Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 14302
b: refs/heads/master
c: fbf0e13
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Nov 17, 2005
1 parent 2a977a9 commit e7ef4a9
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a2c91a8819e315e9fd1aef3ff57badb6c1be3f80
refs/heads/master: fbf0e1348ec4023675123d432ce1fdfa1eef8e54
7 changes: 5 additions & 2 deletions trunk/drivers/net/wireless/ipw2200.c
Original file line number Diff line number Diff line change
Expand Up @@ -1110,8 +1110,7 @@ static struct ipw_fw_error *ipw_alloc_error_log(struct ipw_priv *priv)
error->elem_len = elem_len;
error->log_len = log_len;
error->elem = (struct ipw_error_elem *)error->payload;
error->log = (struct ipw_event *)(error->elem +
(sizeof(*error->elem) * elem_len));
error->log = (struct ipw_event *)(error->elem + elem_len);

ipw_capture_event_log(priv, log_len, error->log);

Expand Down Expand Up @@ -8926,6 +8925,10 @@ static int ipw_request_direct_scan(struct ipw_priv *priv, char *essid,
struct ipw_scan_request_ext scan;
int err = 0, scan_type;

if (!(priv->status & STATUS_INIT) ||
(priv->status & STATUS_EXIT_PENDING))
return 0;

down(&priv->sem);

if (priv->status & STATUS_RF_KILL_MASK) {
Expand Down
31 changes: 27 additions & 4 deletions trunk/include/asm-i386/signal.h
Original file line number Diff line number Diff line change
Expand Up @@ -159,14 +159,37 @@ typedef struct sigaltstack {

#define __HAVE_ARCH_SIG_BITOPS

static __inline__ void sigaddset(sigset_t *set, int _sig)
#define sigaddset(set,sig) \
(__builtin_constant_p(sig) ? \
__const_sigaddset((set),(sig)) : \
__gen_sigaddset((set),(sig)))

static __inline__ void __gen_sigaddset(sigset_t *set, int _sig)
{
__asm__("btsl %1,%0" : "=m"(*set) : "Ir"(_sig - 1) : "cc");
__asm__("btsl %1,%0" : "+m"(*set) : "Ir"(_sig - 1) : "cc");
}

static __inline__ void sigdelset(sigset_t *set, int _sig)
static __inline__ void __const_sigaddset(sigset_t *set, int _sig)
{
__asm__("btrl %1,%0" : "=m"(*set) : "Ir"(_sig - 1) : "cc");
unsigned long sig = _sig - 1;
set->sig[sig / _NSIG_BPW] |= 1 << (sig % _NSIG_BPW);
}

#define sigdelset(set,sig) \
(__builtin_constant_p(sig) ? \
__const_sigdelset((set),(sig)) : \
__gen_sigdelset((set),(sig)))


static __inline__ void __gen_sigdelset(sigset_t *set, int _sig)
{
__asm__("btrl %1,%0" : "+m"(*set) : "Ir"(_sig - 1) : "cc");
}

static __inline__ void __const_sigaddset(sigset_t *set, int _sig)
{
unsigned long sig = _sig - 1;
set->sig[sig / _NSIG_BPW] &= ~(1 << (sig % _NSIG_BPW));
}

static __inline__ int __const_sigismember(sigset_t *set, int _sig)
Expand Down

0 comments on commit e7ef4a9

Please sign in to comment.