Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

usb: xhci: convert tasklets to use new tasklet_setup() API

In preparation for unconditionally passing the
struct tasklet_struct pointer to all tasklet
callbacks, switch to using the new tasklet_setup()
and from_tasklet() to pass the tasklet pointer explicitly.

Signed-off-by: Romain Perier <romain.perier@gmail.com>
Signed-off-by: Allen Pais <allen.lkml@gmail.com>
Link: https://lore.kernel.org/r/20200817090209.26351-7-allen.cryptic@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Allen Pais and committed by
Greg Kroah-Hartman
81d324cd f7aa9386

+3 -3
+3 -3
drivers/usb/host/xhci-dbgtty.c
··· 288 288 .unthrottle = dbc_tty_unthrottle, 289 289 }; 290 290 291 - static void dbc_rx_push(unsigned long _port) 291 + static void dbc_rx_push(struct tasklet_struct *t) 292 292 { 293 293 struct dbc_request *req; 294 294 struct tty_struct *tty; 295 295 unsigned long flags; 296 296 bool do_push = false; 297 297 bool disconnect = false; 298 - struct dbc_port *port = (void *)_port; 298 + struct dbc_port *port = from_tasklet(port, t, push); 299 299 struct list_head *queue = &port->read_queue; 300 300 301 301 spin_lock_irqsave(&port->port_lock, flags); ··· 382 382 { 383 383 tty_port_init(&port->port); 384 384 spin_lock_init(&port->port_lock); 385 - tasklet_init(&port->push, dbc_rx_push, (unsigned long)port); 385 + tasklet_setup(&port->push, dbc_rx_push); 386 386 INIT_LIST_HEAD(&port->read_pool); 387 387 INIT_LIST_HEAD(&port->read_queue); 388 388 INIT_LIST_HEAD(&port->write_pool);