+load_return_t
+fatfile_getarch_affinity(
+ struct vnode *vp,
+ vm_offset_t data_ptr,
+ struct fat_arch *archret,
+ int affinity __unused)
+{
+ /*
+ * Ignore all architectural bits when determining if an image
+ * in a fat file should be skipped or graded.
+ */
+ return fatfile_getarch(vp, data_ptr, cpu_type(), CPU_ARCH_MASK, archret);
+}
+
+/**********************************************************************
+ * Routine: fatfile_getarch_with_bits()
+ *
+ * Function: Locate the architecture-dependant contents of a fat
+ * file that match this CPU.
+ *
+ * Args: vp: The vnode for the fat file.
+ * archbits: Architecture specific feature bits
+ * header: A pointer to the fat file header.
+ * archret (out): Pointer to fat_arch structure to hold
+ * the results.
+ *
+ * Returns: KERN_SUCCESS: Valid architecture found.
+ * KERN_FAILURE: No valid architecture found.
+ **********************************************************************/
+load_return_t
+fatfile_getarch_with_bits(
+ struct vnode *vp,
+ integer_t archbits,
+ vm_offset_t data_ptr,
+ struct fat_arch *archret)
+{
+ return fatfile_getarch(vp, data_ptr, archbits | (cpu_type() & ~CPU_ARCH_MASK), 0, archret);
+}