* how to disable interrupt in application?
@ 2006-05-31 0:33 zhuzhenhua
2006-05-31 6:11 ` Bin Chen
0 siblings, 1 reply; 6+ messages in thread
From: zhuzhenhua @ 2006-05-31 0:33 UTC (permalink / raw)
To: linux-mips
our project have a video decoder code run as application. there is
some short code want to be run uninterruptable. is there anyway to do
it?
thanks for any hints
Best Regards
zhuzhenhua
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to disable interrupt in application?
2006-05-31 0:33 how to disable interrupt in application? zhuzhenhua
@ 2006-05-31 6:11 ` Bin Chen
2006-05-31 6:58 ` Kevin D. Kissell
2006-05-31 7:02 ` Freddy Spierenburg
0 siblings, 2 replies; 6+ messages in thread
From: Bin Chen @ 2006-05-31 6:11 UTC (permalink / raw)
To: zhuzhenhua; +Cc: linux-mips
man sigprocmask
On 5/31/06, zhuzhenhua <zzh.hust@gmail.com> wrote:
> our project have a video decoder code run as application. there is
> some short code want to be run uninterruptable. is there anyway to do
> it?
> thanks for any hints
> Best Regards
>
>
> zhuzhenhua
>
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to disable interrupt in application?
2006-05-31 6:11 ` Bin Chen
@ 2006-05-31 6:58 ` Kevin D. Kissell
2006-05-31 7:37 ` zhuzhenhua
2006-05-31 7:02 ` Freddy Spierenburg
1 sibling, 1 reply; 6+ messages in thread
From: Kevin D. Kissell @ 2006-05-31 6:58 UTC (permalink / raw)
To: Bin Chen, zhuzhenhua; +Cc: linux-mips
sigprocmask manages signals, which are user-mode abstractions
of exceptions. It does not affect hardware interrupt behavior.
If by "uninterruptable", ZhuZhenHua means that the decoder
process will not get switched out in favor of another user-mode
process, then getpriority()/setpriority() provide some control
that may be sufficient. If what is desired is that hardware interrupts
are actually masked during some critical sequence, the critical
sequence must be executed with kenel privilege - you need to
look at putting the critical sequence into a driver or other loadable
kernel module that can be invoked by the application code.
Regards,
Kevin K.
----- Original Message -----
From: "Bin Chen" <binary.chen@gmail.com>
To: "zhuzhenhua" <zzh.hust@gmail.com>
Cc: "linux-mips" <linux-mips@linux-mips.org>
Sent: Wednesday, May 31, 2006 8:11 AM
Subject: Re: how to disable interrupt in application?
> man sigprocmask
>
> On 5/31/06, zhuzhenhua <zzh.hust@gmail.com> wrote:
> > our project have a video decoder code run as application. there is
> > some short code want to be run uninterruptable. is there anyway to do
> > it?
> > thanks for any hints
> > Best Regards
> >
> >
> > zhuzhenhua
> >
> >
>
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to disable interrupt in application?
2006-05-31 6:11 ` Bin Chen
2006-05-31 6:58 ` Kevin D. Kissell
@ 2006-05-31 7:02 ` Freddy Spierenburg
1 sibling, 0 replies; 6+ messages in thread
From: Freddy Spierenburg @ 2006-05-31 7:02 UTC (permalink / raw)
To: Bin Chen; +Cc: zhuzhenhua, linux-mips
[-- Attachment #1: Type: text/plain, Size: 740 bytes --]
Hi,
On Wed, May 31, 2006 at 02:11:00PM +0800, Bin Chen wrote:
> On 5/31/06, zhuzhenhua <zzh.hust@gmail.com> wrote:
> >our project have a video decoder code run as application. there is
> >some short code want to be run uninterruptable. is there anyway to do
> >it?
> man sigprocmask
This way you can mask signals, but AFAIK your process is still
interruptable. What if the kernel scheduler decides another
process deserves some running time? Not something you can
suppress, if I'm correct.
--
$ cat ~/.signature
Freddy Spierenburg <freddy@dusktilldawn.nl> http://freddy.snarl.nl/
GnuPG: 0x7941D1E1=C948 5851 26D2 FA5C 39F1 E588 6F17 FD5D 7941 D1E1
$ # Please read http://www.ietf.org/rfc/rfc2015.txt before complain!
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to disable interrupt in application?
2006-05-31 6:58 ` Kevin D. Kissell
@ 2006-05-31 7:37 ` zhuzhenhua
2006-05-31 9:39 ` Kevin D. Kissell
0 siblings, 1 reply; 6+ messages in thread
From: zhuzhenhua @ 2006-05-31 7:37 UTC (permalink / raw)
To: Kevin D. Kissell; +Cc: Bin Chen, linux-mips
On 5/31/06, Kevin D. Kissell <KevinK@mips.com> wrote:
> sigprocmask manages signals, which are user-mode abstractions
> of exceptions. It does not affect hardware interrupt behavior.
> If by "uninterruptable", ZhuZhenHua means that the decoder
> process will not get switched out in favor of another user-mode
> process, then getpriority()/setpriority() provide some control
> that may be sufficient. If what is desired is that hardware interrupts
> are actually masked during some critical sequence, the critical
> sequence must be executed with kenel privilege - you need to
> look at putting the critical sequence into a driver or other loadable
> kernel module that can be invoked by the application code.
>
> Regards,
>
> Kevin K.
>
> ----- Original Message -----
> From: "Bin Chen" <binary.chen@gmail.com>
> To: "zhuzhenhua" <zzh.hust@gmail.com>
> Cc: "linux-mips" <linux-mips@linux-mips.org>
> Sent: Wednesday, May 31, 2006 8:11 AM
> Subject: Re: how to disable interrupt in application?
>
>
> > man sigprocmask
> >
> > On 5/31/06, zhuzhenhua <zzh.hust@gmail.com> wrote:
> > > our project have a video decoder code run as application. there is
> > > some short code want to be run uninterruptable. is there anyway to do
> > > it?
> > > thanks for any hints
> > > Best Regards
> > >
> > >
> > > zhuzhenhua
> > >
> > >
> >
> >
>
actually i don't want the pipelining be interrupted while run our user
define instructions.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to disable interrupt in application?
2006-05-31 7:37 ` zhuzhenhua
@ 2006-05-31 9:39 ` Kevin D. Kissell
0 siblings, 0 replies; 6+ messages in thread
From: Kevin D. Kissell @ 2006-05-31 9:39 UTC (permalink / raw)
To: zhuzhenhua; +Cc: Bin Chen, linux-mips
> actually i don't want the pipelining be interrupted while run our user
> defined instructions.
If you want to guarantee that, you need to put that code into a kernel
module that turns off interrupts during processing - and you need to
accept responsibility for the fact that a problem in your code may be
irrecoverably fatal to the system, and that errors in system timing may
accumulate due to clock interrupts not being serviced.
Regards,
Kevin K.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2006-05-31 9:36 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-05-31 0:33 how to disable interrupt in application? zhuzhenhua
2006-05-31 6:11 ` Bin Chen
2006-05-31 6:58 ` Kevin D. Kissell
2006-05-31 7:37 ` zhuzhenhua
2006-05-31 9:39 ` Kevin D. Kissell
2006-05-31 7:02 ` Freddy Spierenburg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox