mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2025-10-22 23:13:01 +02:00
Merge branch 'v5.7/standard/base' into v5.7/standard/cn96xx
This commit is contained in:
commit
3ec171bfb4
2
Makefile
2
Makefile
|
@ -1,7 +1,7 @@
|
|||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 7
|
||||
SUBLEVEL = 18
|
||||
SUBLEVEL = 19
|
||||
EXTRAVERSION =
|
||||
NAME = Kleptomaniac Octopus
|
||||
|
||||
|
|
|
@ -184,7 +184,7 @@ __init_LPCR_ISA300:
|
|||
|
||||
__init_FSCR:
|
||||
mfspr r3,SPRN_FSCR
|
||||
ori r3,r3,FSCR_TAR|FSCR_DSCR|FSCR_EBB
|
||||
ori r3,r3,FSCR_TAR|FSCR_EBB
|
||||
mtspr SPRN_FSCR,r3
|
||||
blr
|
||||
|
||||
|
|
|
@ -3594,7 +3594,7 @@ static int check_missing_comp_in_tx_queue(struct ena_adapter *adapter,
|
|||
}
|
||||
|
||||
u64_stats_update_begin(&tx_ring->syncp);
|
||||
tx_ring->tx_stats.missed_tx = missed_tx;
|
||||
tx_ring->tx_stats.missed_tx += missed_tx;
|
||||
u64_stats_update_end(&tx_ring->syncp);
|
||||
|
||||
return rc;
|
||||
|
@ -4519,6 +4519,9 @@ static void ena_keep_alive_wd(void *adapter_data,
|
|||
rx_drops = ((u64)desc->rx_drops_high << 32) | desc->rx_drops_low;
|
||||
|
||||
u64_stats_update_begin(&adapter->syncp);
|
||||
/* These stats are accumulated by the device, so the counters indicate
|
||||
* all drops since last reset.
|
||||
*/
|
||||
adapter->dev_stats.rx_drops = rx_drops;
|
||||
u64_stats_update_end(&adapter->syncp);
|
||||
}
|
||||
|
|
|
@ -571,7 +571,7 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
goto err;
|
||||
}
|
||||
|
||||
len = data_len + extra;
|
||||
len = data_len + extra + MAX_SHARED_LIBS * sizeof(unsigned long);
|
||||
len = PAGE_ALIGN(len);
|
||||
realdatastart = vm_mmap(NULL, 0, len,
|
||||
PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE, 0);
|
||||
|
@ -585,7 +585,9 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
vm_munmap(textpos, text_len);
|
||||
goto err;
|
||||
}
|
||||
datapos = ALIGN(realdatastart, FLAT_DATA_ALIGN);
|
||||
datapos = ALIGN(realdatastart +
|
||||
MAX_SHARED_LIBS * sizeof(unsigned long),
|
||||
FLAT_DATA_ALIGN);
|
||||
|
||||
pr_debug("Allocated data+bss+stack (%u bytes): %lx\n",
|
||||
data_len + bss_len + stack_len, datapos);
|
||||
|
@ -615,7 +617,7 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
memp_size = len;
|
||||
} else {
|
||||
|
||||
len = text_len + data_len + extra;
|
||||
len = text_len + data_len + extra + MAX_SHARED_LIBS * sizeof(u32);
|
||||
len = PAGE_ALIGN(len);
|
||||
textpos = vm_mmap(NULL, 0, len,
|
||||
PROT_READ | PROT_EXEC | PROT_WRITE, MAP_PRIVATE, 0);
|
||||
|
@ -630,7 +632,9 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
}
|
||||
|
||||
realdatastart = textpos + ntohl(hdr->data_start);
|
||||
datapos = ALIGN(realdatastart, FLAT_DATA_ALIGN);
|
||||
datapos = ALIGN(realdatastart +
|
||||
MAX_SHARED_LIBS * sizeof(u32),
|
||||
FLAT_DATA_ALIGN);
|
||||
|
||||
reloc = (__be32 __user *)
|
||||
(datapos + (ntohl(hdr->reloc_start) - text_len));
|
||||
|
@ -647,9 +651,8 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
(text_len + full_data
|
||||
- sizeof(struct flat_hdr)),
|
||||
0);
|
||||
if (datapos != realdatastart)
|
||||
memmove((void *)datapos, (void *)realdatastart,
|
||||
full_data);
|
||||
memmove((void *) datapos, (void *) realdatastart,
|
||||
full_data);
|
||||
#else
|
||||
/*
|
||||
* This is used on MMU systems mainly for testing.
|
||||
|
@ -705,7 +708,8 @@ static int load_flat_file(struct linux_binprm *bprm,
|
|||
if (IS_ERR_VALUE(result)) {
|
||||
ret = result;
|
||||
pr_err("Unable to read code+data+bss, errno %d\n", ret);
|
||||
vm_munmap(textpos, text_len + data_len + extra);
|
||||
vm_munmap(textpos, text_len + data_len + extra +
|
||||
MAX_SHARED_LIBS * sizeof(u32));
|
||||
goto err;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5421,8 +5421,8 @@ struct sk_buff *skb_vlan_untag(struct sk_buff *skb)
|
|||
skb = skb_share_check(skb, GFP_ATOMIC);
|
||||
if (unlikely(!skb))
|
||||
goto err_free;
|
||||
|
||||
if (unlikely(!pskb_may_pull(skb, VLAN_HLEN)))
|
||||
/* We may access the two bytes after vlan_hdr in vlan_set_encap_proto(). */
|
||||
if (unlikely(!pskb_may_pull(skb, VLAN_HLEN + sizeof(unsigned short))))
|
||||
goto err_free;
|
||||
|
||||
vhdr = (struct vlan_hdr *)skb->data;
|
||||
|
|
|
@ -224,7 +224,9 @@ int ethnl_set_features(struct sk_buff *skb, struct genl_info *info)
|
|||
DECLARE_BITMAP(wanted_diff_mask, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(active_diff_mask, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(old_active, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(old_wanted, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(new_active, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(new_wanted, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(req_wanted, NETDEV_FEATURE_COUNT);
|
||||
DECLARE_BITMAP(req_mask, NETDEV_FEATURE_COUNT);
|
||||
struct nlattr *tb[ETHTOOL_A_FEATURES_MAX + 1];
|
||||
|
@ -250,6 +252,7 @@ int ethnl_set_features(struct sk_buff *skb, struct genl_info *info)
|
|||
|
||||
rtnl_lock();
|
||||
ethnl_features_to_bitmap(old_active, dev->features);
|
||||
ethnl_features_to_bitmap(old_wanted, dev->wanted_features);
|
||||
ret = ethnl_parse_bitset(req_wanted, req_mask, NETDEV_FEATURE_COUNT,
|
||||
tb[ETHTOOL_A_FEATURES_WANTED],
|
||||
netdev_features_strings, info->extack);
|
||||
|
@ -261,17 +264,15 @@ int ethnl_set_features(struct sk_buff *skb, struct genl_info *info)
|
|||
goto out_rtnl;
|
||||
}
|
||||
|
||||
/* set req_wanted bits not in req_mask from old_active */
|
||||
/* set req_wanted bits not in req_mask from old_wanted */
|
||||
bitmap_and(req_wanted, req_wanted, req_mask, NETDEV_FEATURE_COUNT);
|
||||
bitmap_andnot(new_active, old_active, req_mask, NETDEV_FEATURE_COUNT);
|
||||
bitmap_or(req_wanted, new_active, req_wanted, NETDEV_FEATURE_COUNT);
|
||||
if (bitmap_equal(req_wanted, old_active, NETDEV_FEATURE_COUNT)) {
|
||||
ret = 0;
|
||||
goto out_rtnl;
|
||||
bitmap_andnot(new_wanted, old_wanted, req_mask, NETDEV_FEATURE_COUNT);
|
||||
bitmap_or(req_wanted, new_wanted, req_wanted, NETDEV_FEATURE_COUNT);
|
||||
if (!bitmap_equal(req_wanted, old_wanted, NETDEV_FEATURE_COUNT)) {
|
||||
dev->wanted_features &= ~dev->hw_features;
|
||||
dev->wanted_features |= ethnl_bitmap_to_features(req_wanted) & dev->hw_features;
|
||||
__netdev_update_features(dev);
|
||||
}
|
||||
|
||||
dev->wanted_features = ethnl_bitmap_to_features(req_wanted);
|
||||
__netdev_update_features(dev);
|
||||
ethnl_features_to_bitmap(new_active, dev->features);
|
||||
mod = !bitmap_equal(old_active, new_active, NETDEV_FEATURE_COUNT);
|
||||
|
||||
|
|
|
@ -402,7 +402,7 @@ static int nh_check_attr_group(struct net *net, struct nlattr *tb[],
|
|||
struct nexthop_grp *nhg;
|
||||
unsigned int i, j;
|
||||
|
||||
if (len & (sizeof(struct nexthop_grp) - 1)) {
|
||||
if (!len || len & (sizeof(struct nexthop_grp) - 1)) {
|
||||
NL_SET_ERR_MSG(extack,
|
||||
"Invalid length for nexthop group attribute");
|
||||
return -EINVAL;
|
||||
|
@ -1104,6 +1104,9 @@ static struct nexthop *nexthop_create_group(struct net *net,
|
|||
struct nexthop *nh;
|
||||
int i;
|
||||
|
||||
if (WARN_ON(!num_nh))
|
||||
return ERR_PTR(-EINVAL);
|
||||
|
||||
nh = nexthop_alloc();
|
||||
if (!nh)
|
||||
return ERR_PTR(-ENOMEM);
|
||||
|
|
|
@ -886,7 +886,15 @@ int ip6_tnl_rcv(struct ip6_tnl *t, struct sk_buff *skb,
|
|||
struct metadata_dst *tun_dst,
|
||||
bool log_ecn_err)
|
||||
{
|
||||
return __ip6_tnl_rcv(t, skb, tpi, tun_dst, ip6ip6_dscp_ecn_decapsulate,
|
||||
int (*dscp_ecn_decapsulate)(const struct ip6_tnl *t,
|
||||
const struct ipv6hdr *ipv6h,
|
||||
struct sk_buff *skb);
|
||||
|
||||
dscp_ecn_decapsulate = ip6ip6_dscp_ecn_decapsulate;
|
||||
if (tpi->proto == htons(ETH_P_IP))
|
||||
dscp_ecn_decapsulate = ip4ip6_dscp_ecn_decapsulate;
|
||||
|
||||
return __ip6_tnl_rcv(t, skb, tpi, tun_dst, dscp_ecn_decapsulate,
|
||||
log_ecn_err);
|
||||
}
|
||||
EXPORT_SYMBOL(ip6_tnl_rcv);
|
||||
|
|
|
@ -692,23 +692,25 @@ static void qrtr_port_remove(struct qrtr_sock *ipc)
|
|||
*/
|
||||
static int qrtr_port_assign(struct qrtr_sock *ipc, int *port)
|
||||
{
|
||||
u32 min_port;
|
||||
int rc;
|
||||
|
||||
mutex_lock(&qrtr_port_lock);
|
||||
if (!*port) {
|
||||
rc = idr_alloc(&qrtr_ports, ipc,
|
||||
QRTR_MIN_EPH_SOCKET, QRTR_MAX_EPH_SOCKET + 1,
|
||||
GFP_ATOMIC);
|
||||
if (rc >= 0)
|
||||
*port = rc;
|
||||
min_port = QRTR_MIN_EPH_SOCKET;
|
||||
rc = idr_alloc_u32(&qrtr_ports, ipc, &min_port, QRTR_MAX_EPH_SOCKET, GFP_ATOMIC);
|
||||
if (!rc)
|
||||
*port = min_port;
|
||||
} else if (*port < QRTR_MIN_EPH_SOCKET && !capable(CAP_NET_ADMIN)) {
|
||||
rc = -EACCES;
|
||||
} else if (*port == QRTR_PORT_CTRL) {
|
||||
rc = idr_alloc(&qrtr_ports, ipc, 0, 1, GFP_ATOMIC);
|
||||
min_port = 0;
|
||||
rc = idr_alloc_u32(&qrtr_ports, ipc, &min_port, 0, GFP_ATOMIC);
|
||||
} else {
|
||||
rc = idr_alloc(&qrtr_ports, ipc, *port, *port + 1, GFP_ATOMIC);
|
||||
if (rc >= 0)
|
||||
*port = rc;
|
||||
min_port = *port;
|
||||
rc = idr_alloc_u32(&qrtr_ports, ipc, &min_port, *port, GFP_ATOMIC);
|
||||
if (!rc)
|
||||
*port = min_port;
|
||||
}
|
||||
mutex_unlock(&qrtr_port_lock);
|
||||
|
||||
|
|
|
@ -702,7 +702,7 @@ static int tcf_ct_handle_fragments(struct net *net, struct sk_buff *skb,
|
|||
err = ip_defrag(net, skb, user);
|
||||
local_bh_enable();
|
||||
if (err && err != -EINPROGRESS)
|
||||
goto out_free;
|
||||
return err;
|
||||
|
||||
if (!err) {
|
||||
*defrag = true;
|
||||
|
|
|
@ -88,12 +88,13 @@ static int sctp_stream_alloc_out(struct sctp_stream *stream, __u16 outcnt,
|
|||
int ret;
|
||||
|
||||
if (outcnt <= stream->outcnt)
|
||||
return 0;
|
||||
goto out;
|
||||
|
||||
ret = genradix_prealloc(&stream->out, outcnt, gfp);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
out:
|
||||
stream->outcnt = outcnt;
|
||||
return 0;
|
||||
}
|
||||
|
@ -104,12 +105,13 @@ static int sctp_stream_alloc_in(struct sctp_stream *stream, __u16 incnt,
|
|||
int ret;
|
||||
|
||||
if (incnt <= stream->incnt)
|
||||
return 0;
|
||||
goto out;
|
||||
|
||||
ret = genradix_prealloc(&stream->in, incnt, gfp);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
out:
|
||||
stream->incnt = incnt;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -170,13 +170,15 @@ static int __smc_diag_dump(struct sock *sk, struct sk_buff *skb,
|
|||
(req->diag_ext & (1 << (SMC_DIAG_DMBINFO - 1))) &&
|
||||
!list_empty(&smc->conn.lgr->list)) {
|
||||
struct smc_connection *conn = &smc->conn;
|
||||
struct smcd_diag_dmbinfo dinfo = {
|
||||
.linkid = *((u32 *)conn->lgr->id),
|
||||
.peer_gid = conn->lgr->peer_gid,
|
||||
.my_gid = conn->lgr->smcd->local_gid,
|
||||
.token = conn->rmb_desc->token,
|
||||
.peer_token = conn->peer_token
|
||||
};
|
||||
struct smcd_diag_dmbinfo dinfo;
|
||||
|
||||
memset(&dinfo, 0, sizeof(dinfo));
|
||||
|
||||
dinfo.linkid = *((u32 *)conn->lgr->id);
|
||||
dinfo.peer_gid = conn->lgr->peer_gid;
|
||||
dinfo.my_gid = conn->lgr->smcd->local_gid;
|
||||
dinfo.token = conn->rmb_desc->token;
|
||||
dinfo.peer_token = conn->peer_token;
|
||||
|
||||
if (nla_put(skb, SMC_DIAG_DMBINFO, sizeof(dinfo), &dinfo) < 0)
|
||||
goto errout;
|
||||
|
|
|
@ -757,10 +757,12 @@ static void tipc_aead_encrypt_done(struct crypto_async_request *base, int err)
|
|||
switch (err) {
|
||||
case 0:
|
||||
this_cpu_inc(tx->stats->stat[STAT_ASYNC_OK]);
|
||||
rcu_read_lock();
|
||||
if (likely(test_bit(0, &b->up)))
|
||||
b->media->send_msg(net, skb, b, &tx_ctx->dst);
|
||||
else
|
||||
kfree_skb(skb);
|
||||
rcu_read_unlock();
|
||||
break;
|
||||
case -EINPROGRESS:
|
||||
return;
|
||||
|
|
|
@ -275,8 +275,9 @@ err_out:
|
|||
static int tipc_nl_compat_dumpit(struct tipc_nl_compat_cmd_dump *cmd,
|
||||
struct tipc_nl_compat_msg *msg)
|
||||
{
|
||||
int err;
|
||||
struct nlmsghdr *nlh;
|
||||
struct sk_buff *arg;
|
||||
int err;
|
||||
|
||||
if (msg->req_type && (!msg->req_size ||
|
||||
!TLV_CHECK_TYPE(msg->req, msg->req_type)))
|
||||
|
@ -305,6 +306,15 @@ static int tipc_nl_compat_dumpit(struct tipc_nl_compat_cmd_dump *cmd,
|
|||
return -ENOMEM;
|
||||
}
|
||||
|
||||
nlh = nlmsg_put(arg, 0, 0, tipc_genl_family.id, 0, NLM_F_MULTI);
|
||||
if (!nlh) {
|
||||
kfree_skb(arg);
|
||||
kfree_skb(msg->rep);
|
||||
msg->rep = NULL;
|
||||
return -EMSGSIZE;
|
||||
}
|
||||
nlmsg_end(arg, nlh);
|
||||
|
||||
err = __tipc_nl_compat_dumpit(cmd, msg, arg);
|
||||
if (err) {
|
||||
kfree_skb(msg->rep);
|
||||
|
|
Loading…
Reference in New Issue
Block a user