Il mer 27 nov 2024, 07:17 Zhao Liu ha scritto:
> > and a single "regs: BqlRefCell" in PL011State.
>
> Here I have a possibly common question about the choice of BqlCell and
> future BqlRefCell. Pls refer my comment below...
>
> I understand we need BqlRefCell instead of BqlCell for registers sinc
Paolo Bonzini writes:
> QEMU objects usually have their pointer shared with the "outside
> world" very early in their lifetime, for example when they create their
> MemoryRegions. Because at this point it is not valid anymore to
> create a &mut reference to the device, individual parts of the
On Tue, Nov 26, 2024 at 05:11:36PM +0100, Paolo Bonzini wrote:
> Date: Tue, 26 Nov 2024 17:11:36 +0100
> From: Paolo Bonzini
> Subject: Re: [PATCH 1/2] rust: add BQL-enforcing Cell variant
>
> On 11/26/24 15:56, Zhao Liu wrote:
> > > > But this actually applies to
On 11/26/24 15:56, Zhao Liu wrote:
But this actually applies to _all_ of the device struct! Once a
pointer to the device has been handed out (for example via
memory_region_init_io or qdev_init_clock_in), accesses to the device
struct must not use &mut anymore.
is the final goal to wrap the ent
On Fri, Nov 22, 2024 at 08:47:55AM +0100, Paolo Bonzini wrote:
> Date: Fri, 22 Nov 2024 08:47:55 +0100
> From: Paolo Bonzini
> Subject: [PATCH 1/2] rust: add BQL-enforcing Cell variant
> X-Mailer: git-send-email 2.47.0
>
> QEMU objects usually have their pointer shared with th
QEMU objects usually have their pointer shared with the "outside
world" very early in their lifetime, for example when they create their
MemoryRegions. Because at this point it is not valid anymore to
create a &mut reference to the device, individual parts of the
device struct must be made mutable