*
* @APPLE_LICENSE_HEADER_START@
*
- * This file contains Original Code and/or Modifications of Original Code
- * as defined in and that are subject to the Apple Public Source License
- * Version 2.0 (the 'License'). You may not use this file except in
- * compliance with the License. Please obtain a copy of the License at
- * http://www.opensource.apple.com/apsl/ and read it before using this
- * file.
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
*
- * The Original Code and all software distributed under the License are
- * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
* EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
* INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
- * Please see the License for the specific language governing rights and
- * limitations under the License.
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
*
* @APPLE_LICENSE_HEADER_END@
*/
#else /* !defined(__alpha) */
#define is_kernel_data_addr(a) \
- (!(a) || ((a) >= VM_MIN_KERNEL_ADDRESS && !((a) & 0x3)))
+ (!(a) || ((a) >= vm_min_kernel_address && !((a) & 0x3)))
#endif /* defined(__alpha) */
*/
scan = (void *)z->free_elements;
- (void *)z->free_elements = NULL;
+ z->free_elements = 0;
unlock_zone(z);
if (keep != NULL) {
tail->next = (void *)z->free_elements;
- (void *)z->free_elements = keep;
+ z->free_elements = (vm_offset_t) keep;
tail = keep = NULL;
} else {
m =0;
}
if (m !=0 ) {
prev->next = (void *)z->free_elements;
- (void *)z->free_elements = (void *)base_elt;
+ z->free_elements = (vm_offset_t) base_elt;
base_prev->next = elt;
prev = base_prev;
}
lock_zone(z);
tail->next = (void *)z->free_elements;
- (void *)z->free_elements = keep;
+ z->free_elements = (vm_offset_t) keep;
unlock_zone(z);
}
if (keep != NULL) {
tail->next = (void *)z->free_elements;
- (void *)z->free_elements = keep;
+ z->free_elements = (vm_offset_t) keep;
}
if (z->waiting) {
if (keep != NULL) {
tail->next = (void *)z->free_elements;
- (void *)z->free_elements = keep;
+ z->free_elements = (vm_offset_t) keep;
}
}
#ifdef ppc
max_zones = num_zones + 4;
#else
- max_zones = num_zones + 2;
+ max_zones = num_zones + 3; /* ATN: count the number below!! */
#endif
z = first_zone;
simple_unlock(&all_zones_lock);
zn++;
zi++;
#endif
+
+#ifdef i386
+ strcpy(zn->zn_name, "page_tables");
+ pt_fake_zone_info(&zi->zi_count, &zi->zi_cur_size, &zi->zi_max_size, &zi->zi_elem_size,
+ &zi->zi_alloc_size, &zi->zi_collectable, &zi->zi_exhaustible);
+ zn++;
+ zi++;
+#endif
+
strcpy(zn->zn_name, "kalloc.large");
kalloc_fake_zone_info(&zi->zi_count, &zi->zi_cur_size, &zi->zi_max_size, &zi->zi_elem_size,
&zi->zi_alloc_size, &zi->zi_collectable, &zi->zi_exhaustible);