1. 03 Feb, 2021 38 commits
  2. 02 Feb, 2021 2 commits
    • Jakub Kicinski's avatar
      Merge branch 'drivers-net-update-tasklet_init-callers' · c96b0a39
      Jakub Kicinski authored
      Emil Renner Berthing says:
      
      ====================
      drivers: net: update tasklet_init callers
      
      This updates the remaining callers of tasklet_init() in drivers/net
      to the new API introduced in
      commit 12cc923f ("tasklet: Introduce new initialization API")
      
      All changes are done by coccinelle using the following semantic patch.
      Coccinelle needs a little help parsing drivers/net/arcnet/arcnet.c
      
      @ match @
      type T;
      T *container;
      identifier tasklet;
      identifier callback;
      @@
      	tasklet_init(&container->tasklet, callback, (unsigned long)container);
      
      @ patch1 depends on match @
      type match.T;
      identifier match.tasklet;
      identifier match.callback;
      identifier data;
      identifier container;
      @@
      -void callback(unsigned long data)
      +void callback(struct tasklet_struct *t)
      {
      	...
      -	T *container = (T *)data;
      +	T *container = from_tasklet(container, t, tasklet);
      	...
      }
      
      @ patch2 depends on match @
      type match.T;
      identifier match.tasklet;
      identifier match.callback;
      identifier data;
      identifier container;
      @@
      -void callback(unsigned long data)
      +void callback(struct tasklet_struct *t)
      {
      	...
      -	T *container;
      +	T *container = from_tasklet(container, t, tasklet);
      	...
      -	container = (T *)data;
      	...
      }
      
      @ depends on (patch1 || patch2) @
      match.T *container;
      identifier match.tasklet;
      identifier match.callback;
      @@
      -	tasklet_init(&container->tasklet, callback, (unsigned long)container);
      +	tasklet_setup(&container->tasklet, callback);
      ====================
      
      Link: https://lore.kernel.org/r/20210130234730.26565-1-kernel@esmil.dkSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      c96b0a39
    • Emil Renner Berthing's avatar
      net: usb: rtl8150: use new tasklet API · 1999ad32
      Emil Renner Berthing authored
      This converts the driver to use the new tasklet API introduced in
      commit 12cc923f ("tasklet: Introduce new initialization API")
      Signed-off-by: default avatarEmil Renner Berthing <kernel@esmil.dk>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      1999ad32