# Re: \[PATCH 07/16\] tty: remove file from tty\_ldisc\_ops::ioctl and compat\_ioctl

- From: Marc Kleine-Budde \<mkl@pengutronix.de\>
- Date: 2021-09-15 08:05:09 
- List: linux-serial
- Page: https://ratatoskr.run/linux-serial/2021/09/1509081
- Thread: https://ratatoskr.run/linux-serial/2021/09/1507597/t.md

```text
On 14.09.2021 11:11:25, Jiri Slaby wrote:
> After the previous patches, noone needs 'file' parameter in neither
> ioctl hook from tty_ldisc_ops. So remove 'file' from both of them.
> 
[...]
> diff --git a/drivers/net/can/slcan.c b/drivers/net/can/slcan.c
> index 9a4ebda30510..de2da1b09a79 100644
> --- a/drivers/net/can/slcan.c
> +++ b/drivers/net/can/slcan.c
> @@ -670,8 +670,8 @@ static void slcan_hangup(struct tty_struct *tty)
>  }
>  
>  /* Perform I/O control on an active SLCAN channel. */
> -static int slcan_ioctl(struct tty_struct *tty, struct file *file,
> -		       unsigned int cmd, unsigned long arg)
> +static int slcan_ioctl(struct tty_struct *tty, unsigned int cmd,
> +		unsigned long arg)
>  {
>  	struct slcan *sl = (struct slcan *) tty->disc_data;
>  	unsigned int tmp;

nitpick:
Checkpatch complains about this:

| CHECK: Alignment should match open parenthesis
| #674: FILE: drivers/net/can/slcan.c:674:
| +static int slcan_ioctl(struct tty_struct *tty, unsigned int cmd,
| +               unsigned long arg)

Same for other hunks in this file.

regards,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |
```

## Attachments

- [signature.asc](https://ratatoskr.run/linux-serial/2021/09/1509081/attachment/0) (application/pgp-signature, 488 bytes)
