mirror of
https://github.com/FEX-Emu/linux.git
synced 2025-03-05 19:18:06 +00:00
appletalk: fix checkpatch error with indent
checkpatch error: switch and case should be at the same indent. Signed-off-by: Wang Weidong <wangweidong1@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
6f0984a05e
commit
7b30600cc6
@ -1790,53 +1790,53 @@ static int atalk_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
|
|||||||
void __user *argp = (void __user *)arg;
|
void __user *argp = (void __user *)arg;
|
||||||
|
|
||||||
switch (cmd) {
|
switch (cmd) {
|
||||||
/* Protocol layer */
|
/* Protocol layer */
|
||||||
case TIOCOUTQ: {
|
case TIOCOUTQ: {
|
||||||
long amount = sk->sk_sndbuf - sk_wmem_alloc_get(sk);
|
long amount = sk->sk_sndbuf - sk_wmem_alloc_get(sk);
|
||||||
|
|
||||||
if (amount < 0)
|
if (amount < 0)
|
||||||
amount = 0;
|
amount = 0;
|
||||||
rc = put_user(amount, (int __user *)argp);
|
rc = put_user(amount, (int __user *)argp);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case TIOCINQ: {
|
case TIOCINQ: {
|
||||||
/*
|
/*
|
||||||
* These two are safe on a single CPU system as only
|
* These two are safe on a single CPU system as only
|
||||||
* user tasks fiddle here
|
* user tasks fiddle here
|
||||||
*/
|
*/
|
||||||
struct sk_buff *skb = skb_peek(&sk->sk_receive_queue);
|
struct sk_buff *skb = skb_peek(&sk->sk_receive_queue);
|
||||||
long amount = 0;
|
long amount = 0;
|
||||||
|
|
||||||
if (skb)
|
if (skb)
|
||||||
amount = skb->len - sizeof(struct ddpehdr);
|
amount = skb->len - sizeof(struct ddpehdr);
|
||||||
rc = put_user(amount, (int __user *)argp);
|
rc = put_user(amount, (int __user *)argp);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SIOCGSTAMP:
|
case SIOCGSTAMP:
|
||||||
rc = sock_get_timestamp(sk, argp);
|
rc = sock_get_timestamp(sk, argp);
|
||||||
break;
|
break;
|
||||||
case SIOCGSTAMPNS:
|
case SIOCGSTAMPNS:
|
||||||
rc = sock_get_timestampns(sk, argp);
|
rc = sock_get_timestampns(sk, argp);
|
||||||
break;
|
break;
|
||||||
/* Routing */
|
/* Routing */
|
||||||
case SIOCADDRT:
|
case SIOCADDRT:
|
||||||
case SIOCDELRT:
|
case SIOCDELRT:
|
||||||
rc = -EPERM;
|
rc = -EPERM;
|
||||||
if (capable(CAP_NET_ADMIN))
|
if (capable(CAP_NET_ADMIN))
|
||||||
rc = atrtr_ioctl(cmd, argp);
|
rc = atrtr_ioctl(cmd, argp);
|
||||||
break;
|
break;
|
||||||
/* Interface */
|
/* Interface */
|
||||||
case SIOCGIFADDR:
|
case SIOCGIFADDR:
|
||||||
case SIOCSIFADDR:
|
case SIOCSIFADDR:
|
||||||
case SIOCGIFBRDADDR:
|
case SIOCGIFBRDADDR:
|
||||||
case SIOCATALKDIFADDR:
|
case SIOCATALKDIFADDR:
|
||||||
case SIOCDIFADDR:
|
case SIOCDIFADDR:
|
||||||
case SIOCSARP: /* proxy AARP */
|
case SIOCSARP: /* proxy AARP */
|
||||||
case SIOCDARP: /* proxy AARP */
|
case SIOCDARP: /* proxy AARP */
|
||||||
rtnl_lock();
|
rtnl_lock();
|
||||||
rc = atif_ioctl(cmd, argp);
|
rc = atif_ioctl(cmd, argp);
|
||||||
rtnl_unlock();
|
rtnl_unlock();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user