diff options
| author | Greg Kroah-Hartman <gregkh@google.com> | 2021-01-23 16:11:11 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@google.com> | 2021-01-23 16:11:11 +0100 |
| commit | fc5470b839d979082c5646182e026c226ebdc378 (patch) | |
| tree | 0c0c7705e9a8cddb0bc6221cb6051f9183d055dc /net | |
| parent | cf3e310ff85b280eec62a1470465d986be80c204 (diff) | |
| parent | 4f907dff9d3629fc87f9608770168b68958a9f46 (diff) | |
Merge 4.4.253 into android-4.4-p
Changes in 4.4.253
ASoC: dapm: remove widget from dirty list on free
mm/hugetlb: fix potential missing huge page size info
ext4: fix bug for rename with RENAME_WHITEOUT
ARC: build: add boot_targets to PHONY
ethernet: ucc_geth: fix definition and size of ucc_geth_tx_global_pram
arch/arc: add copy_user_page() to <asm/page.h> to fix build error on ARC
misdn: dsp: select CONFIG_BITREVERSE
net: ethernet: fs_enet: Add missing MODULE_LICENSE
ACPI: scan: add stub acpi_create_platform_device() for !CONFIG_ACPI
ARM: picoxcell: fix missing interrupt-parent properties
Input: uinput - avoid FF flush when destroying device
dump_common_audit_data(): fix racy accesses to ->d_name
NFS: nfs_igrab_and_active must first reference the superblock
ext4: fix superblock checksum failure when setting password salt
RDMA/usnic: Fix memleak in find_free_vf_and_create_qp_grp
mm, slub: consider rest of partial list if acquire_slab() fails
net: sunrpc: interpret the return value of kstrtou32 correctly
usb: ohci: Make distrust_firmware param default to false
iio: buffer: Fix demux update
nfsd4: readdirplus shouldn't return parent of export
net: cdc_ncm: correct overhead in delayed_ndp_size
netxen_nic: fix MSI/MSI-x interrupts
rndis_host: set proper input size for OID_GEN_PHYSICAL_MEDIUM request
net: dcb: Validate netlink message in DCB handler
net: dcb: Accept RTM_GETDCB messages carrying set-like DCB commands
net: sit: unregister_netdevice on newlink's error path
rxrpc: Fix handling of an unsupported token type in rxrpc_read()
net: avoid 32 x truesize under-estimation for tiny skbs
spi: cadence: cache reference clock rate during probe
Linux 4.4.253
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I654eb9f2b62aea6745aeae37341e162ab2a6a596
Diffstat (limited to 'net')
| -rw-r--r-- | net/core/skbuff.c | 9 | ||||
| -rw-r--r-- | net/dcb/dcbnl.c | 2 | ||||
| -rw-r--r-- | net/ipv6/sit.c | 5 | ||||
| -rw-r--r-- | net/rxrpc/ar-key.c | 6 | ||||
| -rw-r--r-- | net/sunrpc/addr.c | 2 |
5 files changed, 18 insertions, 6 deletions
diff --git a/net/core/skbuff.c b/net/core/skbuff.c index f77ea52be8bf..011c2cf4d041 100644 --- a/net/core/skbuff.c +++ b/net/core/skbuff.c @@ -480,13 +480,17 @@ EXPORT_SYMBOL(__netdev_alloc_skb); struct sk_buff *__napi_alloc_skb(struct napi_struct *napi, unsigned int len, gfp_t gfp_mask) { - struct page_frag_cache *nc = this_cpu_ptr(&napi_alloc_cache); + struct page_frag_cache *nc; struct sk_buff *skb; void *data; len += NET_SKB_PAD + NET_IP_ALIGN; - if ((len > SKB_WITH_OVERHEAD(PAGE_SIZE)) || + /* If requested length is either too small or too big, + * we use kmalloc() for skb->head allocation. + */ + if (len <= SKB_WITH_OVERHEAD(1024) || + len > SKB_WITH_OVERHEAD(PAGE_SIZE) || (gfp_mask & (__GFP_DIRECT_RECLAIM | GFP_DMA))) { skb = __alloc_skb(len, gfp_mask, SKB_ALLOC_RX, NUMA_NO_NODE); if (!skb) @@ -494,6 +498,7 @@ struct sk_buff *__napi_alloc_skb(struct napi_struct *napi, unsigned int len, goto skb_success; } + nc = this_cpu_ptr(&napi_alloc_cache); len += SKB_DATA_ALIGN(sizeof(struct skb_shared_info)); len = SKB_DATA_ALIGN(len); diff --git a/net/dcb/dcbnl.c b/net/dcb/dcbnl.c index 6fe2b615518c..426c30f9fdb0 100644 --- a/net/dcb/dcbnl.c +++ b/net/dcb/dcbnl.c @@ -1725,6 +1725,8 @@ static int dcb_doit(struct sk_buff *skb, struct nlmsghdr *nlh) fn = &reply_funcs[dcb->cmd]; if (!fn->cb) return -EOPNOTSUPP; + if (fn->type == RTM_SETDCB && !netlink_capable(skb, CAP_NET_ADMIN)) + return -EPERM; if (!tb[DCB_ATTR_IFNAME]) return -EINVAL; diff --git a/net/ipv6/sit.c b/net/ipv6/sit.c index 8bab7e64ffcf..1ee190137da4 100644 --- a/net/ipv6/sit.c +++ b/net/ipv6/sit.c @@ -1584,8 +1584,11 @@ static int ipip6_newlink(struct net *src_net, struct net_device *dev, } #ifdef CONFIG_IPV6_SIT_6RD - if (ipip6_netlink_6rd_parms(data, &ip6rd)) + if (ipip6_netlink_6rd_parms(data, &ip6rd)) { err = ipip6_tunnel_update_6rd(nt, &ip6rd); + if (err < 0) + unregister_netdevice_queue(dev, NULL); + } #endif return err; diff --git a/net/rxrpc/ar-key.c b/net/rxrpc/ar-key.c index ea615e53eab2..f4ad63d6e540 100644 --- a/net/rxrpc/ar-key.c +++ b/net/rxrpc/ar-key.c @@ -1116,7 +1116,7 @@ static long rxrpc_read(const struct key *key, default: /* we have a ticket we can't encode */ pr_err("Unsupported key token type (%u)\n", token->security_index); - continue; + return -ENOPKG; } _debug("token[%u]: toksize=%u", ntoks, toksize); @@ -1236,7 +1236,9 @@ static long rxrpc_read(const struct key *key, break; default: - break; + pr_err("Unsupported key token type (%u)\n", + token->security_index); + return -ENOPKG; } ASSERTCMP((unsigned long)xdr - (unsigned long)oldxdr, ==, diff --git a/net/sunrpc/addr.c b/net/sunrpc/addr.c index 8391c2785550..7404f02702a1 100644 --- a/net/sunrpc/addr.c +++ b/net/sunrpc/addr.c @@ -184,7 +184,7 @@ static int rpc_parse_scope_id(struct net *net, const char *buf, scope_id = dev->ifindex; dev_put(dev); } else { - if (kstrtou32(p, 10, &scope_id) == 0) { + if (kstrtou32(p, 10, &scope_id) != 0) { kfree(p); return 0; } |
