* porting to ia64
@ 2005-02-09 22:08 Eric Desjardins
2005-02-09 22:29 ` Luck, Tony
2005-02-09 22:32 ` Keith Owens
0 siblings, 2 replies; 3+ messages in thread
From: Eric Desjardins @ 2005-02-09 22:08 UTC (permalink / raw)
To: linux-ia64
Hi,
I'm not to familiar with kernel code but I'm trying to port a kernel
driver from x86 to ia64.
I was just wondering how should I translate that:
static int interrupts_blocked()
{
unsigned long flags = 0;
__save_flags(flags);
return (flags & X86_EFLAGS_IF) =
0;
}
Thanks for any help I can get...
--
Eric Desjardins <eric.desjardins@discreet.com>
^ permalink raw reply [flat|nested] 3+ messages in thread* RE: porting to ia64 2005-02-09 22:08 porting to ia64 Eric Desjardins @ 2005-02-09 22:29 ` Luck, Tony 2005-02-09 22:32 ` Keith Owens 1 sibling, 0 replies; 3+ messages in thread From: Luck, Tony @ 2005-02-09 22:29 UTC (permalink / raw) To: linux-ia64 > return (flags & X86_EFLAGS_IF) I suspect that "irqs_disabled()" does what you want (and is portable between x86, ia64 and others). -Tony ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: porting to ia64 2005-02-09 22:08 porting to ia64 Eric Desjardins 2005-02-09 22:29 ` Luck, Tony @ 2005-02-09 22:32 ` Keith Owens 1 sibling, 0 replies; 3+ messages in thread From: Keith Owens @ 2005-02-09 22:32 UTC (permalink / raw) To: linux-ia64 On Wed, 09 Feb 2005 17:08:23 -0500, Eric Desjardins <eric.desjardins@discreet.com> wrote: >Hi, > >I'm not to familiar with kernel code but I'm trying to port a kernel >driver from x86 to ia64. > >I was just wondering how should I translate that: > >static int interrupts_blocked() >{ > unsigned long flags = 0; > > __save_flags(flags); > > return (flags & X86_EFLAGS_IF) = >0; >} if (irqs_disabled()) { ... } works on all platforms. Your driver does not need to define its own function. ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-02-09 22:32 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2005-02-09 22:08 porting to ia64 Eric Desjardins 2005-02-09 22:29 ` Luck, Tony 2005-02-09 22:32 ` Keith Owens
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox