net: xilinx_ll_temac: Fix string overflow
Size of this snprintf "lltemac.%lx" is bigger than 16 characters. Replacing it with "ll_tem.%lx" Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Michal Simek <michal.simek@xilinx.com>
This commit is contained in:
parent
7e5281fee4
commit
21909baf57
@ -303,7 +303,8 @@ int xilinx_ll_temac_initialize(bd_t *bis, struct ll_temac_info *devinf)
|
||||
if (devinf->devname) {
|
||||
strncpy(dev->name, devinf->devname, sizeof(dev->name));
|
||||
} else {
|
||||
snprintf(dev->name, sizeof(dev->name), "lltemac.%lx", devinf->base_addr);
|
||||
snprintf(dev->name, sizeof(dev->name), "ll_tem.%lx",
|
||||
devinf->base_addr);
|
||||
devinf->devname = dev->name;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user