110-add_number_to_dev_name.patch 341 B

1234567891011
  1. --- a/driver/wl_linux.c
  2. +++ b/driver/wl_linux.c
  3. @@ -1425,7 +1425,7 @@ wl_alloc_if(wl_info_t *wl, int iftype, u
  4. dev = alloc_etherdev(sizeof(wl_if_t));
  5. wlif = netdev_priv(dev);
  6. bzero(wlif, sizeof(wl_if_t));
  7. - strncpy(dev->name, name, IFNAMSIZ);
  8. + snprintf(dev->name, IFNAMSIZ, name, subunit);
  9. wlif->type = iftype;
  10. wlif->dev = dev;