cpufunc.h (4f6c19e5930de48dd17e6199cb65b6e3a149166d) cpufunc.h (a67ef0a77a6bf036275ca4365d251d34b92cfa78)
1/*-
2 * Copyright (c) 2003 Peter Wemm.
3 * Copyright (c) 1993 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 105 unchanged lines hidden (view full) ---

114}
115
116static __inline void
117enable_intr(void)
118{
119 __asm __volatile("sti");
120}
121
1/*-
2 * Copyright (c) 2003 Peter Wemm.
3 * Copyright (c) 1993 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 105 unchanged lines hidden (view full) ---

114}
115
116static __inline void
117enable_intr(void)
118{
119 __asm __volatile("sti");
120}
121
122#ifdef _KERNEL
123
122#define HAVE_INLINE_FFS
123
124static __inline int
125ffs(int mask)
126{
127#if 0
128 /*
129 * Note that gcc-2's builtin ffs would be used if we didn't declare

--- 27 unchanged lines hidden (view full) ---

157#define HAVE_INLINE_FLSL
158
159static __inline int
160flsl(long mask)
161{
162 return (mask == 0 ? mask : (int)bsrq((u_long)mask) + 1);
163}
164
124#define HAVE_INLINE_FFS
125
126static __inline int
127ffs(int mask)
128{
129#if 0
130 /*
131 * Note that gcc-2's builtin ffs would be used if we didn't declare

--- 27 unchanged lines hidden (view full) ---

159#define HAVE_INLINE_FLSL
160
161static __inline int
162flsl(long mask)
163{
164 return (mask == 0 ? mask : (int)bsrq((u_long)mask) + 1);
165}
166
167#endif /* _KERNEL */
168
165static __inline void
166halt(void)
167{
168 __asm __volatile("hlt");
169}
170
171#if __GNUC__ < 2
172

--- 604 unchanged lines hidden ---
169static __inline void
170halt(void)
171{
172 __asm __volatile("hlt");
173}
174
175#if __GNUC__ < 2
176

--- 604 unchanged lines hidden ---