[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 2/2] rust: add bindings for interrupt sources
From: |
Paolo Bonzini |
Subject: |
Re: [PATCH 2/2] rust: add bindings for interrupt sources |
Date: |
Fri, 22 Nov 2024 09:32:30 +0100 |
> > +/// Interrupt sources are used by devices to pass changes to a boolean
> > value to
> > +/// other devices (typically interrupt or GPIO controllers). QEMU
> > interrupt
> > +/// sources are always active-high.
>
> So 'always active-high' = true below? (Wondering about pulsation, if the
> true -> false transition is always correct).
Yeah, I mean that raise uses true (or 1 :)) and lower uses false.
an example?
> Is this deliberate to restrict the Rust binding to boolean? (Maybe you
> envision a VectoredInterruptSource implementation for that).
No, I simply wasn't aware of that. I'll adjust; do you have
an example?
> > +/// Interrupt sources can only be triggered under the Big QEMU Lock; they
> > are
> > +/// neither `Send` nor `Sync`.
Oops, this is incorrect. BqlCell *is* Send/Sync, but checks the
BQL state at run-time.
Paolo
Re: [PATCH 2/2] rust: add bindings for interrupt sources, Zhao Liu, 2024/11/26