peripheral.c: initialize common members only
Other members will be initialized according to peripheral configuration.
This commit is contained in:
parent
f938bb790e
commit
2c5973ee7e
|
@ -43,7 +43,7 @@ void peripheral_update(union peripheral *const p)
|
|||
void peripheral_init(const struct peripheral_cfg *const cfg,
|
||||
union peripheral *const p)
|
||||
{
|
||||
*p = (const union peripheral){0};
|
||||
p->common = (const struct peripheral_common){0};
|
||||
|
||||
switch (p->common.type = cfg->type)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue