Skip to content
Snippets Groups Projects
Commit a4ffd956 authored by Mike Frysinger's avatar Mike Frysinger
Browse files

Blackfin: gptimers: add structure for hardware register layout

parent 427472c9
No related branches found
No related tags found
No related merge requests found
...@@ -193,4 +193,22 @@ uint16_t get_enabled_gptimers(void); ...@@ -193,4 +193,22 @@ uint16_t get_enabled_gptimers(void);
uint32_t get_gptimer_status(unsigned int group); uint32_t get_gptimer_status(unsigned int group);
void set_gptimer_status(unsigned int group, uint32_t value); void set_gptimer_status(unsigned int group, uint32_t value);
/*
* All Blackfin system MMRs are padded to 32bits even if the register
* itself is only 16bits. So use a helper macro to streamline this.
*/
#define __BFP(m) u16 m; u16 __pad_##m
/*
* bfin timer registers layout
*/
struct bfin_gptimer_regs {
__BFP(config);
u32 counter;
u32 period;
u32 width;
};
#undef __BFP
#endif #endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment