cndm: Add wmb to ensure command is fully written in mailbox before executing it

Signed-off-by: Alex Forencich <alex@alexforencich.com>
This commit is contained in:
Alex Forencich
2026-03-03 00:46:15 -08:00
parent 0d4a030e3f
commit 902996e3bd

View File

@@ -24,6 +24,9 @@ int cndm_exec_mbox_cmd(struct cndm_dev *cdev, void *cmd, void *rsp)
iowrite32(*((u32 *)(cmd + k*4)), cdev->hw_addr + 0x10000 + k*4); iowrite32(*((u32 *)(cmd + k*4)), cdev->hw_addr + 0x10000 + k*4);
} }
// ensure the command is completely written
wmb();
// execute it // execute it
iowrite32(0x00000001, cdev->hw_addr + 0x0200); iowrite32(0x00000001, cdev->hw_addr + 0x0200);