-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'alpha' (alpha architecture patches)
Merge alpha architecture update from Michael Cree: "The Alpha Maintainer, Matt Turner, is currently unavailable, so I have collected up patches that have been posted to the linux-alpha mailing list over the last couple of months, and are forwarding them to you in the hope that you are prepared to accept them via me. The patches by Al Viro and myself I have been running against kernels for two months now so have had quite a bit of testing. All except one patch were intended for the 3.5 kernel but because of Matt's unavailability never got forwarded to you." * emailed patches from Michael Cree <mcree@orcon.net.nz>: (9 commits) alpha: Fix fall-out from disintegrating asm/system.h Redefine ATOMIC_INIT and ATOMIC64_INIT to drop the casts alpha: fix fpu.h usage in userspace alpha/mm/fault.c: Port OOM changes to do_page_fault alpha: take kernel_execve() out of entry.S alpha: take a bunch of syscalls into osf_sys.c alpha: Use new generic strncpy_from_user() and strnlen_user() alpha: Wire up cross memory attach syscalls alpha: Don't export SOCK_NONBLOCK to user space.
- Loading branch information
Showing
21 changed files
with
177 additions
and
1,176 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#ifndef _ASM_WORD_AT_A_TIME_H | ||
#define _ASM_WORD_AT_A_TIME_H | ||
|
||
#include <asm/compiler.h> | ||
|
||
/* | ||
* word-at-a-time interface for Alpha. | ||
*/ | ||
|
||
/* | ||
* We do not use the word_at_a_time struct on Alpha, but it needs to be | ||
* implemented to humour the generic code. | ||
*/ | ||
struct word_at_a_time { | ||
const unsigned long unused; | ||
}; | ||
|
||
#define WORD_AT_A_TIME_CONSTANTS { 0 } | ||
|
||
/* Return nonzero if val has a zero */ | ||
static inline unsigned long has_zero(unsigned long val, unsigned long *bits, const struct word_at_a_time *c) | ||
{ | ||
unsigned long zero_locations = __kernel_cmpbge(0, val); | ||
*bits = zero_locations; | ||
return zero_locations; | ||
} | ||
|
||
static inline unsigned long prep_zero_mask(unsigned long val, unsigned long bits, const struct word_at_a_time *c) | ||
{ | ||
return bits; | ||
} | ||
|
||
#define create_zero_mask(bits) (bits) | ||
|
||
static inline unsigned long find_zero(unsigned long bits) | ||
{ | ||
#if defined(CONFIG_ALPHA_EV6) && defined(CONFIG_ALPHA_EV67) | ||
/* Simple if have CIX instructions */ | ||
return __kernel_cttz(bits); | ||
#else | ||
unsigned long t1, t2, t3; | ||
/* Retain lowest set bit only */ | ||
bits &= -bits; | ||
/* Binary search for lowest set bit */ | ||
t1 = bits & 0xf0; | ||
t2 = bits & 0xcc; | ||
t3 = bits & 0xaa; | ||
if (t1) t1 = 4; | ||
if (t2) t2 = 2; | ||
if (t3) t3 = 1; | ||
return t1 + t2 + t3; | ||
#endif | ||
} | ||
|
||
#endif /* _ASM_WORD_AT_A_TIME_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.