History

Merge drm/drm-next into drm-misc-next

Picking up v5.0 + missed misc-fixes from last release

Sean Paul committed 7 years ago

Commit cd7d3a12 parents 6b5c029 4b057e7545 files · +8028 −4060Browse files

Showing the changes to include/linux (7 of 545 files). Show all

Unified · Split

7 files
  1. include/linux/key-type.h +6 −16
  2. include/linux/netdev_features.h +22 −2
  3. include/linux/netdevice.h +1 −1
  4. include/linux/phy.h +8 −0
  5. include/linux/sched.h +0 −6
  6. include/linux/skbuff.h +7 −1
  7. include/linux/virtio_net.h +19 −0
include/linux/key-type.h+6−16
@@ -20,15 +20,6 @@ · 19 unmodified lines
20struct kernel_pkey_query;20struct kernel_pkey_query;
21struct kernel_pkey_params;21struct kernel_pkey_params;
22 22
23/*
24 * key under-construction record
25 * - passed to the request_key actor if supplied
26 */
27struct key_construction {
28 struct key *key; /* key being constructed */
29 struct key *authkey;/* authorisation for key being constructed */
30};
31
32/*23/*
33 * Pre-parsed payload, used by key add, update and instantiate.24 * Pre-parsed payload, used by key add, update and instantiate.
34 *25 *
@@ -50,8 +41,7 @@ struct key_preparsed_payload { · 15 unmodified lines
50 time64_t expiry; /* Expiry time of key */41 time64_t expiry; /* Expiry time of key */
51} __randomize_layout;42} __randomize_layout;
52 43
53typedef int (*request_key_actor_t)(struct key_construction *key,44typedef int (*request_key_actor_t)(struct key *auth_key, void *aux);
54 const char *op, void *aux);
55 45
56/*46/*
57 * Preparsed matching criterion.47 * Preparsed matching criterion.
@@ -181,20 +171,20 @@ extern int key_instantiate_and_link(struct key *key, · 123 unmodified lines
181 const void *data,171 const void *data,
182 size_t datalen,172 size_t datalen,
183 struct key *keyring,173 struct key *keyring,
184 struct key *instkey);174 struct key *authkey);
185extern int key_reject_and_link(struct key *key,175extern int key_reject_and_link(struct key *key,
186 unsigned timeout,176 unsigned timeout,
187 unsigned error,177 unsigned error,
188 struct key *keyring,178 struct key *keyring,
189 struct key *instkey);179 struct key *authkey);
190extern void complete_request_key(struct key_construction *cons, int error);180extern void complete_request_key(struct key *authkey, int error);
191 181
192static inline int key_negate_and_link(struct key *key,182static inline int key_negate_and_link(struct key *key,
193 unsigned timeout,183 unsigned timeout,
194 struct key *keyring,184 struct key *keyring,
195 struct key *instkey)185 struct key *authkey)
196{186{
197 return key_reject_and_link(key, timeout, ENOKEY, keyring, instkey);187 return key_reject_and_link(key, timeout, ENOKEY, keyring, authkey);
198}188}
199 189
200extern int generic_key_instantiate(struct key *key, struct key_preparsed_payload *prep);190extern int generic_key_instantiate(struct key *key, struct key_preparsed_payload *prep);
include/linux/netdev_features.h+22−2
@@ -11,6 +11,8 @@ · 10 unmodified lines
11#define _LINUX_NETDEV_FEATURES_H11#define _LINUX_NETDEV_FEATURES_H
12 12
13#include <linux/types.h>13#include <linux/types.h>
14#include <linux/bitops.h>
15#include <asm/byteorder.h>
14 16
15typedef u64 netdev_features_t;17typedef u64 netdev_features_t;
16 18
@@ -154,8 +156,26 @@ enum { · 137 unmodified lines
154#define NETIF_F_HW_TLS_TX __NETIF_F(HW_TLS_TX)156#define NETIF_F_HW_TLS_TX __NETIF_F(HW_TLS_TX)
155#define NETIF_F_HW_TLS_RX __NETIF_F(HW_TLS_RX)157#define NETIF_F_HW_TLS_RX __NETIF_F(HW_TLS_RX)
156 158
157#define for_each_netdev_feature(mask_addr, bit) \159/* Finds the next feature with the highest number of the range of start till 0.
158 for_each_set_bit(bit, (unsigned long *)mask_addr, NETDEV_FEATURE_COUNT)160 */
161static inline int find_next_netdev_feature(u64 feature, unsigned long start)
162{
163 /* like BITMAP_LAST_WORD_MASK() for u64
164 * this sets the most significant 64 - start to 0.
165 */
166 feature &= ~0ULL >> (-start & ((sizeof(feature) * 8) - 1));
167
168 return fls64(feature) - 1;
169}
170
171/* This goes for the MSB to the LSB through the set feature bits,
172 * mask_addr should be a u64 and bit an int
173 */
174#define for_each_netdev_feature(mask_addr, bit) \
175 for ((bit) = find_next_netdev_feature((mask_addr), \
176 NETDEV_FEATURE_COUNT); \
177 (bit) >= 0; \
178 (bit) = find_next_netdev_feature((mask_addr), (bit) - 1))
159 179
160/* Features valid for ethtool to change */180/* Features valid for ethtool to change */
161/* = all defined minus driver/device-class-related */181/* = all defined minus driver/device-class-related */
include/linux/netdevice.h+1−1
@@ -3861,7 +3861,7 @@ static inline u32 netif_msg_init(int debug_value, int default_msg_enable_bits) · 3860 unmodified lines
3861 if (debug_value == 0) /* no output */3861 if (debug_value == 0) /* no output */
3862 return 0;3862 return 0;
3863 /* set low N bits */3863 /* set low N bits */
3864 return (1 << debug_value) - 1;3864 return (1U << debug_value) - 1;
3865}3865}
3866 3866
3867static inline void __netif_tx_lock(struct netdev_queue *txq, int cpu)3867static inline void __netif_tx_lock(struct netdev_queue *txq, int cpu)
include/linux/phy.h+8−0
@@ -992,6 +992,14 @@ static inline int genphy_no_soft_reset(struct phy_device *phydev) · 991 unmodified lines
992{992{
993 return 0;993 return 0;
994}994}
995static inline int genphy_no_ack_interrupt(struct phy_device *phydev)
996{
997 return 0;
998}
999static inline int genphy_no_config_intr(struct phy_device *phydev)
1000{
1001 return 0;
1002}
995int genphy_read_mmd_unsupported(struct phy_device *phdev, int devad,1003int genphy_read_mmd_unsupported(struct phy_device *phdev, int devad,
996 u16 regnum);1004 u16 regnum);
997int genphy_write_mmd_unsupported(struct phy_device *phdev, int devnum,1005int genphy_write_mmd_unsupported(struct phy_device *phdev, int devnum,
include/linux/sched.h+0−6
@@ -739,12 +739,6 @@ struct task_struct { · 738 unmodified lines
739 unsigned use_memdelay:1;739 unsigned use_memdelay:1;
740#endif740#endif
741 741
742 /*
743 * May usercopy functions fault on kernel addresses?
744 * This is not just a single bit because this can potentially nest.
745 */
746 unsigned int kernel_uaccess_faults_ok;
747
748 unsigned long atomic_flags; /* Flags requiring atomic access. */742 unsigned long atomic_flags; /* Flags requiring atomic access. */
749 743
750 struct restart_block restart_block;744 struct restart_block restart_block;
include/linux/skbuff.h+7−1
@@ -2434,7 +2434,7 @@ static inline void skb_probe_transport_header(struct sk_buff *skb, · 2433 unmodified lines
2434 2434
2435 if (skb_flow_dissect_flow_keys_basic(skb, &keys, NULL, 0, 0, 0, 0))2435 if (skb_flow_dissect_flow_keys_basic(skb, &keys, NULL, 0, 0, 0, 0))
2436 skb_set_transport_header(skb, keys.control.thoff);2436 skb_set_transport_header(skb, keys.control.thoff);
2437 else2437 else if (offset_hint >= 0)
2438 skb_set_transport_header(skb, offset_hint);2438 skb_set_transport_header(skb, offset_hint);
2439}2439}
2440 2440
@@ -4212,6 +4212,12 @@ static inline bool skb_is_gso_sctp(const struct sk_buff *skb) · 1771 unmodified lines
4212 return skb_shinfo(skb)->gso_type & SKB_GSO_SCTP;4212 return skb_shinfo(skb)->gso_type & SKB_GSO_SCTP;
4213}4213}
4214 4214
4215static inline bool skb_is_gso_tcp(const struct sk_buff *skb)
4216{
4217 return skb_is_gso(skb) &&
4218 skb_shinfo(skb)->gso_type & (SKB_GSO_TCPV4 | SKB_GSO_TCPV6);
4219}
4220
4215static inline void skb_gso_reset(struct sk_buff *skb)4221static inline void skb_gso_reset(struct sk_buff *skb)
4216{4222{
4217 skb_shinfo(skb)->gso_size = 0;4223 skb_shinfo(skb)->gso_size = 0;
include/linux/virtio_net.h+19−0
@@ -57,6 +57,25 @@ static inline int virtio_net_hdr_to_skb(struct sk_buff *skb, · 56 unmodified lines
57 57
58 if (!skb_partial_csum_set(skb, start, off))58 if (!skb_partial_csum_set(skb, start, off))
59 return -EINVAL;59 return -EINVAL;
60 } else {
61 /* gso packets without NEEDS_CSUM do not set transport_offset.
62 * probe and drop if does not match one of the above types.
63 */
64 if (gso_type && skb->network_header) {
65 if (!skb->protocol)
66 virtio_net_hdr_set_proto(skb, hdr);
67retry:
68 skb_probe_transport_header(skb, -1);
69 if (!skb_transport_header_was_set(skb)) {
70 /* UFO does not specify ipv4 or 6: try both */
71 if (gso_type & SKB_GSO_UDP &&
72 skb->protocol == htons(ETH_P_IP)) {
73 skb->protocol = htons(ETH_P_IPV6);
74 goto retry;
75 }
76 return -EINVAL;
77 }
78 }
60 }79 }
61 80
62 if (hdr->gso_type != VIRTIO_NET_HDR_GSO_NONE) {81 if (hdr->gso_type != VIRTIO_NET_HDR_GSO_NONE) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t