On Mon, Mar 7, 2016 at 10:28 AM, Simon Glass wrote:
> It is common with memory-mapped I/O to use the address of a structure member
> to access memory, as in:
>
>struct some_regs {
> u32 ctrl;
> u32 data;
>}
>
>struct some_regs *regs = (struct some_regs *)BASE_ADDRESS;
>
>
It is common with memory-mapped I/O to use the address of a structure member
to access memory, as in:
struct some_regs {
u32 ctrl;
u32 data;
}
struct some_regs *regs = (struct some_regs *)BASE_ADDRESS;
writel(1, ®->ctrl);
writel(2, ®->data);
This does not currently wo
2 matches
Mail list logo