Ido Schimmel 73cb11933c ipmr: Copy option to correct variable
Cited commit mistakenly copied provided option to 'val' instead of to
'mfc':

```
-               if (copy_from_user(&mfc, optval, sizeof(mfc))) {
+               if (copy_from_sockptr(&val, optval, sizeof(val))) {
```

Fix this by copying the option to 'mfc'.

selftest router_multicast.sh before:

$ ./router_multicast.sh
smcroutectl: Unknown or malformed IPC message 'a' from client.
smcroutectl: failed removing multicast route, does not exist.
TEST: mcast IPv4                                                    [FAIL]
        Multicast not received on first host
TEST: mcast IPv6                                                    [ OK ]
smcroutectl: Unknown or malformed IPC message 'a' from client.
smcroutectl: failed removing multicast route, does not exist.
TEST: RPF IPv4                                                      [FAIL]
        Multicast not received on first host
TEST: RPF IPv6                                                      [ OK ]

selftest router_multicast.sh after:

$ ./router_multicast.sh
TEST: mcast IPv4                                                    [ OK ]
TEST: mcast IPv6                                                    [ OK ]
TEST: RPF IPv4                                                      [ OK ]
TEST: RPF IPv6                                                      [ OK ]

Fixes: 01ccb5b48f08 ("net/ipv4: switch ip_mroute_setsockopt to sockptr_t")
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-07-27 11:39:55 -07:00
..
2020-03-12 15:55:00 -07:00
2020-03-12 15:55:00 -07:00
2020-07-13 17:20:39 -07:00
2020-07-24 17:12:41 -07:00
2020-03-30 13:45:04 -07:00
2020-07-24 17:12:41 -07:00
2020-07-27 11:39:55 -07:00
2020-06-10 13:18:40 -07:00
2020-07-24 15:41:54 -07:00
2020-03-16 18:26:54 -07:00
2020-07-13 17:20:39 -07:00
2020-03-16 18:26:55 -07:00
2020-07-24 15:41:54 -07:00