History

Merge tag 'v5.5-rc3' into sched/core, to pick up fixes

Ingo Molnar committed 6 years ago

Commit 1e5f8a32 parents a5e37de 46cf0532365 files · +73743 −24048Browse files

Showing the changes to include/linux (89 of 2365 files). Show all

Unified · Split

89 files
  1. include/linux/agpgart.h +0 −2
  2. include/linux/bitmap.h +51 −0
  3. include/linux/bitops.h +12 −0
  4. include/linux/blk-cgroup.h +0 −2
  5. include/linux/blkdev.h +10 −14
  6. include/linux/bpf-cgroup.h +4 −4
  7. include/linux/bpf.h +3 −0
  8. include/linux/build_bug.h +2 −2
  9. include/linux/bvec.h +10 −12
  10. include/linux/ceph/libceph.h +6 −4
  11. include/linux/cpu_cooling.h +8 −10
  12. include/linux/cpufreq.h +0 −11
  13. include/linux/cpuidle.h +1 −1
  14. include/linux/dcache.h +5 −0
  15. include/linux/devfreq.h +10 −4
  16. include/linux/device.h +2 −2
  17. include/linux/efi.h +5 −5
  18. include/linux/energy_model.h +1 −2
  19. include/linux/export.h +28 −63
  20. include/linux/filter.h +12 −8
  21. include/linux/firmware/meson/meson_sm.h +9 −6
  22. include/linux/firmware/xlnx-zynqmp.h +2 −1
  23. include/linux/ftrace.h +5 −0
  24. include/linux/genalloc.h +1 −1
  25. include/linux/i2c.h +6 −6
  26. include/linux/initrd.h +2 −0
  27. include/linux/jbd2.h +1 −1
  28. include/linux/kasan.h +9 −6
  29. include/linux/kcov.h +23 −0
  30. include/linux/kernel.h +14 −5
  31. include/linux/kvm_host.h +1 −1
  32. include/linux/lockd/debug.h +0 −4
  33. include/linux/lockd/lockd.h +0 −4
  34. include/linux/logic_pio.h +2 −2
  35. include/linux/mfd/stm32-timers.h +4 −8
  36. include/linux/mfd/syscon/atmel-matrix.h +0 −1
  37. include/linux/miscdevice.h +1 −0
  38. include/linux/mm.h +8 −5
  39. include/linux/mod_devicetable.h +2 −2
  40. include/linux/moduleparam.h +2 −2
  41. include/linux/namei.h +1 −0
  42. include/linux/netdevice.h +6 −1
  43. include/linux/nfs4.h +26 −0
  44. include/linux/nfs_fs.h +3 −1
  45. include/linux/nfs_fs_sb.h +5 −1
  46. include/linux/nfs_xdr.h +24 −7
  47. include/linux/notifier.h +0 −4
  48. include/linux/nvme-fc-driver.h +4 −0
  49. include/linux/of_mdio.h +6 −0
  50. include/linux/phy.h +1 −1
  51. include/linux/phy_led_triggers.h +1 −1
  52. include/linux/pipe_fs_i.h +0 −2
  53. include/linux/platform_data/ti-prm.h +21 −0
  54. include/linux/platform_data/ti-sysc.h +2 −0
  55. include/linux/pm_qos.h +50 −36
  56. include/linux/pm_wakeup.h +9 −0
  57. include/linux/printk.h +1 −2
  58. include/linux/proc_fs.h +2 −2
  59. include/linux/pwm.h +1 −4
  60. include/linux/qcom_scm.h +26 −0
  61. include/linux/rbtree_augmented.h +2 −4
  62. include/linux/rculist_nulls.h +37 −0
  63. include/linux/reset-controller.h +2 −1
  64. include/linux/reset.h +46 −0
  65. include/linux/sched.h +8 −0
  66. include/linux/sched/cpufreq.h +3 −0
  67. include/linux/skbuff.h +3 −2
  68. include/linux/soc/mmp/cputype.h +87 −0
  69. include/linux/soc/qcom/llcc-qcom.h +20 −74
  70. include/linux/socket.h +13 −7
  71. include/linux/sunrpc/auth.h +0 −3
  72. include/linux/sunrpc/auth_gss.h +0 −2
  73. include/linux/sunrpc/clnt.h +1 −3
  74. include/linux/sunrpc/gss_api.h +0 −2
  75. include/linux/sunrpc/gss_err.h +0 −3
  76. include/linux/sunrpc/msg_prot.h +0 −3
  77. include/linux/sunrpc/rpc_pipe_fs.h +0 −3
  78. include/linux/sunrpc/svcauth.h +0 −4
  79. include/linux/sunrpc/svcauth_gss.h +0 −2
  80. include/linux/sunrpc/xdr.h +0 −3
  81. include/linux/sunrpc/xprt.h +2 −5
  82. include/linux/sunrpc/xprtsock.h +0 −4
  83. include/linux/syscalls.h +0 −3
  84. include/linux/sysctl.h +2 −4
  85. include/linux/thermal.h +0 −11
  86. include/linux/thread_info.h +2 −0
  87. include/linux/time.h +13 −0
  88. include/linux/tpm.h +1 −0
  89. include/linux/vmstat.h +50 −0
include/linux/agpgart.h+0−2
@@ -30,8 +30,6 @@ · 29 unmodified lines
30#include <linux/agp_backend.h>30#include <linux/agp_backend.h>
31#include <uapi/linux/agpgart.h>31#include <uapi/linux/agpgart.h>
32 32
33#define AGPGART_MINOR 175
34
35struct agp_info {33struct agp_info {
36 struct agp_version version; /* version of the driver */34 struct agp_version version; /* version of the driver */
37 u32 bridge_id; /* bridge vendor/device */35 u32 bridge_id; /* bridge vendor/device */
include/linux/bitmap.h+51−0
@@ -53,6 +53,7 @@ · 52 unmodified lines
53 * bitmap_find_next_zero_area_off(buf, len, pos, n, mask) as above53 * bitmap_find_next_zero_area_off(buf, len, pos, n, mask) as above
54 * bitmap_shift_right(dst, src, n, nbits) *dst = *src >> n54 * bitmap_shift_right(dst, src, n, nbits) *dst = *src >> n
55 * bitmap_shift_left(dst, src, n, nbits) *dst = *src << n55 * bitmap_shift_left(dst, src, n, nbits) *dst = *src << n
56 * bitmap_replace(dst, old, new, mask, nbits) *dst = (*old & ~(*mask)) | (*new & *mask)
56 * bitmap_remap(dst, src, old, new, nbits) *dst = map(old, new)(src)57 * bitmap_remap(dst, src, old, new, nbits) *dst = map(old, new)(src)
57 * bitmap_bitremap(oldbit, old, new, nbits) newbit = map(old, new)(oldbit)58 * bitmap_bitremap(oldbit, old, new, nbits) newbit = map(old, new)(oldbit)
58 * bitmap_onto(dst, orig, relmap, nbits) *dst = orig relative to relmap59 * bitmap_onto(dst, orig, relmap, nbits) *dst = orig relative to relmap
@@ -66,6 +67,8 @@ · 7 unmodified lines
66 * bitmap_allocate_region(bitmap, pos, order) Allocate specified bit region67 * bitmap_allocate_region(bitmap, pos, order) Allocate specified bit region
67 * bitmap_from_arr32(dst, buf, nbits) Copy nbits from u32[] buf to dst68 * bitmap_from_arr32(dst, buf, nbits) Copy nbits from u32[] buf to dst
68 * bitmap_to_arr32(buf, src, nbits) Copy nbits from buf to u32[] dst69 * bitmap_to_arr32(buf, src, nbits) Copy nbits from buf to u32[] dst
70 * bitmap_get_value8(map, start) Get 8bit value from map at start
71 * bitmap_set_value8(map, value, start) Set 8bit value to map at start
69 *72 *
70 * Note, bitmap_zero() and bitmap_fill() operate over the region of73 * Note, bitmap_zero() and bitmap_fill() operate over the region of
71 * unsigned longs, that is, bits behind bitmap till the unsigned long74 * unsigned longs, that is, bits behind bitmap till the unsigned long
@@ -138,6 +141,9 @@ extern void __bitmap_xor(unsigned long *dst, const unsigned long *bitmap1, · 66 unmodified lines
138 const unsigned long *bitmap2, unsigned int nbits);141 const unsigned long *bitmap2, unsigned int nbits);
139extern int __bitmap_andnot(unsigned long *dst, const unsigned long *bitmap1,142extern int __bitmap_andnot(unsigned long *dst, const unsigned long *bitmap1,
140 const unsigned long *bitmap2, unsigned int nbits);143 const unsigned long *bitmap2, unsigned int nbits);
144extern void __bitmap_replace(unsigned long *dst,
145 const unsigned long *old, const unsigned long *new,
146 const unsigned long *mask, unsigned int nbits);
141extern int __bitmap_intersects(const unsigned long *bitmap1,147extern int __bitmap_intersects(const unsigned long *bitmap1,
142 const unsigned long *bitmap2, unsigned int nbits);148 const unsigned long *bitmap2, unsigned int nbits);
143extern int __bitmap_subset(const unsigned long *bitmap1,149extern int __bitmap_subset(const unsigned long *bitmap1,
@@ -432,6 +438,18 @@ static inline void bitmap_shift_left(unsigned long *dst, const unsigned long *sr · 288 unmodified lines
432 __bitmap_shift_left(dst, src, shift, nbits);438 __bitmap_shift_left(dst, src, shift, nbits);
433}439}
434 440
441static inline void bitmap_replace(unsigned long *dst,
442 const unsigned long *old,
443 const unsigned long *new,
444 const unsigned long *mask,
445 unsigned int nbits)
446{
447 if (small_const_nbits(nbits))
448 *dst = (*old & ~(*mask)) | (*new & *mask);
449 else
450 __bitmap_replace(dst, old, new, mask, nbits);
451}
452
435static inline int bitmap_parse(const char *buf, unsigned int buflen,453static inline int bitmap_parse(const char *buf, unsigned int buflen,
436 unsigned long *maskp, int nmaskbits)454 unsigned long *maskp, int nmaskbits)
437{455{
@@ -489,6 +507,39 @@ static inline void bitmap_from_u64(unsigned long *dst, u64 mask) · 51 unmodified lines
489 dst[1] = mask >> 32;507 dst[1] = mask >> 32;
490}508}
491 509
510/**
511 * bitmap_get_value8 - get an 8-bit value within a memory region
512 * @map: address to the bitmap memory region
513 * @start: bit offset of the 8-bit value; must be a multiple of 8
514 *
515 * Returns the 8-bit value located at the @start bit offset within the @src
516 * memory region.
517 */
518static inline unsigned long bitmap_get_value8(const unsigned long *map,
519 unsigned long start)
520{
521 const size_t index = BIT_WORD(start);
522 const unsigned long offset = start % BITS_PER_LONG;
523
524 return (map[index] >> offset) & 0xFF;
525}
526
527/**
528 * bitmap_set_value8 - set an 8-bit value within a memory region
529 * @map: address to the bitmap memory region
530 * @value: the 8-bit value; values wider than 8 bits may clobber bitmap
531 * @start: bit offset of the 8-bit value; must be a multiple of 8
532 */
533static inline void bitmap_set_value8(unsigned long *map, unsigned long value,
534 unsigned long start)
535{
536 const size_t index = BIT_WORD(start);
537 const unsigned long offset = start % BITS_PER_LONG;
538
539 map[index] &= ~(0xFFUL << offset);
540 map[index] |= value << offset;
541}
542
492#endif /* __ASSEMBLY__ */543#endif /* __ASSEMBLY__ */
493 544
494#endif /* __LINUX_BITMAP_H */545#endif /* __LINUX_BITMAP_H */
include/linux/bitops.h+12−0
@@ -47,6 +47,18 @@ extern unsigned long __sw_hweight64(__u64 w); · 46 unmodified lines
47 (bit) < (size); \47 (bit) < (size); \
48 (bit) = find_next_zero_bit((addr), (size), (bit) + 1))48 (bit) = find_next_zero_bit((addr), (size), (bit) + 1))
49 49
50/**
51 * for_each_set_clump8 - iterate over bitmap for each 8-bit clump with set bits
52 * @start: bit offset to start search and to store the current iteration offset
53 * @clump: location to store copy of current 8-bit clump
54 * @bits: bitmap address to base the search on
55 * @size: bitmap size in number of bits
56 */
57#define for_each_set_clump8(start, clump, bits, size) \
58 for ((start) = find_first_clump8(&(clump), (bits), (size)); \
59 (start) < (size); \
60 (start) = find_next_clump8(&(clump), (bits), (size), (start) + 8))
61
50static inline int get_bitmask_order(unsigned int count)62static inline int get_bitmask_order(unsigned int count)
51{63{
52 int order;64 int order;
include/linux/blk-cgroup.h+0−2
@@ -188,7 +188,6 @@ struct blkcg_gq *__blkg_lookup_create(struct blkcg *blkcg, · 187 unmodified lines
188struct blkcg_gq *blkg_lookup_create(struct blkcg *blkcg,188struct blkcg_gq *blkg_lookup_create(struct blkcg *blkcg,
189 struct request_queue *q);189 struct request_queue *q);
190int blkcg_init_queue(struct request_queue *q);190int blkcg_init_queue(struct request_queue *q);
191void blkcg_drain_queue(struct request_queue *q);
192void blkcg_exit_queue(struct request_queue *q);191void blkcg_exit_queue(struct request_queue *q);
193 192
194/* Blkio controller policy registration */193/* Blkio controller policy registration */
@@ -720,7 +719,6 @@ static inline struct blkcg_gq *blkg_lookup(struct blkcg *blkcg, void *key) { ret · 525 unmodified lines
720static inline struct blkcg_gq *blk_queue_root_blkg(struct request_queue *q)719static inline struct blkcg_gq *blk_queue_root_blkg(struct request_queue *q)
721{ return NULL; }720{ return NULL; }
722static inline int blkcg_init_queue(struct request_queue *q) { return 0; }721static inline int blkcg_init_queue(struct request_queue *q) { return 0; }
723static inline void blkcg_drain_queue(struct request_queue *q) { }
724static inline void blkcg_exit_queue(struct request_queue *q) { }722static inline void blkcg_exit_queue(struct request_queue *q) { }
725static inline int blkcg_policy_register(struct blkcg_policy *pol) { return 0; }723static inline int blkcg_policy_register(struct blkcg_policy *pol) { return 0; }
726static inline void blkcg_policy_unregister(struct blkcg_policy *pol) { }724static inline void blkcg_policy_unregister(struct blkcg_policy *pol) { }
include/linux/blkdev.h+10−14
@@ -357,8 +357,7 @@ typedef int (*report_zones_cb)(struct blk_zone *zone, unsigned int idx, · 356 unmodified lines
357#define BLK_ALL_ZONES ((unsigned int)-1)357#define BLK_ALL_ZONES ((unsigned int)-1)
358int blkdev_report_zones(struct block_device *bdev, sector_t sector,358int blkdev_report_zones(struct block_device *bdev, sector_t sector,
359 unsigned int nr_zones, report_zones_cb cb, void *data);359 unsigned int nr_zones, report_zones_cb cb, void *data);
360 360unsigned int blkdev_nr_zones(struct gendisk *disk);
361extern unsigned int blkdev_nr_zones(struct block_device *bdev);
362extern int blkdev_zone_mgmt(struct block_device *bdev, enum req_opf op,361extern int blkdev_zone_mgmt(struct block_device *bdev, enum req_opf op,
363 sector_t sectors, sector_t nr_sectors,362 sector_t sectors, sector_t nr_sectors,
364 gfp_t gfp_mask);363 gfp_t gfp_mask);
@@ -371,12 +370,7 @@ extern int blkdev_zone_mgmt_ioctl(struct block_device *bdev, fmode_t mode, · 6 unmodified lines
371 370
372#else /* CONFIG_BLK_DEV_ZONED */371#else /* CONFIG_BLK_DEV_ZONED */
373 372
374static inline unsigned int blkdev_nr_zones(struct block_device *bdev)373static inline unsigned int blkdev_nr_zones(struct gendisk *disk)
375{
376 return 0;
377}
378
379static inline int blk_revalidate_disk_zones(struct gendisk *disk)
380{374{
381 return 0;375 return 0;
382}376}
@@ -504,9 +498,9 @@ struct request_queue { · 121 unmodified lines
504 /*498 /*
505 * Zoned block device information for request dispatch control.499 * Zoned block device information for request dispatch control.
506 * nr_zones is the total number of zones of the device. This is always500 * nr_zones is the total number of zones of the device. This is always
507 * 0 for regular block devices. seq_zones_bitmap is a bitmap of nr_zones501 * 0 for regular block devices. conv_zones_bitmap is a bitmap of nr_zones
508 * bits which indicates if a zone is conventional (bit clear) or502 * bits which indicates if a zone is conventional (bit set) or
509 * sequential (bit set). seq_zones_wlock is a bitmap of nr_zones503 * sequential (bit clear). seq_zones_wlock is a bitmap of nr_zones
510 * bits which indicates if a zone is write locked, that is, if a write504 * bits which indicates if a zone is write locked, that is, if a write
511 * request targeting the zone was dispatched. All three fields are505 * request targeting the zone was dispatched. All three fields are
512 * initialized by the low level device driver (e.g. scsi/sd.c).506 * initialized by the low level device driver (e.g. scsi/sd.c).
@@ -519,7 +513,7 @@ struct request_queue { · 6 unmodified lines
519 * blk_mq_unfreeze_queue().513 * blk_mq_unfreeze_queue().
520 */514 */
521 unsigned int nr_zones;515 unsigned int nr_zones;
522 unsigned long *seq_zones_bitmap;516 unsigned long *conv_zones_bitmap;
523 unsigned long *seq_zones_wlock;517 unsigned long *seq_zones_wlock;
524#endif /* CONFIG_BLK_DEV_ZONED */518#endif /* CONFIG_BLK_DEV_ZONED */
525 519
@@ -724,9 +718,11 @@ static inline unsigned int blk_queue_zone_no(struct request_queue *q, · 198 unmodified lines
724static inline bool blk_queue_zone_is_seq(struct request_queue *q,718static inline bool blk_queue_zone_is_seq(struct request_queue *q,
725 sector_t sector)719 sector_t sector)
726{720{
727 if (!blk_queue_is_zoned(q) || !q->seq_zones_bitmap)721 if (!blk_queue_is_zoned(q))
728 return false;722 return false;
729 return test_bit(blk_queue_zone_no(q, sector), q->seq_zones_bitmap);723 if (!q->conv_zones_bitmap)
724 return true;
725 return !test_bit(blk_queue_zone_no(q, sector), q->conv_zones_bitmap);
730}726}
731#else /* CONFIG_BLK_DEV_ZONED */727#else /* CONFIG_BLK_DEV_ZONED */
732static inline unsigned int blk_queue_nr_zones(struct request_queue *q)728static inline unsigned int blk_queue_nr_zones(struct request_queue *q)
include/linux/bpf-cgroup.h+4−4
@@ -157,8 +157,8 @@ void bpf_cgroup_storage_link(struct bpf_cgroup_storage *storage, · 156 unmodified lines
157 struct cgroup *cgroup,157 struct cgroup *cgroup,
158 enum bpf_attach_type type);158 enum bpf_attach_type type);
159void bpf_cgroup_storage_unlink(struct bpf_cgroup_storage *storage);159void bpf_cgroup_storage_unlink(struct bpf_cgroup_storage *storage);
160int bpf_cgroup_storage_assign(struct bpf_prog *prog, struct bpf_map *map);160int bpf_cgroup_storage_assign(struct bpf_prog_aux *aux, struct bpf_map *map);
161void bpf_cgroup_storage_release(struct bpf_prog *prog, struct bpf_map *map);161void bpf_cgroup_storage_release(struct bpf_prog_aux *aux, struct bpf_map *map);
162 162
163int bpf_percpu_cgroup_storage_copy(struct bpf_map *map, void *key, void *value);163int bpf_percpu_cgroup_storage_copy(struct bpf_map *map, void *key, void *value);
164int bpf_percpu_cgroup_storage_update(struct bpf_map *map, void *key,164int bpf_percpu_cgroup_storage_update(struct bpf_map *map, void *key,
@@ -360,9 +360,9 @@ static inline int cgroup_bpf_prog_query(const union bpf_attr *attr, · 195 unmodified lines
360 360
361static inline void bpf_cgroup_storage_set(361static inline void bpf_cgroup_storage_set(
362 struct bpf_cgroup_storage *storage[MAX_BPF_CGROUP_STORAGE_TYPE]) {}362 struct bpf_cgroup_storage *storage[MAX_BPF_CGROUP_STORAGE_TYPE]) {}
363static inline int bpf_cgroup_storage_assign(struct bpf_prog *prog,363static inline int bpf_cgroup_storage_assign(struct bpf_prog_aux *aux,
364 struct bpf_map *map) { return 0; }364 struct bpf_map *map) { return 0; }
365static inline void bpf_cgroup_storage_release(struct bpf_prog *prog,365static inline void bpf_cgroup_storage_release(struct bpf_prog_aux *aux,
366 struct bpf_map *map) {}366 struct bpf_map *map) {}
367static inline struct bpf_cgroup_storage *bpf_cgroup_storage_alloc(367static inline struct bpf_cgroup_storage *bpf_cgroup_storage_alloc(
368 struct bpf_prog *prog, enum bpf_cgroup_storage_type stype) { return NULL; }368 struct bpf_prog *prog, enum bpf_cgroup_storage_type stype) { return NULL; }
include/linux/bpf.h+3−0
@@ -461,6 +461,7 @@ struct bpf_trampoline { · 460 unmodified lines
461 struct {461 struct {
462 struct btf_func_model model;462 struct btf_func_model model;
463 void *addr;463 void *addr;
464 bool ftrace_managed;
464 } func;465 } func;
465 /* list of BPF programs using this trampoline */466 /* list of BPF programs using this trampoline */
466 struct hlist_head progs_hlist[BPF_TRAMP_MAX];467 struct hlist_head progs_hlist[BPF_TRAMP_MAX];
@@ -817,6 +818,8 @@ struct bpf_prog * __must_check bpf_prog_inc_not_zero(struct bpf_prog *prog); · 350 unmodified lines
817void bpf_prog_put(struct bpf_prog *prog);818void bpf_prog_put(struct bpf_prog *prog);
818int __bpf_prog_charge(struct user_struct *user, u32 pages);819int __bpf_prog_charge(struct user_struct *user, u32 pages);
819void __bpf_prog_uncharge(struct user_struct *user, u32 pages);820void __bpf_prog_uncharge(struct user_struct *user, u32 pages);
821void __bpf_free_used_maps(struct bpf_prog_aux *aux,
822 struct bpf_map **used_maps, u32 len);
820 823
821void bpf_prog_free_id(struct bpf_prog *prog, bool do_idr_lock);824void bpf_prog_free_id(struct bpf_prog *prog, bool do_idr_lock);
822void bpf_map_free_id(struct bpf_map *map, bool do_idr_lock);825void bpf_map_free_id(struct bpf_map *map, bool do_idr_lock);
include/linux/build_bug.h+2−2
@@ -9,11 +9,11 @@ · 8 unmodified lines
9#else /* __CHECKER__ */9#else /* __CHECKER__ */
10/*10/*
11 * Force a compilation error if condition is true, but also produce a11 * Force a compilation error if condition is true, but also produce a
12 * result (of value 0 and type size_t), so the expression can be used12 * result (of value 0 and type int), so the expression can be used
13 * e.g. in a structure initializer (or where-ever else comma expressions13 * e.g. in a structure initializer (or where-ever else comma expressions
14 * aren't permitted).14 * aren't permitted).
15 */15 */
16#define BUILD_BUG_ON_ZERO(e) (sizeof(struct { int:(-!!(e)); }))16#define BUILD_BUG_ON_ZERO(e) ((int)(sizeof(struct { int:(-!!(e)); })))
17#endif /* __CHECKER__ */17#endif /* __CHECKER__ */
18 18
19/* Force a compilation error if a constant expression is not a power of 2 */19/* Force a compilation error if a constant expression is not a power of 2 */
include/linux/bvec.h+10−12
@@ -87,26 +87,24 @@ struct bvec_iter_all { · 86 unmodified lines
87static inline bool bvec_iter_advance(const struct bio_vec *bv,87static inline bool bvec_iter_advance(const struct bio_vec *bv,
88 struct bvec_iter *iter, unsigned bytes)88 struct bvec_iter *iter, unsigned bytes)
89{89{
90 unsigned int idx = iter->bi_idx;
91
90 if (WARN_ONCE(bytes > iter->bi_size,92 if (WARN_ONCE(bytes > iter->bi_size,
91 "Attempted to advance past end of bvec iter\n")) {93 "Attempted to advance past end of bvec iter\n")) {
92 iter->bi_size = 0;94 iter->bi_size = 0;
93 return false;95 return false;
94 }96 }
95 97
96 while (bytes) {98 iter->bi_size -= bytes;
97 const struct bio_vec *cur = bv + iter->bi_idx;99 bytes += iter->bi_bvec_done;
98 unsigned len = min3(bytes, iter->bi_size,
99 cur->bv_len - iter->bi_bvec_done);
100
101 bytes -= len;
102 iter->bi_size -= len;
103 iter->bi_bvec_done += len;
104 100
105 if (iter->bi_bvec_done == cur->bv_len) {101 while (bytes && bytes >= bv[idx].bv_len) {
106 iter->bi_bvec_done = 0;102 bytes -= bv[idx].bv_len;
107 iter->bi_idx++;103 idx++;
108 }
109 }104 }
105
106 iter->bi_idx = idx;
107 iter->bi_bvec_done = bytes;
110 return true;108 return true;
111}109}
112 110
include/linux/ceph/libceph.h+6−4
@@ -280,10 +280,12 @@ extern const char *ceph_msg_type_name(int type); · 279 unmodified lines
280extern int ceph_check_fsid(struct ceph_client *client, struct ceph_fsid *fsid);280extern int ceph_check_fsid(struct ceph_client *client, struct ceph_fsid *fsid);
281extern void *ceph_kvmalloc(size_t size, gfp_t flags);281extern void *ceph_kvmalloc(size_t size, gfp_t flags);
282 282
283extern struct ceph_options *ceph_parse_options(char *options,283struct fs_parameter;
284 const char *dev_name, const char *dev_name_end,284struct ceph_options *ceph_alloc_options(void);
285 int (*parse_extra_token)(char *c, void *private),285int ceph_parse_mon_ips(const char *buf, size_t len, struct ceph_options *opt,
286 void *private);286 struct fs_context *fc);
287int ceph_parse_param(struct fs_parameter *param, struct ceph_options *opt,
288 struct fs_context *fc);
287int ceph_print_client_options(struct seq_file *m, struct ceph_client *client,289int ceph_print_client_options(struct seq_file *m, struct ceph_client *client,
288 bool show_all);290 bool show_all);
289extern void ceph_destroy_options(struct ceph_options *opt);291extern void ceph_destroy_options(struct ceph_options *opt);
include/linux/cpu_cooling.h+8−10
@@ -33,6 +33,13 @@ cpufreq_cooling_register(struct cpufreq_policy *policy); · 32 unmodified lines
33 */33 */
34void cpufreq_cooling_unregister(struct thermal_cooling_device *cdev);34void cpufreq_cooling_unregister(struct thermal_cooling_device *cdev);
35 35
36/**
37 * of_cpufreq_cooling_register - create cpufreq cooling device based on DT.
38 * @policy: cpufreq policy.
39 */
40struct thermal_cooling_device *
41of_cpufreq_cooling_register(struct cpufreq_policy *policy);
42
36#else /* !CONFIG_CPU_THERMAL */43#else /* !CONFIG_CPU_THERMAL */
37static inline struct thermal_cooling_device *44static inline struct thermal_cooling_device *
38cpufreq_cooling_register(struct cpufreq_policy *policy)45cpufreq_cooling_register(struct cpufreq_policy *policy)
@@ -45,21 +52,12 @@ void cpufreq_cooling_unregister(struct thermal_cooling_device *cdev) · 6 unmodified lines
45{52{
46 return;53 return;
47}54}
48#endif /* CONFIG_CPU_THERMAL */
49 55
50#if defined(CONFIG_THERMAL_OF) && defined(CONFIG_CPU_THERMAL)
51/**
52 * of_cpufreq_cooling_register - create cpufreq cooling device based on DT.
53 * @policy: cpufreq policy.
54 */
55struct thermal_cooling_device *
56of_cpufreq_cooling_register(struct cpufreq_policy *policy);
57#else
58static inline struct thermal_cooling_device *56static inline struct thermal_cooling_device *
59of_cpufreq_cooling_register(struct cpufreq_policy *policy)57of_cpufreq_cooling_register(struct cpufreq_policy *policy)
60{58{
61 return NULL;59 return NULL;
62}60}
63#endif /* defined(CONFIG_THERMAL_OF) && defined(CONFIG_CPU_THERMAL) */61#endif /* CONFIG_CPU_THERMAL */
64 62
65#endif /* __CPU_COOLING_H__ */63#endif /* __CPU_COOLING_H__ */
include/linux/cpufreq.h+0−11
@@ -595,17 +595,6 @@ struct governor_attr { · 594 unmodified lines
595 size_t count);595 size_t count);
596};596};
597 597
598static inline bool cpufreq_this_cpu_can_update(struct cpufreq_policy *policy)
599{
600 /*
601 * Allow remote callbacks if:
602 * - dvfs_possible_from_any_cpu flag is set
603 * - the local and remote CPUs share cpufreq policy
604 */
605 return policy->dvfs_possible_from_any_cpu ||
606 cpumask_test_cpu(smp_processor_id(), policy->cpus);
607}
608
609/*********************************************************************598/*********************************************************************
610 * FREQUENCY TABLE HELPERS *599 * FREQUENCY TABLE HELPERS *
611 *********************************************************************/600 *********************************************************************/
include/linux/cpuidle.h+1−1
@@ -54,7 +54,6 @@ struct cpuidle_state { · 53 unmodified lines
54 unsigned int exit_latency; /* in US */54 unsigned int exit_latency; /* in US */
55 int power_usage; /* in mW */55 int power_usage; /* in mW */
56 unsigned int target_residency; /* in US */56 unsigned int target_residency; /* in US */
57 bool disabled; /* disabled on all CPUs */
58 57
59 int (*enter) (struct cpuidle_device *dev,58 int (*enter) (struct cpuidle_device *dev,
60 struct cpuidle_driver *drv,59 struct cpuidle_driver *drv,
@@ -77,6 +76,7 @@ struct cpuidle_state { · 16 unmodified lines
77#define CPUIDLE_FLAG_POLLING BIT(0) /* polling state */76#define CPUIDLE_FLAG_POLLING BIT(0) /* polling state */
78#define CPUIDLE_FLAG_COUPLED BIT(1) /* state applies to multiple cpus */77#define CPUIDLE_FLAG_COUPLED BIT(1) /* state applies to multiple cpus */
79#define CPUIDLE_FLAG_TIMER_STOP BIT(2) /* timer is stopped on this state */78#define CPUIDLE_FLAG_TIMER_STOP BIT(2) /* timer is stopped on this state */
79#define CPUIDLE_FLAG_UNUSABLE BIT(3) /* avoid using this state */
80 80
81struct cpuidle_device_kobj;81struct cpuidle_device_kobj;
82struct cpuidle_state_kobj;82struct cpuidle_state_kobj;
include/linux/dcache.h+5−0
@@ -440,6 +440,11 @@ static inline bool d_is_negative(const struct dentry *dentry) · 439 unmodified lines
440 return d_is_miss(dentry);440 return d_is_miss(dentry);
441}441}
442 442
443static inline bool d_flags_negative(unsigned flags)
444{
445 return (flags & DCACHE_ENTRY_TYPE) == DCACHE_MISS_TYPE;
446}
447
443static inline bool d_is_positive(const struct dentry *dentry)448static inline bool d_is_positive(const struct dentry *dentry)
444{449{
445 return !d_is_negative(dentry);450 return !d_is_negative(dentry);
include/linux/devfreq.h+10−4
@@ -13,6 +13,7 @@ · 12 unmodified lines
13#include <linux/device.h>13#include <linux/device.h>
14#include <linux/notifier.h>14#include <linux/notifier.h>
15#include <linux/pm_opp.h>15#include <linux/pm_opp.h>
16#include <linux/pm_qos.h>
16 17
17#define DEVFREQ_NAME_LEN 1618#define DEVFREQ_NAME_LEN 16
18 19
@@ -123,8 +124,8 @@ struct devfreq_dev_profile { · 104 unmodified lines
123 * @previous_freq: previously configured frequency value.124 * @previous_freq: previously configured frequency value.
124 * @data: Private data of the governor. The devfreq framework does not125 * @data: Private data of the governor. The devfreq framework does not
125 * touch this.126 * touch this.
126 * @min_freq: Limit minimum frequency requested by user (0: none)127 * @user_min_freq_req: PM QoS minimum frequency request from user (via sysfs)
127 * @max_freq: Limit maximum frequency requested by user (0: none)128 * @user_max_freq_req: PM QoS maximum frequency request from user (via sysfs)
128 * @scaling_min_freq: Limit minimum frequency requested by OPP interface129 * @scaling_min_freq: Limit minimum frequency requested by OPP interface
129 * @scaling_max_freq: Limit maximum frequency requested by OPP interface130 * @scaling_max_freq: Limit maximum frequency requested by OPP interface
130 * @stop_polling: devfreq polling status of a device.131 * @stop_polling: devfreq polling status of a device.
@@ -136,6 +137,8 @@ struct devfreq_dev_profile { · 5 unmodified lines
136 * @time_in_state: Statistics of devfreq states137 * @time_in_state: Statistics of devfreq states
137 * @last_stat_updated: The last time stat updated138 * @last_stat_updated: The last time stat updated
138 * @transition_notifier_list: list head of DEVFREQ_TRANSITION_NOTIFIER notifier139 * @transition_notifier_list: list head of DEVFREQ_TRANSITION_NOTIFIER notifier
140 * @nb_min: Notifier block for DEV_PM_QOS_MIN_FREQUENCY
141 * @nb_max: Notifier block for DEV_PM_QOS_MAX_FREQUENCY
139 *142 *
140 * This structure stores the devfreq information for a give device.143 * This structure stores the devfreq information for a give device.
141 *144 *
@@ -161,8 +164,8 @@ struct devfreq { · 19 unmodified lines
161 164
162 void *data; /* private data for governors */165 void *data; /* private data for governors */
163 166
164 unsigned long min_freq;167 struct dev_pm_qos_request user_min_freq_req;
165 unsigned long max_freq;168 struct dev_pm_qos_request user_max_freq_req;
166 unsigned long scaling_min_freq;169 unsigned long scaling_min_freq;
167 unsigned long scaling_max_freq;170 unsigned long scaling_max_freq;
168 bool stop_polling;171 bool stop_polling;
@@ -178,6 +181,9 @@ struct devfreq { · 9 unmodified lines
178 unsigned long last_stat_updated;181 unsigned long last_stat_updated;
179 182
180 struct srcu_notifier_head transition_notifier_list;183 struct srcu_notifier_head transition_notifier_list;
184
185 struct notifier_block nb_min;
186 struct notifier_block nb_max;
181};187};
182 188
183struct devfreq_freqs {189struct devfreq_freqs {
include/linux/device.h+2−2
@@ -1666,11 +1666,11 @@ extern bool kill_device(struct device *dev); · 1665 unmodified lines
1666#ifdef CONFIG_DEVTMPFS1666#ifdef CONFIG_DEVTMPFS
1667extern int devtmpfs_create_node(struct device *dev);1667extern int devtmpfs_create_node(struct device *dev);
1668extern int devtmpfs_delete_node(struct device *dev);1668extern int devtmpfs_delete_node(struct device *dev);
1669extern int devtmpfs_mount(const char *mntdir);1669extern int devtmpfs_mount(void);
1670#else1670#else
1671static inline int devtmpfs_create_node(struct device *dev) { return 0; }1671static inline int devtmpfs_create_node(struct device *dev) { return 0; }
1672static inline int devtmpfs_delete_node(struct device *dev) { return 0; }1672static inline int devtmpfs_delete_node(struct device *dev) { return 0; }
1673static inline int devtmpfs_mount(const char *mountpoint) { return 0; }1673static inline int devtmpfs_mount(void) { return 0; }
1674#endif1674#endif
1675 1675
1676/* drivers/base/power/shutdown.c */1676/* drivers/base/power/shutdown.c */
include/linux/efi.h+5−5
@@ -824,7 +824,7 @@ typedef struct { · 823 unmodified lines
824 __aligned_u64 image_size;824 __aligned_u64 image_size;
825 unsigned int image_code_type;825 unsigned int image_code_type;
826 unsigned int image_data_type;826 unsigned int image_data_type;
827 unsigned long unload;827 u32 unload;
828} efi_loaded_image_32_t;828} efi_loaded_image_32_t;
829 829
830typedef struct {830typedef struct {
@@ -840,14 +840,14 @@ typedef struct { · 9 unmodified lines
840 __aligned_u64 image_size;840 __aligned_u64 image_size;
841 unsigned int image_code_type;841 unsigned int image_code_type;
842 unsigned int image_data_type;842 unsigned int image_data_type;
843 unsigned long unload;843 u64 unload;
844} efi_loaded_image_64_t;844} efi_loaded_image_64_t;
845 845
846typedef struct {846typedef struct {
847 u32 revision;847 u32 revision;
848 void *parent_handle;848 efi_handle_t parent_handle;
849 efi_system_table_t *system_table;849 efi_system_table_t *system_table;
850 void *device_handle;850 efi_handle_t device_handle;
851 void *file_path;851 void *file_path;
852 void *reserved;852 void *reserved;
853 u32 load_options_size;853 u32 load_options_size;
@@ -856,7 +856,7 @@ typedef struct { · 2 unmodified lines
856 __aligned_u64 image_size;856 __aligned_u64 image_size;
857 unsigned int image_code_type;857 unsigned int image_code_type;
858 unsigned int image_data_type;858 unsigned int image_data_type;
859 unsigned long unload;859 efi_status_t (*unload)(efi_handle_t image_handle);
860} efi_loaded_image_t;860} efi_loaded_image_t;
861 861
862 862
include/linux/energy_model.h+1−2
@@ -9,7 +9,6 @@ · 8 unmodified lines
9#include <linux/sched/topology.h>9#include <linux/sched/topology.h>
10#include <linux/types.h>10#include <linux/types.h>
11 11
12#ifdef CONFIG_ENERGY_MODEL
13/**12/**
14 * em_cap_state - Capacity state of a performance domain13 * em_cap_state - Capacity state of a performance domain
15 * @frequency: The CPU frequency in KHz, for consistency with CPUFreq14 * @frequency: The CPU frequency in KHz, for consistency with CPUFreq
@@ -40,6 +39,7 @@ struct em_perf_domain { · 24 unmodified lines
40 unsigned long cpus[0];39 unsigned long cpus[0];
41};40};
42 41
42#ifdef CONFIG_ENERGY_MODEL
43#define EM_CPU_MAX_POWER 0xFFFF43#define EM_CPU_MAX_POWER 0xFFFF
44 44
45struct em_data_callback {45struct em_data_callback {
@@ -160,7 +160,6 @@ static inline int em_pd_nr_cap_states(struct em_perf_domain *pd) · 114 unmodified lines
160}160}
161 161
162#else162#else
163struct em_perf_domain {};
164struct em_data_callback {};163struct em_data_callback {};
165#define EM_DATA_CB(_active_power_cb) { }164#define EM_DATA_CB(_active_power_cb) { }
166 165
include/linux/export.h+28−63
@@ -47,7 +47,7 @@ extern struct module __this_module; · 46 unmodified lines
47 * absolute relocations that require runtime processing on relocatable47 * absolute relocations that require runtime processing on relocatable
48 * kernels.48 * kernels.
49 */49 */
50#define __KSYMTAB_ENTRY_NS(sym, sec) \50#define __KSYMTAB_ENTRY(sym, sec) \
51 __ADDRESSABLE(sym) \51 __ADDRESSABLE(sym) \
52 asm(" .section \"___ksymtab" sec "+" #sym "\", \"a\" \n" \52 asm(" .section \"___ksymtab" sec "+" #sym "\", \"a\" \n" \
53 " .balign 4 \n" \53 " .balign 4 \n" \
@@ -57,33 +57,17 @@ extern struct module __this_module; · 3 unmodified lines
57 " .long __kstrtabns_" #sym "- . \n" \57 " .long __kstrtabns_" #sym "- . \n" \
58 " .previous \n")58 " .previous \n")
59 59
60#define __KSYMTAB_ENTRY(sym, sec) \
61 __ADDRESSABLE(sym) \
62 asm(" .section \"___ksymtab" sec "+" #sym "\", \"a\" \n" \
63 " .balign 4 \n" \
64 "__ksymtab_" #sym ": \n" \
65 " .long " #sym "- . \n" \
66 " .long __kstrtab_" #sym "- . \n" \
67 " .long 0 \n" \
68 " .previous \n")
69
70struct kernel_symbol {60struct kernel_symbol {
71 int value_offset;61 int value_offset;
72 int name_offset;62 int name_offset;
73 int namespace_offset;63 int namespace_offset;
74};64};
75#else65#else
76#define __KSYMTAB_ENTRY_NS(sym, sec) \
77 static const struct kernel_symbol __ksymtab_##sym \
78 __attribute__((section("___ksymtab" sec "+" #sym), used)) \
79 __aligned(sizeof(void *)) \
80 = { (unsigned long)&sym, __kstrtab_##sym, __kstrtabns_##sym }
81
82#define __KSYMTAB_ENTRY(sym, sec) \66#define __KSYMTAB_ENTRY(sym, sec) \
83 static const struct kernel_symbol __ksymtab_##sym \67 static const struct kernel_symbol __ksymtab_##sym \
84 __attribute__((section("___ksymtab" sec "+" #sym), used)) \68 __attribute__((section("___ksymtab" sec "+" #sym), used)) \
85 __aligned(sizeof(void *)) \69 __aligned(sizeof(void *)) \
86 = { (unsigned long)&sym, __kstrtab_##sym, NULL }70 = { (unsigned long)&sym, __kstrtab_##sym, __kstrtabns_##sym }
87 71
88struct kernel_symbol {72struct kernel_symbol {
89 unsigned long value;73 unsigned long value;
@@ -94,28 +78,20 @@ struct kernel_symbol { · 4 unmodified lines
94 78
95#ifdef __GENKSYMS__79#ifdef __GENKSYMS__
96 80
97#define ___EXPORT_SYMBOL(sym,sec) __GENKSYMS_EXPORT_SYMBOL(sym)81#define ___EXPORT_SYMBOL(sym, sec, ns) __GENKSYMS_EXPORT_SYMBOL(sym)
98#define ___EXPORT_SYMBOL_NS(sym,sec,ns) __GENKSYMS_EXPORT_SYMBOL(sym)
99 82
100#else83#else
101 84
102#define ___export_symbol_common(sym, sec) \85/* For every exported symbol, place a struct in the __ksymtab section */
86#define ___EXPORT_SYMBOL(sym, sec, ns) \
103 extern typeof(sym) sym; \87 extern typeof(sym) sym; \
104 __CRC_SYMBOL(sym, sec); \88 __CRC_SYMBOL(sym, sec); \
105 static const char __kstrtab_##sym[] \89 static const char __kstrtab_##sym[] \
106 __attribute__((section("__ksymtab_strings"), used, aligned(1))) \90 __attribute__((section("__ksymtab_strings"), used, aligned(1))) \
107 = #sym \91 = #sym; \
108
109/* For every exported symbol, place a struct in the __ksymtab section */
110#define ___EXPORT_SYMBOL_NS(sym, sec, ns) \
111 ___export_symbol_common(sym, sec); \
112 static const char __kstrtabns_##sym[] \92 static const char __kstrtabns_##sym[] \
113 __attribute__((section("__ksymtab_strings"), used, aligned(1))) \93 __attribute__((section("__ksymtab_strings"), used, aligned(1))) \
114 = #ns; \94 = ns; \
115 __KSYMTAB_ENTRY_NS(sym, sec)
116
117#define ___EXPORT_SYMBOL(sym, sec) \
118 ___export_symbol_common(sym, sec); \
119 __KSYMTAB_ENTRY(sym, sec)95 __KSYMTAB_ENTRY(sym, sec)
120 96
121#endif97#endif
@@ -127,8 +103,7 @@ struct kernel_symbol { · 5 unmodified lines
127 * be reused in other execution contexts such as the UEFI stub or the103 * be reused in other execution contexts such as the UEFI stub or the
128 * decompressor.104 * decompressor.
129 */105 */
130#define __EXPORT_SYMBOL_NS(sym, sec, ns)106#define __EXPORT_SYMBOL(sym, sec, ns)
131#define __EXPORT_SYMBOL(sym, sec)
132 107
133#elif defined(CONFIG_TRIM_UNUSED_KSYMS)108#elif defined(CONFIG_TRIM_UNUSED_KSYMS)
134 109
@@ -144,48 +119,38 @@ struct kernel_symbol { · 9 unmodified lines
144#define __ksym_marker(sym) \119#define __ksym_marker(sym) \
145 static int __ksym_marker_##sym[0] __section(".discard.ksym") __used120 static int __ksym_marker_##sym[0] __section(".discard.ksym") __used
146 121
147#define __EXPORT_SYMBOL(sym, sec) \122#define __EXPORT_SYMBOL(sym, sec, ns) \
148 __ksym_marker(sym); \
149 __cond_export_sym(sym, sec, __is_defined(__KSYM_##sym))
150#define __cond_export_sym(sym, sec, conf) \
151 ___cond_export_sym(sym, sec, conf)
152#define ___cond_export_sym(sym, sec, enabled) \
153 __cond_export_sym_##enabled(sym, sec)
154#define __cond_export_sym_1(sym, sec) ___EXPORT_SYMBOL(sym, sec)
155#define __cond_export_sym_0(sym, sec) /* nothing */
156
157#define __EXPORT_SYMBOL_NS(sym, sec, ns) \
158 __ksym_marker(sym); \123 __ksym_marker(sym); \
159 __cond_export_ns_sym(sym, sec, ns, __is_defined(__KSYM_##sym))124 __cond_export_sym(sym, sec, ns, __is_defined(__KSYM_##sym))
160#define __cond_export_ns_sym(sym, sec, ns, conf) \125#define __cond_export_sym(sym, sec, ns, conf) \
161 ___cond_export_ns_sym(sym, sec, ns, conf)126 ___cond_export_sym(sym, sec, ns, conf)
162#define ___cond_export_ns_sym(sym, sec, ns, enabled) \127#define ___cond_export_sym(sym, sec, ns, enabled) \
163 __cond_export_ns_sym_##enabled(sym, sec, ns)128 __cond_export_sym_##enabled(sym, sec, ns)
164#define __cond_export_ns_sym_1(sym, sec, ns) ___EXPORT_SYMBOL_NS(sym, sec, ns)129#define __cond_export_sym_1(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
165#define __cond_export_ns_sym_0(sym, sec, ns) /* nothing */130#define __cond_export_sym_0(sym, sec, ns) /* nothing */
166 131
167#else132#else
168 133
169#define __EXPORT_SYMBOL_NS(sym,sec,ns) ___EXPORT_SYMBOL_NS(sym,sec,ns)134#define __EXPORT_SYMBOL(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
170#define __EXPORT_SYMBOL(sym,sec) ___EXPORT_SYMBOL(sym,sec)
171 135
172#endif /* CONFIG_MODULES */136#endif /* CONFIG_MODULES */
173 137
174#ifdef DEFAULT_SYMBOL_NAMESPACE138#ifdef DEFAULT_SYMBOL_NAMESPACE
175#undef __EXPORT_SYMBOL139#include <linux/stringify.h>
176#define __EXPORT_SYMBOL(sym, sec) \140#define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, __stringify(DEFAULT_SYMBOL_NAMESPACE))
177 __EXPORT_SYMBOL_NS(sym, sec, DEFAULT_SYMBOL_NAMESPACE)141#else
142#define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "")
178#endif143#endif
179 144
180#define EXPORT_SYMBOL(sym) __EXPORT_SYMBOL(sym, "")145#define EXPORT_SYMBOL(sym) _EXPORT_SYMBOL(sym, "")
181#define EXPORT_SYMBOL_GPL(sym) __EXPORT_SYMBOL(sym, "_gpl")146#define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl")
182#define EXPORT_SYMBOL_GPL_FUTURE(sym) __EXPORT_SYMBOL(sym, "_gpl_future")147#define EXPORT_SYMBOL_GPL_FUTURE(sym) _EXPORT_SYMBOL(sym, "_gpl_future")
183#define EXPORT_SYMBOL_NS(sym, ns) __EXPORT_SYMBOL_NS(sym, "", ns)148#define EXPORT_SYMBOL_NS(sym, ns) __EXPORT_SYMBOL(sym, "", #ns)
184#define EXPORT_SYMBOL_NS_GPL(sym, ns) __EXPORT_SYMBOL_NS(sym, "_gpl", ns)149#define EXPORT_SYMBOL_NS_GPL(sym, ns) __EXPORT_SYMBOL(sym, "_gpl", #ns)
185 150
186#ifdef CONFIG_UNUSED_SYMBOLS151#ifdef CONFIG_UNUSED_SYMBOLS
187#define EXPORT_UNUSED_SYMBOL(sym) __EXPORT_SYMBOL(sym, "_unused")152#define EXPORT_UNUSED_SYMBOL(sym) _EXPORT_SYMBOL(sym, "_unused")
188#define EXPORT_UNUSED_SYMBOL_GPL(sym) __EXPORT_SYMBOL(sym, "_unused_gpl")153#define EXPORT_UNUSED_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_unused_gpl")
189#else154#else
190#define EXPORT_UNUSED_SYMBOL(sym)155#define EXPORT_UNUSED_SYMBOL(sym)
191#define EXPORT_UNUSED_SYMBOL_GPL(sym)156#define EXPORT_UNUSED_SYMBOL_GPL(sym)
include/linux/filter.h+12−8
@@ -420,7 +420,7 @@ static inline bool insn_is_zext(const struct bpf_insn *insn) · 419 unmodified lines
420 420
421#define BPF_FIELD_SIZEOF(type, field) \421#define BPF_FIELD_SIZEOF(type, field) \
422 ({ \422 ({ \
423 const int __size = bytes_to_bpf_size(FIELD_SIZEOF(type, field)); \423 const int __size = bytes_to_bpf_size(sizeof_field(type, field)); \
424 BUILD_BUG_ON(__size < 0); \424 BUILD_BUG_ON(__size < 0); \
425 __size; \425 __size; \
426 })426 })
@@ -497,7 +497,7 @@ static inline bool insn_is_zext(const struct bpf_insn *insn) · 70 unmodified lines
497 497
498#define bpf_target_off(TYPE, MEMBER, SIZE, PTR_SIZE) \498#define bpf_target_off(TYPE, MEMBER, SIZE, PTR_SIZE) \
499 ({ \499 ({ \
500 BUILD_BUG_ON(FIELD_SIZEOF(TYPE, MEMBER) != (SIZE)); \500 BUILD_BUG_ON(sizeof_field(TYPE, MEMBER) != (SIZE)); \
501 *(PTR_SIZE) = (SIZE); \501 *(PTR_SIZE) = (SIZE); \
502 offsetof(TYPE, MEMBER); \502 offsetof(TYPE, MEMBER); \
503 })503 })
@@ -608,7 +608,7 @@ static inline void bpf_compute_data_pointers(struct sk_buff *skb) · 104 unmodified lines
608{608{
609 struct bpf_skb_data_end *cb = (struct bpf_skb_data_end *)skb->cb;609 struct bpf_skb_data_end *cb = (struct bpf_skb_data_end *)skb->cb;
610 610
611 BUILD_BUG_ON(sizeof(*cb) > FIELD_SIZEOF(struct sk_buff, cb));611 BUILD_BUG_ON(sizeof(*cb) > sizeof_field(struct sk_buff, cb));
612 cb->data_meta = skb->data - skb_metadata_len(skb);612 cb->data_meta = skb->data - skb_metadata_len(skb);
613 cb->data_end = skb->data + skb_headlen(skb);613 cb->data_end = skb->data + skb_headlen(skb);
614}614}
@@ -646,9 +646,9 @@ static inline u8 *bpf_skb_cb(struct sk_buff *skb) · 31 unmodified lines
646 * attached to sockets, we need to clear the bpf_skb_cb() area646 * attached to sockets, we need to clear the bpf_skb_cb() area
647 * to not leak previous contents to user space.647 * to not leak previous contents to user space.
648 */648 */
649 BUILD_BUG_ON(FIELD_SIZEOF(struct __sk_buff, cb) != BPF_SKB_CB_LEN);649 BUILD_BUG_ON(sizeof_field(struct __sk_buff, cb) != BPF_SKB_CB_LEN);
650 BUILD_BUG_ON(FIELD_SIZEOF(struct __sk_buff, cb) !=650 BUILD_BUG_ON(sizeof_field(struct __sk_buff, cb) !=
651 FIELD_SIZEOF(struct qdisc_skb_cb, data));651 sizeof_field(struct qdisc_skb_cb, data));
652 652
653 return qdisc_skb_cb(skb)->data;653 return qdisc_skb_cb(skb)->data;
654}654}
@@ -776,8 +776,12 @@ bpf_ctx_narrow_access_offset(u32 off, u32 size, u32 size_default) · 121 unmodified lines
776 776
777static inline void bpf_prog_lock_ro(struct bpf_prog *fp)777static inline void bpf_prog_lock_ro(struct bpf_prog *fp)
778{778{
779 set_vm_flush_reset_perms(fp);779#ifndef CONFIG_BPF_JIT_ALWAYS_ON
780 set_memory_ro((unsigned long)fp, fp->pages);780 if (!fp->jited) {
781 set_vm_flush_reset_perms(fp);
782 set_memory_ro((unsigned long)fp, fp->pages);
783 }
784#endif
781}785}
782 786
783static inline void bpf_jit_binary_lock_ro(struct bpf_binary_header *hdr)787static inline void bpf_jit_binary_lock_ro(struct bpf_binary_header *hdr)
include/linux/firmware/meson/meson_sm.h+9−6
@@ -16,11 +16,14 @@ enum { · 15 unmodified lines
16 16
17struct meson_sm_firmware;17struct meson_sm_firmware;
18 18
19int meson_sm_call(unsigned int cmd_index, u32 *ret, u32 arg0, u32 arg1,19int meson_sm_call(struct meson_sm_firmware *fw, unsigned int cmd_index,
20 u32 arg2, u32 arg3, u32 arg4);20 u32 *ret, u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4);
21int meson_sm_call_write(void *buffer, unsigned int b_size, unsigned int cmd_index,21int meson_sm_call_write(struct meson_sm_firmware *fw, void *buffer,
22 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4);22 unsigned int b_size, unsigned int cmd_index, u32 arg0,
23int meson_sm_call_read(void *buffer, unsigned int bsize, unsigned int cmd_index,23 u32 arg1, u32 arg2, u32 arg3, u32 arg4);
24 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4);24int meson_sm_call_read(struct meson_sm_firmware *fw, void *buffer,
25 unsigned int bsize, unsigned int cmd_index, u32 arg0,
26 u32 arg1, u32 arg2, u32 arg3, u32 arg4);
27struct meson_sm_firmware *meson_sm_get(struct device_node *firmware_node);
25 28
26#endif /* _MESON_SM_FW_H_ */29#endif /* _MESON_SM_FW_H_ */
include/linux/firmware/xlnx-zynqmp.h+2−1
@@ -2,7 +2,7 @@ · 1 unmodified line
2/*2/*
3 * Xilinx Zynq MPSoC Firmware layer3 * Xilinx Zynq MPSoC Firmware layer
4 *4 *
5 * Copyright (C) 2014-2018 Xilinx5 * Copyright (C) 2014-2019 Xilinx
6 *6 *
7 * Michal Simek <michal.simek@xilinx.com>7 * Michal Simek <michal.simek@xilinx.com>
8 * Davorin Mista <davorin.mista@aggios.com>8 * Davorin Mista <davorin.mista@aggios.com>
@@ -46,6 +46,7 @@ · 37 unmodified lines
46#define ZYNQMP_PM_CAPABILITY_ACCESS 0x1U46#define ZYNQMP_PM_CAPABILITY_ACCESS 0x1U
47#define ZYNQMP_PM_CAPABILITY_CONTEXT 0x2U47#define ZYNQMP_PM_CAPABILITY_CONTEXT 0x2U
48#define ZYNQMP_PM_CAPABILITY_WAKEUP 0x4U48#define ZYNQMP_PM_CAPABILITY_WAKEUP 0x4U
49#define ZYNQMP_PM_CAPABILITY_UNUSABLE 0x8U
49 50
50/*51/*
51 * Firmware FPGA Manager flags52 * Firmware FPGA Manager flags
include/linux/ftrace.h+5−0
@@ -264,6 +264,7 @@ int ftrace_modify_direct_caller(struct ftrace_func_entry *entry, · 263 unmodified lines
264 struct dyn_ftrace *rec,264 struct dyn_ftrace *rec,
265 unsigned long old_addr,265 unsigned long old_addr,
266 unsigned long new_addr);266 unsigned long new_addr);
267unsigned long ftrace_find_rec_direct(unsigned long ip);
267#else268#else
268# define ftrace_direct_func_count 0269# define ftrace_direct_func_count 0
269static inline int register_ftrace_direct(unsigned long ip, unsigned long addr)270static inline int register_ftrace_direct(unsigned long ip, unsigned long addr)
@@ -290,6 +291,10 @@ static inline int ftrace_modify_direct_caller(struct ftrace_func_entry *entry, · 20 unmodified lines
290{291{
291 return -ENODEV;292 return -ENODEV;
292}293}
294static inline unsigned long ftrace_find_rec_direct(unsigned long ip)
295{
296 return 0;
297}
293#endif /* CONFIG_DYNAMIC_FTRACE_WITH_DIRECT_CALLS */298#endif /* CONFIG_DYNAMIC_FTRACE_WITH_DIRECT_CALLS */
294 299
295#ifndef CONFIG_HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS300#ifndef CONFIG_HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS
include/linux/genalloc.h+1−1
@@ -206,7 +206,7 @@ extern struct gen_pool *devm_gen_pool_create(struct device *dev, · 205 unmodified lines
206 int min_alloc_order, int nid, const char *name);206 int min_alloc_order, int nid, const char *name);
207extern struct gen_pool *gen_pool_get(struct device *dev, const char *name);207extern struct gen_pool *gen_pool_get(struct device *dev, const char *name);
208 208
209bool addr_in_gen_pool(struct gen_pool *pool, unsigned long start,209extern bool gen_pool_has_addr(struct gen_pool *pool, unsigned long start,
210 size_t size);210 size_t size);
211 211
212#ifdef CONFIG_OF212#ifdef CONFIG_OF
include/linux/i2c.h+6−6
@@ -300,6 +300,7 @@ struct i2c_driver { · 299 unmodified lines
300 * generic enough to hide second-sourcing and compatible revisions.300 * generic enough to hide second-sourcing and compatible revisions.
301 * @adapter: manages the bus segment hosting this I2C device301 * @adapter: manages the bus segment hosting this I2C device
302 * @dev: Driver model device node for the slave.302 * @dev: Driver model device node for the slave.
303 * @init_irq: IRQ that was set at initialization
303 * @irq: indicates the IRQ generated by this device (if any)304 * @irq: indicates the IRQ generated by this device (if any)
304 * @detected: member of an i2c_driver.clients list or i2c-core's305 * @detected: member of an i2c_driver.clients list or i2c-core's
305 * userspace_devices list306 * userspace_devices list
@@ -466,12 +467,6 @@ i2c_new_probed_device(struct i2c_adapter *adap, · 160 unmodified lines
466/* Common custom probe functions */467/* Common custom probe functions */
467extern int i2c_probe_func_quick_read(struct i2c_adapter *adap, unsigned short addr);468extern int i2c_probe_func_quick_read(struct i2c_adapter *adap, unsigned short addr);
468 469
469/* For devices that use several addresses, use i2c_new_dummy() to make
470 * client handles for the extra addresses.
471 */
472extern struct i2c_client *
473i2c_new_dummy(struct i2c_adapter *adap, u16 address);
474
475extern struct i2c_client *470extern struct i2c_client *
476i2c_new_dummy_device(struct i2c_adapter *adapter, u16 address);471i2c_new_dummy_device(struct i2c_adapter *adapter, u16 address);
477 472
@@ -856,6 +851,11 @@ extern void i2c_del_driver(struct i2c_driver *driver); · 378 unmodified lines
856#define i2c_add_driver(driver) \851#define i2c_add_driver(driver) \
857 i2c_register_driver(THIS_MODULE, driver)852 i2c_register_driver(THIS_MODULE, driver)
858 853
854static inline bool i2c_client_has_driver(struct i2c_client *client)
855{
856 return !IS_ERR_OR_NULL(client) && client->dev.driver;
857}
858
859/* call the i2c_client->command() of all attached clients with859/* call the i2c_client->command() of all attached clients with
860 * the given arguments */860 * the given arguments */
861extern void i2c_clients_command(struct i2c_adapter *adap,861extern void i2c_clients_command(struct i2c_adapter *adap,
include/linux/initrd.h+2−0
@@ -28,3 +28,5 @@ extern unsigned int real_root_dev; · 27 unmodified lines
28 28
29extern char __initramfs_start[];29extern char __initramfs_start[];
30extern unsigned long __initramfs_size;30extern unsigned long __initramfs_size;
31
32void console_on_rootfs(void);
include/linux/jbd2.h+1−1
@@ -457,7 +457,7 @@ struct jbd2_revoke_table_s; · 456 unmodified lines
457 * @h_journal: Which journal handle belongs to - used iff h_reserved set.457 * @h_journal: Which journal handle belongs to - used iff h_reserved set.
458 * @h_rsv_handle: Handle reserved for finishing the logical operation.458 * @h_rsv_handle: Handle reserved for finishing the logical operation.
459 * @h_total_credits: Number of remaining buffers we are allowed to add to459 * @h_total_credits: Number of remaining buffers we are allowed to add to
460 journal. These are dirty buffers and revoke descriptor blocks.460 * journal. These are dirty buffers and revoke descriptor blocks.
461 * @h_revoke_credits: Number of remaining revoke records available for handle461 * @h_revoke_credits: Number of remaining revoke records available for handle
462 * @h_ref: Reference count on this handle.462 * @h_ref: Reference count on this handle.
463 * @h_err: Field for caller's use to track errors through large fs operations.463 * @h_err: Field for caller's use to track errors through large fs operations.
include/linux/kasan.h+9−6
@@ -205,20 +205,23 @@ static inline void *kasan_reset_tag(const void *addr) · 204 unmodified lines
205#endif /* CONFIG_KASAN_SW_TAGS */205#endif /* CONFIG_KASAN_SW_TAGS */
206 206
207#ifdef CONFIG_KASAN_VMALLOC207#ifdef CONFIG_KASAN_VMALLOC
208int kasan_populate_vmalloc(unsigned long requested_size,208int kasan_populate_vmalloc(unsigned long addr, unsigned long size);
209 struct vm_struct *area);209void kasan_poison_vmalloc(const void *start, unsigned long size);
210void kasan_poison_vmalloc(void *start, unsigned long size);210void kasan_unpoison_vmalloc(const void *start, unsigned long size);
211void kasan_release_vmalloc(unsigned long start, unsigned long end,211void kasan_release_vmalloc(unsigned long start, unsigned long end,
212 unsigned long free_region_start,212 unsigned long free_region_start,
213 unsigned long free_region_end);213 unsigned long free_region_end);
214#else214#else
215static inline int kasan_populate_vmalloc(unsigned long requested_size,215static inline int kasan_populate_vmalloc(unsigned long start,
216 struct vm_struct *area)216 unsigned long size)
217{217{
218 return 0;218 return 0;
219}219}
220 220
221static inline void kasan_poison_vmalloc(void *start, unsigned long size) {}221static inline void kasan_poison_vmalloc(const void *start, unsigned long size)
222{ }
223static inline void kasan_unpoison_vmalloc(const void *start, unsigned long size)
224{ }
222static inline void kasan_release_vmalloc(unsigned long start,225static inline void kasan_release_vmalloc(unsigned long start,
223 unsigned long end,226 unsigned long end,
224 unsigned long free_region_start,227 unsigned long free_region_start,
include/linux/kcov.h+23−0
@@ -37,12 +37,35 @@ do { \ · 36 unmodified lines
37 (t)->kcov_mode &= ~KCOV_IN_CTXSW; \37 (t)->kcov_mode &= ~KCOV_IN_CTXSW; \
38} while (0)38} while (0)
39 39
40/* See Documentation/dev-tools/kcov.rst for usage details. */
41void kcov_remote_start(u64 handle);
42void kcov_remote_stop(void);
43u64 kcov_common_handle(void);
44
45static inline void kcov_remote_start_common(u64 id)
46{
47 kcov_remote_start(kcov_remote_handle(KCOV_SUBSYSTEM_COMMON, id));
48}
49
50static inline void kcov_remote_start_usb(u64 id)
51{
52 kcov_remote_start(kcov_remote_handle(KCOV_SUBSYSTEM_USB, id));
53}
54
40#else55#else
41 56
42static inline void kcov_task_init(struct task_struct *t) {}57static inline void kcov_task_init(struct task_struct *t) {}
43static inline void kcov_task_exit(struct task_struct *t) {}58static inline void kcov_task_exit(struct task_struct *t) {}
44static inline void kcov_prepare_switch(struct task_struct *t) {}59static inline void kcov_prepare_switch(struct task_struct *t) {}
45static inline void kcov_finish_switch(struct task_struct *t) {}60static inline void kcov_finish_switch(struct task_struct *t) {}
61static inline void kcov_remote_start(u64 handle) {}
62static inline void kcov_remote_stop(void) {}
63static inline u64 kcov_common_handle(void)
64{
65 return 0;
66}
67static inline void kcov_remote_start_common(u64 id) {}
68static inline void kcov_remote_start_usb(u64 id) {}
46 69
47#endif /* CONFIG_KCOV */70#endif /* CONFIG_KCOV */
48#endif /* _LINUX_KCOV_H */71#endif /* _LINUX_KCOV_H */
include/linux/kernel.h+14−5
@@ -348,8 +348,7 @@ int __must_check kstrtoll(const char *s, unsigned int base, long long *res); · 347 unmodified lines
348 * @res: Where to write the result of the conversion on success.348 * @res: Where to write the result of the conversion on success.
349 *349 *
350 * Returns 0 on success, -ERANGE on overflow and -EINVAL on parsing error.350 * Returns 0 on success, -ERANGE on overflow and -EINVAL on parsing error.
351 * Used as a replacement for the obsolete simple_strtoull. Return code must351 * Used as a replacement for the simple_strtoull. Return code must be checked.
352 * be checked.
353*/352*/
354static inline int __must_check kstrtoul(const char *s, unsigned int base, unsigned long *res)353static inline int __must_check kstrtoul(const char *s, unsigned int base, unsigned long *res)
355{354{
@@ -377,8 +376,7 @@ static inline int __must_check kstrtoul(const char *s, unsigned int base, unsign · 21 unmodified lines
377 * @res: Where to write the result of the conversion on success.376 * @res: Where to write the result of the conversion on success.
378 *377 *
379 * Returns 0 on success, -ERANGE on overflow and -EINVAL on parsing error.378 * Returns 0 on success, -ERANGE on overflow and -EINVAL on parsing error.
380 * Used as a replacement for the obsolete simple_strtoull. Return code must379 * Used as a replacement for the simple_strtoull. Return code must be checked.
381 * be checked.
382 */380 */
383static inline int __must_check kstrtol(const char *s, unsigned int base, long *res)381static inline int __must_check kstrtol(const char *s, unsigned int base, long *res)
384{382{
@@ -454,7 +452,18 @@ static inline int __must_check kstrtos32_from_user(const char __user *s, size_t · 69 unmodified lines
454 return kstrtoint_from_user(s, count, base, res);452 return kstrtoint_from_user(s, count, base, res);
455}453}
456 454
457/* Obsolete, do not use. Use kstrto<foo> instead */455/*
456 * Use kstrto<foo> instead.
457 *
458 * NOTE: simple_strto<foo> does not check for the range overflow and,
459 * depending on the input, may give interesting results.
460 *
461 * Use these functions if and only if you cannot use kstrto<foo>, because
462 * the conversion ends on the first non-digit character, which may be far
463 * beyond the supported range. It might be useful to parse the strings like
464 * 10x50 or 12:21 without altering original string or temporary buffer in use.
465 * Keep in mind above caveat.
466 */
458 467
459extern unsigned long simple_strtoul(const char *,char **,unsigned int);468extern unsigned long simple_strtoul(const char *,char **,unsigned int);
460extern long simple_strtol(const char *,char **,unsigned int);469extern long simple_strtol(const char *,char **,unsigned int);
include/linux/kvm_host.h+1−1
@@ -149,7 +149,7 @@ static inline bool is_error_page(struct page *page) · 148 unmodified lines
149#define KVM_REQUEST_ARCH_BASE 8149#define KVM_REQUEST_ARCH_BASE 8
150 150
151#define KVM_ARCH_REQ_FLAGS(nr, flags) ({ \151#define KVM_ARCH_REQ_FLAGS(nr, flags) ({ \
152 BUILD_BUG_ON((unsigned)(nr) >= (FIELD_SIZEOF(struct kvm_vcpu, requests) * 8) - KVM_REQUEST_ARCH_BASE); \152 BUILD_BUG_ON((unsigned)(nr) >= (sizeof_field(struct kvm_vcpu, requests) * 8) - KVM_REQUEST_ARCH_BASE); \
153 (unsigned)(((nr) + KVM_REQUEST_ARCH_BASE) | (flags)); \153 (unsigned)(((nr) + KVM_REQUEST_ARCH_BASE) | (flags)); \
154})154})
155#define KVM_ARCH_REQ(nr) KVM_ARCH_REQ_FLAGS(nr, 0)155#define KVM_ARCH_REQ(nr) KVM_ARCH_REQ_FLAGS(nr, 0)
include/linux/lockd/debug.h+0−4
@@ -10,8 +10,6 @@ · 9 unmodified lines
10#ifndef LINUX_LOCKD_DEBUG_H10#ifndef LINUX_LOCKD_DEBUG_H
11#define LINUX_LOCKD_DEBUG_H11#define LINUX_LOCKD_DEBUG_H
12 12
13#ifdef __KERNEL__
14
15#include <linux/sunrpc/debug.h>13#include <linux/sunrpc/debug.h>
16 14
17/*15/*
@@ -25,8 +23,6 @@ · 7 unmodified lines
25# define ifdebug(flag) if (0)23# define ifdebug(flag) if (0)
26#endif24#endif
27 25
28#endif /* __KERNEL__ */
29
30/*26/*
31 * Debug flags27 * Debug flags
32 */28 */
include/linux/lockd/lockd.h+0−4
@@ -10,8 +10,6 @@ · 9 unmodified lines
10#ifndef LINUX_LOCKD_LOCKD_H10#ifndef LINUX_LOCKD_LOCKD_H
11#define LINUX_LOCKD_LOCKD_H11#define LINUX_LOCKD_LOCKD_H
12 12
13#ifdef __KERNEL__
14
15#include <linux/in.h>13#include <linux/in.h>
16#include <linux/in6.h>14#include <linux/in6.h>
17#include <net/ipv6.h>15#include <net/ipv6.h>
@@ -373,6 +371,4 @@ static inline int nlm_compare_locks(const struct file_lock *fl1, · 355 unmodified lines
373 371
374extern const struct lock_manager_operations nlmsvc_lock_operations;372extern const struct lock_manager_operations nlmsvc_lock_operations;
375 373
376#endif /* __KERNEL__ */
377
378#endif /* LINUX_LOCKD_LOCKD_H */374#endif /* LINUX_LOCKD_LOCKD_H */
include/linux/logic_pio.h+2−2
@@ -108,10 +108,10 @@ void logic_outsl(unsigned long addr, const void *buffer, unsigned int count); · 107 unmodified lines
108 * area by redefining the macro below.108 * area by redefining the macro below.
109 */109 */
110#define PIO_INDIRECT_SIZE 0x4000110#define PIO_INDIRECT_SIZE 0x4000
111#define MMIO_UPPER_LIMIT (IO_SPACE_LIMIT - PIO_INDIRECT_SIZE)
112#else111#else
113#define MMIO_UPPER_LIMIT IO_SPACE_LIMIT112#define PIO_INDIRECT_SIZE 0
114#endif /* CONFIG_INDIRECT_PIO */113#endif /* CONFIG_INDIRECT_PIO */
114#define MMIO_UPPER_LIMIT (IO_SPACE_LIMIT - PIO_INDIRECT_SIZE)
115 115
116struct logic_pio_hwaddr *find_io_range_by_fwnode(struct fwnode_handle *fwnode);116struct logic_pio_hwaddr *find_io_range_by_fwnode(struct fwnode_handle *fwnode);
117unsigned long logic_pio_trans_hwaddr(struct fwnode_handle *fwnode,117unsigned long logic_pio_trans_hwaddr(struct fwnode_handle *fwnode,
include/linux/mfd/stm32-timers.h+4−8
@@ -70,14 +70,11 @@ · 69 unmodified lines
70#define TIM_CCER_CC4E BIT(12) /* Capt/Comp 4 out Ena */70#define TIM_CCER_CC4E BIT(12) /* Capt/Comp 4 out Ena */
71#define TIM_CCER_CC4P BIT(13) /* Capt/Comp 4 Polarity */71#define TIM_CCER_CC4P BIT(13) /* Capt/Comp 4 Polarity */
72#define TIM_CCER_CCXE (BIT(0) | BIT(4) | BIT(8) | BIT(12))72#define TIM_CCER_CCXE (BIT(0) | BIT(4) | BIT(8) | BIT(12))
73#define TIM_BDTR_BKE BIT(12) /* Break input enable */73#define TIM_BDTR_BKE(x) BIT(12 + (x) * 12) /* Break input enable */
74#define TIM_BDTR_BKP BIT(13) /* Break input polarity */74#define TIM_BDTR_BKP(x) BIT(13 + (x) * 12) /* Break input polarity */
75#define TIM_BDTR_AOE BIT(14) /* Automatic Output Enable */75#define TIM_BDTR_AOE BIT(14) /* Automatic Output Enable */
76#define TIM_BDTR_MOE BIT(15) /* Main Output Enable */76#define TIM_BDTR_MOE BIT(15) /* Main Output Enable */
77#define TIM_BDTR_BKF (BIT(16) | BIT(17) | BIT(18) | BIT(19))77#define TIM_BDTR_BKF(x) (0xf << (16 + (x) * 4))
78#define TIM_BDTR_BK2F (BIT(20) | BIT(21) | BIT(22) | BIT(23))
79#define TIM_BDTR_BK2E BIT(24) /* Break 2 input enable */
80#define TIM_BDTR_BK2P BIT(25) /* Break 2 input polarity */
81#define TIM_DCR_DBA GENMASK(4, 0) /* DMA base addr */78#define TIM_DCR_DBA GENMASK(4, 0) /* DMA base addr */
82#define TIM_DCR_DBL GENMASK(12, 8) /* DMA burst len */79#define TIM_DCR_DBL GENMASK(12, 8) /* DMA burst len */
83 80
@@ -87,8 +84,7 @@ · 3 unmodified lines
87#define TIM_CR2_MMS2_SHIFT 2084#define TIM_CR2_MMS2_SHIFT 20
88#define TIM_SMCR_TS_SHIFT 485#define TIM_SMCR_TS_SHIFT 4
89#define TIM_BDTR_BKF_MASK 0xF86#define TIM_BDTR_BKF_MASK 0xF
90#define TIM_BDTR_BKF_SHIFT 1687#define TIM_BDTR_BKF_SHIFT(x) (16 + (x) * 4)
91#define TIM_BDTR_BK2F_SHIFT 20
92 88
93enum stm32_timers_dmas {89enum stm32_timers_dmas {
94 STM32_TIMERS_DMA_CH1,90 STM32_TIMERS_DMA_CH1,
include/linux/mfd/syscon/atmel-matrix.h+0−1
@@ -106,7 +106,6 @@ · 105 unmodified lines
106#define AT91_MATRIX_DDR_IOSR BIT(18)106#define AT91_MATRIX_DDR_IOSR BIT(18)
107#define AT91_MATRIX_NFD0_SELECT BIT(24)107#define AT91_MATRIX_NFD0_SELECT BIT(24)
108#define AT91_MATRIX_DDR_MP_EN BIT(25)108#define AT91_MATRIX_DDR_MP_EN BIT(25)
109#define AT91_MATRIX_EBI_NUM_CS 8
110 109
111#define AT91_MATRIX_USBPUCR_PUON BIT(30)110#define AT91_MATRIX_USBPUCR_PUON BIT(30)
112 111
include/linux/miscdevice.h+1−0
@@ -33,6 +33,7 @@ · 32 unmodified lines
33#define SGI_MMTIMER 15333#define SGI_MMTIMER 153
34#define STORE_QUEUE_MINOR 155 /* unused */34#define STORE_QUEUE_MINOR 155 /* unused */
35#define I2O_MINOR 16635#define I2O_MINOR 166
36#define AGPGART_MINOR 175
36#define HWRNG_MINOR 18337#define HWRNG_MINOR 183
37#define MICROCODE_MINOR 18438#define MICROCODE_MINOR 184
38#define IRNET_MINOR 18739#define IRNET_MINOR 187
include/linux/mm.h+8−5
@@ -1838,12 +1838,12 @@ static inline void mm_dec_nr_ptes(struct mm_struct *mm) {} · 1837 unmodified lines
1838int __pte_alloc(struct mm_struct *mm, pmd_t *pmd);1838int __pte_alloc(struct mm_struct *mm, pmd_t *pmd);
1839int __pte_alloc_kernel(pmd_t *pmd);1839int __pte_alloc_kernel(pmd_t *pmd);
1840 1840
1841#if defined(CONFIG_MMU)
1842
1841/*1843/*
1842 * The following ifdef needed to get the 4level-fixup.h header to work.1844 * The following ifdef needed to get the 5level-fixup.h header to work.
1843 * Remove it when 4level-fixup.h has been removed.1845 * Remove it when 5level-fixup.h has been removed.
1844 */1846 */
1845#if defined(CONFIG_MMU) && !defined(__ARCH_HAS_4LEVEL_HACK)
1846
1847#ifndef __ARCH_HAS_5LEVEL_HACK1847#ifndef __ARCH_HAS_5LEVEL_HACK
1848static inline p4d_t *p4d_alloc(struct mm_struct *mm, pgd_t *pgd,1848static inline p4d_t *p4d_alloc(struct mm_struct *mm, pgd_t *pgd,
1849 unsigned long address)1849 unsigned long address)
@@ -1865,7 +1865,7 @@ static inline pmd_t *pmd_alloc(struct mm_struct *mm, pud_t *pud, unsigned long a · 15 unmodified lines
1865 return (unlikely(pud_none(*pud)) && __pmd_alloc(mm, pud, address))?1865 return (unlikely(pud_none(*pud)) && __pmd_alloc(mm, pud, address))?
1866 NULL: pmd_offset(pud, address);1866 NULL: pmd_offset(pud, address);
1867}1867}
1868#endif /* CONFIG_MMU && !__ARCH_HAS_4LEVEL_HACK */1868#endif /* CONFIG_MMU */
1869 1869
1870#if USE_SPLIT_PTE_PTLOCKS1870#if USE_SPLIT_PTE_PTLOCKS
1871#if ALLOC_SPLIT_PTLOCKS1871#if ALLOC_SPLIT_PTLOCKS
@@ -2621,6 +2621,9 @@ static inline int vm_fault_to_errno(vm_fault_t vm_fault, int foll_flags) · 749 unmodified lines
2621typedef int (*pte_fn_t)(pte_t *pte, unsigned long addr, void *data);2621typedef int (*pte_fn_t)(pte_t *pte, unsigned long addr, void *data);
2622extern int apply_to_page_range(struct mm_struct *mm, unsigned long address,2622extern int apply_to_page_range(struct mm_struct *mm, unsigned long address,
2623 unsigned long size, pte_fn_t fn, void *data);2623 unsigned long size, pte_fn_t fn, void *data);
2624extern int apply_to_existing_page_range(struct mm_struct *mm,
2625 unsigned long address, unsigned long size,
2626 pte_fn_t fn, void *data);
2624 2627
2625#ifdef CONFIG_PAGE_POISONING2628#ifdef CONFIG_PAGE_POISONING
2626extern bool page_poisoning_enabled(void);2629extern bool page_poisoning_enabled(void);
include/linux/mod_devicetable.h+2−2
@@ -587,9 +587,9 @@ struct platform_device_id { · 586 unmodified lines
587#define MDIO_NAME_SIZE 32587#define MDIO_NAME_SIZE 32
588#define MDIO_MODULE_PREFIX "mdio:"588#define MDIO_MODULE_PREFIX "mdio:"
589 589
590#define MDIO_ID_FMT "%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d"590#define MDIO_ID_FMT "%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u%u"
591#define MDIO_ID_ARGS(_id) \591#define MDIO_ID_ARGS(_id) \
592 (_id)>>31, ((_id)>>30) & 1, ((_id)>>29) & 1, ((_id)>>28) & 1, \592 ((_id)>>31) & 1, ((_id)>>30) & 1, ((_id)>>29) & 1, ((_id)>>28) & 1, \
593 ((_id)>>27) & 1, ((_id)>>26) & 1, ((_id)>>25) & 1, ((_id)>>24) & 1, \593 ((_id)>>27) & 1, ((_id)>>26) & 1, ((_id)>>25) & 1, ((_id)>>24) & 1, \
594 ((_id)>>23) & 1, ((_id)>>22) & 1, ((_id)>>21) & 1, ((_id)>>20) & 1, \594 ((_id)>>23) & 1, ((_id)>>22) & 1, ((_id)>>21) & 1, ((_id)>>20) & 1, \
595 ((_id)>>19) & 1, ((_id)>>18) & 1, ((_id)>>17) & 1, ((_id)>>16) & 1, \595 ((_id)>>19) & 1, ((_id)>>18) & 1, ((_id)>>17) & 1, ((_id)>>16) & 1, \
include/linux/moduleparam.h+2−2
@@ -100,11 +100,11 @@ struct kparam_array · 99 unmodified lines
100 100
101/**101/**
102 * module_param - typesafe helper for a module/cmdline parameter102 * module_param - typesafe helper for a module/cmdline parameter
103 * @value: the variable to alter, and exposed parameter name.103 * @name: the variable to alter, and exposed parameter name.
104 * @type: the type of the parameter104 * @type: the type of the parameter
105 * @perm: visibility in sysfs.105 * @perm: visibility in sysfs.
106 *106 *
107 * @value becomes the module parameter, or (prefixed by KBUILD_MODNAME and a107 * @name becomes the module parameter, or (prefixed by KBUILD_MODNAME and a
108 * ".") the kernel commandline parameter. Note that - is changed to _, so108 * ".") the kernel commandline parameter. Note that - is changed to _, so
109 * the user can use "foo-bar=1" even for variable "foo_bar".109 * the user can use "foo-bar=1" even for variable "foo_bar".
110 *110 *
include/linux/namei.h+1−0
@@ -60,6 +60,7 @@ extern int kern_path_mountpoint(int, const char *, struct path *, unsigned int); · 59 unmodified lines
60extern struct dentry *try_lookup_one_len(const char *, struct dentry *, int);60extern struct dentry *try_lookup_one_len(const char *, struct dentry *, int);
61extern struct dentry *lookup_one_len(const char *, struct dentry *, int);61extern struct dentry *lookup_one_len(const char *, struct dentry *, int);
62extern struct dentry *lookup_one_len_unlocked(const char *, struct dentry *, int);62extern struct dentry *lookup_one_len_unlocked(const char *, struct dentry *, int);
63extern struct dentry *lookup_positive_unlocked(const char *, struct dentry *, int);
63 64
64extern int follow_down_one(struct path *);65extern int follow_down_one(struct path *);
65extern int follow_down(struct path *);66extern int follow_down(struct path *);
include/linux/netdevice.h+6−1
@@ -1775,7 +1775,7 @@ enum netdev_priv_flags { · 1774 unmodified lines
1775 * for hardware timestamping1775 * for hardware timestamping
1776 * @sfp_bus: attached &struct sfp_bus structure.1776 * @sfp_bus: attached &struct sfp_bus structure.
1777 * @qdisc_tx_busylock_key: lockdep class annotating Qdisc->busylock1777 * @qdisc_tx_busylock_key: lockdep class annotating Qdisc->busylock
1778 spinlock1778 * spinlock
1779 * @qdisc_running_key: lockdep class annotating Qdisc->running seqcount1779 * @qdisc_running_key: lockdep class annotating Qdisc->running seqcount
1780 * @qdisc_xmit_lock_key: lockdep class annotating1780 * @qdisc_xmit_lock_key: lockdep class annotating
1781 * netdev_queue->_xmit_lock spinlock1781 * netdev_queue->_xmit_lock spinlock
@@ -1881,6 +1881,11 @@ struct net_device { · 99 unmodified lines
1881 unsigned char if_port;1881 unsigned char if_port;
1882 unsigned char dma;1882 unsigned char dma;
1883 1883
1884 /* Note : dev->mtu is often read without holding a lock.
1885 * Writers usually hold RTNL.
1886 * It is recommended to use READ_ONCE() to annotate the reads,
1887 * and to use WRITE_ONCE() to annotate the writes.
1888 */
1884 unsigned int mtu;1889 unsigned int mtu;
1885 unsigned int min_mtu;1890 unsigned int min_mtu;
1886 unsigned int max_mtu;1891 unsigned int max_mtu;
include/linux/nfs4.h+26−0
@@ -16,6 +16,7 @@ · 15 unmodified lines
16#include <linux/list.h>16#include <linux/list.h>
17#include <linux/uidgid.h>17#include <linux/uidgid.h>
18#include <uapi/linux/nfs4.h>18#include <uapi/linux/nfs4.h>
19#include <linux/sunrpc/msg_prot.h>
19 20
20enum nfs4_acl_whotype {21enum nfs4_acl_whotype {
21 NFS4_ACL_WHO_NAMED = 0,22 NFS4_ACL_WHO_NAMED = 0,
@@ -539,6 +540,8 @@ enum { · 517 unmodified lines
539 540
540 NFSPROC4_CLNT_LOOKUPP,541 NFSPROC4_CLNT_LOOKUPP,
541 NFSPROC4_CLNT_LAYOUTERROR,542 NFSPROC4_CLNT_LAYOUTERROR,
543
544 NFSPROC4_CLNT_COPY_NOTIFY,
542};545};
543 546
544/* nfs41 types */547/* nfs41 types */
@@ -674,4 +677,27 @@ struct nfs4_op_map { · 129 unmodified lines
674 } u;677 } u;
675};678};
676 679
680struct nfs42_netaddr {
681 char netid[RPCBIND_MAXNETIDLEN];
682 char addr[RPCBIND_MAXUADDRLEN + 1];
683 u32 netid_len;
684 u32 addr_len;
685};
686
687enum netloc_type4 {
688 NL4_NAME = 1,
689 NL4_URL = 2,
690 NL4_NETADDR = 3,
691};
692
693struct nl4_server {
694 enum netloc_type4 nl4_type;
695 union {
696 struct { /* NL4_NAME, NL4_URL */
697 int nl4_str_sz;
698 char nl4_str[NFS4_OPAQUE_LIMIT + 1];
699 };
700 struct nfs42_netaddr nl4_addr; /* NL4_NETADDR */
701 } u;
702};
677#endif703#endif
include/linux/nfs_fs.h+3−1
@@ -189,13 +189,15 @@ struct nfs_inode { · 188 unmodified lines
189 189
190struct nfs4_copy_state {190struct nfs4_copy_state {
191 struct list_head copies;191 struct list_head copies;
192 struct list_head src_copies;
192 nfs4_stateid stateid;193 nfs4_stateid stateid;
193 struct completion completion;194 struct completion completion;
194 uint64_t count;195 uint64_t count;
195 struct nfs_writeverf verf;196 struct nfs_writeverf verf;
196 int error;197 int error;
197 int flags;198 int flags;
198 struct nfs4_state *parent_state;199 struct nfs4_state *parent_src_state;
200 struct nfs4_state *parent_dst_state;
199};201};
200 202
201/*203/*
include/linux/nfs_fs_sb.h+5−1
@@ -45,6 +45,9 @@ struct nfs_client { · 44 unmodified lines
45#define NFS_CS_INFINITE_SLOTS 3 /* - don't limit TCP slots */45#define NFS_CS_INFINITE_SLOTS 3 /* - don't limit TCP slots */
46#define NFS_CS_NO_RETRANS_TIMEOUT 4 /* - Disable retransmit timeouts */46#define NFS_CS_NO_RETRANS_TIMEOUT 4 /* - Disable retransmit timeouts */
47#define NFS_CS_TSM_POSSIBLE 5 /* - Maybe state migration */47#define NFS_CS_TSM_POSSIBLE 5 /* - Maybe state migration */
48#define NFS_CS_NOPING 6 /* - don't ping on connect */
49#define NFS_CS_DS 7 /* - Server is a DS */
50#define NFS_CS_REUSEPORT 8 /* - reuse src port on reconnect */
48 struct sockaddr_storage cl_addr; /* server identifier */51 struct sockaddr_storage cl_addr; /* server identifier */
49 size_t cl_addrlen;52 size_t cl_addrlen;
50 char * cl_hostname; /* hostname of server */53 char * cl_hostname; /* hostname of server */
@@ -171,7 +174,7 @@ struct nfs_server { · 120 unmodified lines
171 174
172 struct nfs_fsid fsid;175 struct nfs_fsid fsid;
173 __u64 maxfilesize; /* maximum file size */176 __u64 maxfilesize; /* maximum file size */
174 struct timespec time_delta; /* smallest time granularity */177 struct timespec64 time_delta; /* smallest time granularity */
175 unsigned long mount_time; /* when this fs was mounted */178 unsigned long mount_time; /* when this fs was mounted */
176 struct super_block *super; /* VFS super block */179 struct super_block *super; /* VFS super block */
177 dev_t s_dev; /* superblock dev numbers */180 dev_t s_dev; /* superblock dev numbers */
@@ -276,5 +279,6 @@ struct nfs_server { · 98 unmodified lines
276#define NFS_CAP_COPY (1U << 24)279#define NFS_CAP_COPY (1U << 24)
277#define NFS_CAP_OFFLOAD_CANCEL (1U << 25)280#define NFS_CAP_OFFLOAD_CANCEL (1U << 25)
278#define NFS_CAP_LAYOUTERROR (1U << 26)281#define NFS_CAP_LAYOUTERROR (1U << 26)
282#define NFS_CAP_COPY_NOTIFY (1U << 27)
279 283
280#endif284#endif
include/linux/nfs_xdr.h+24−7
@@ -62,14 +62,14 @@ struct nfs_fattr { · 61 unmodified lines
62 struct nfs_fsid fsid;62 struct nfs_fsid fsid;
63 __u64 fileid;63 __u64 fileid;
64 __u64 mounted_on_fileid;64 __u64 mounted_on_fileid;
65 struct timespec atime;65 struct timespec64 atime;
66 struct timespec mtime;66 struct timespec64 mtime;
67 struct timespec ctime;67 struct timespec64 ctime;
68 __u64 change_attr; /* NFSv4 change attribute */68 __u64 change_attr; /* NFSv4 change attribute */
69 __u64 pre_change_attr;/* pre-op NFSv4 change attribute */69 __u64 pre_change_attr;/* pre-op NFSv4 change attribute */
70 __u64 pre_size; /* pre_op_attr.size */70 __u64 pre_size; /* pre_op_attr.size */
71 struct timespec pre_mtime; /* pre_op_attr.mtime */71 struct timespec64 pre_mtime; /* pre_op_attr.mtime */
72 struct timespec pre_ctime; /* pre_op_attr.ctime */72 struct timespec64 pre_ctime; /* pre_op_attr.ctime */
73 unsigned long time_start;73 unsigned long time_start;
74 unsigned long gencount;74 unsigned long gencount;
75 struct nfs4_string *owner_name;75 struct nfs4_string *owner_name;
@@ -143,7 +143,7 @@ struct nfs_fsinfo { · 67 unmodified lines
143 __u32 wtmult; /* writes should be multiple of this */143 __u32 wtmult; /* writes should be multiple of this */
144 __u32 dtpref; /* pref. readdir transfer size */144 __u32 dtpref; /* pref. readdir transfer size */
145 __u64 maxfilesize;145 __u64 maxfilesize;
146 struct timespec time_delta; /* server time granularity */146 struct timespec64 time_delta; /* server time granularity */
147 __u32 lease_time; /* in seconds */147 __u32 lease_time; /* in seconds */
148 __u32 nlayouttypes; /* number of layouttypes */148 __u32 nlayouttypes; /* number of layouttypes */
149 __u32 layouttype[NFS_MAX_LAYOUT_TYPES]; /* supported pnfs layout driver */149 __u32 layouttype[NFS_MAX_LAYOUT_TYPES]; /* supported pnfs layout driver */
@@ -869,7 +869,7 @@ struct nfs3_sattrargs { · 719 unmodified lines
869 struct nfs_fh * fh;869 struct nfs_fh * fh;
870 struct iattr * sattr;870 struct iattr * sattr;
871 unsigned int guard;871 unsigned int guard;
872 struct timespec guardtime;872 struct timespec64 guardtime;
873};873};
874 874
875struct nfs3_diropargs {875struct nfs3_diropargs {
@@ -1435,6 +1435,7 @@ struct nfs42_copy_args { · 559 unmodified lines
1435 1435
1436 u64 count;1436 u64 count;
1437 bool sync;1437 bool sync;
1438 struct nl4_server *cp_src;
1438};1439};
1439 1440
1440struct nfs42_write_res {1441struct nfs42_write_res {
@@ -1463,6 +1464,22 @@ struct nfs42_offload_status_res { · 22 unmodified lines
1463 int osr_status;1464 int osr_status;
1464};1465};
1465 1466
1467struct nfs42_copy_notify_args {
1468 struct nfs4_sequence_args cna_seq_args;
1469
1470 struct nfs_fh *cna_src_fh;
1471 nfs4_stateid cna_src_stateid;
1472 struct nl4_server cna_dst;
1473};
1474
1475struct nfs42_copy_notify_res {
1476 struct nfs4_sequence_res cnr_seq_res;
1477
1478 struct nfstime4 cnr_lease_time;
1479 nfs4_stateid cnr_stateid;
1480 struct nl4_server cnr_src;
1481};
1482
1466struct nfs42_seek_args {1483struct nfs42_seek_args {
1467 struct nfs4_sequence_args seq_args;1484 struct nfs4_sequence_args seq_args;
1468 1485
include/linux/notifier.h+0−4
@@ -150,10 +150,6 @@ extern int raw_notifier_chain_register(struct raw_notifier_head *nh, · 149 unmodified lines
150extern int srcu_notifier_chain_register(struct srcu_notifier_head *nh,150extern int srcu_notifier_chain_register(struct srcu_notifier_head *nh,
151 struct notifier_block *nb);151 struct notifier_block *nb);
152 152
153extern int blocking_notifier_chain_cond_register(
154 struct blocking_notifier_head *nh,
155 struct notifier_block *nb);
156
157extern int atomic_notifier_chain_unregister(struct atomic_notifier_head *nh,153extern int atomic_notifier_chain_unregister(struct atomic_notifier_head *nh,
158 struct notifier_block *nb);154 struct notifier_block *nb);
159extern int blocking_notifier_chain_unregister(struct blocking_notifier_head *nh,155extern int blocking_notifier_chain_unregister(struct blocking_notifier_head *nh,
include/linux/nvme-fc-driver.h+4−0
@@ -270,6 +270,8 @@ struct nvme_fc_remote_port { · 269 unmodified lines
270 *270 *
271 * Host/Initiator Transport Entrypoints/Parameters:271 * Host/Initiator Transport Entrypoints/Parameters:
272 *272 *
273 * @module: The LLDD module using the interface
274 *
273 * @localport_delete: The LLDD initiates deletion of a localport via275 * @localport_delete: The LLDD initiates deletion of a localport via
274 * nvme_fc_deregister_localport(). However, the teardown is276 * nvme_fc_deregister_localport(). However, the teardown is
275 * asynchronous. This routine is called upon the completion of the277 * asynchronous. This routine is called upon the completion of the
@@ -383,6 +385,8 @@ struct nvme_fc_remote_port { · 107 unmodified lines
383 * Value is Mandatory. Allowed to be zero.385 * Value is Mandatory. Allowed to be zero.
384 */386 */
385struct nvme_fc_port_template {387struct nvme_fc_port_template {
388 struct module *module;
389
386 /* initiator-based functions */390 /* initiator-based functions */
387 void (*localport_delete)(struct nvme_fc_local_port *);391 void (*localport_delete)(struct nvme_fc_local_port *);
388 void (*remoteport_delete)(struct nvme_fc_remote_port *);392 void (*remoteport_delete)(struct nvme_fc_remote_port *);
include/linux/of_mdio.h+6−0
@@ -12,6 +12,7 @@ · 11 unmodified lines
12#include <linux/of.h>12#include <linux/of.h>
13 13
14#if IS_ENABLED(CONFIG_OF_MDIO)14#if IS_ENABLED(CONFIG_OF_MDIO)
15extern bool of_mdiobus_child_is_phy(struct device_node *child);
15extern int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np);16extern int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np);
16extern struct phy_device *of_phy_find_device(struct device_node *phy_np);17extern struct phy_device *of_phy_find_device(struct device_node *phy_np);
17extern struct phy_device *of_phy_connect(struct net_device *dev,18extern struct phy_device *of_phy_connect(struct net_device *dev,
@@ -54,6 +55,11 @@ static inline int of_mdio_parse_addr(struct device *dev, · 36 unmodified lines
54}55}
55 56
56#else /* CONFIG_OF_MDIO */57#else /* CONFIG_OF_MDIO */
58static bool of_mdiobus_child_is_phy(struct device_node *child)
59{
60 return false;
61}
62
57static inline int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)63static inline int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)
58{64{
59 /*65 /*
include/linux/phy.h+1−1
@@ -1000,7 +1000,7 @@ int phy_modify_paged_changed(struct phy_device *phydev, int page, u32 regnum, · 999 unmodified lines
1000int phy_modify_paged(struct phy_device *phydev, int page, u32 regnum,1000int phy_modify_paged(struct phy_device *phydev, int page, u32 regnum,
1001 u16 mask, u16 set);1001 u16 mask, u16 set);
1002 1002
1003struct phy_device *phy_device_create(struct mii_bus *bus, int addr, int phy_id,1003struct phy_device *phy_device_create(struct mii_bus *bus, int addr, u32 phy_id,
1004 bool is_c45,1004 bool is_c45,
1005 struct phy_c45_device_ids *c45_ids);1005 struct phy_c45_device_ids *c45_ids);
1006#if IS_ENABLED(CONFIG_PHYLIB)1006#if IS_ENABLED(CONFIG_PHYLIB)
include/linux/phy_led_triggers.h+1−1
@@ -14,7 +14,7 @@ struct phy_device; · 13 unmodified lines
14#define PHY_LED_TRIGGER_SPEED_SUFFIX_SIZE 1114#define PHY_LED_TRIGGER_SPEED_SUFFIX_SIZE 11
15 15
16#define PHY_LINK_LED_TRIGGER_NAME_SIZE (MII_BUS_ID_SIZE + \16#define PHY_LINK_LED_TRIGGER_NAME_SIZE (MII_BUS_ID_SIZE + \
17 FIELD_SIZEOF(struct mdio_device, addr)+\17 sizeof_field(struct mdio_device, addr)+\
18 PHY_LED_TRIGGER_SPEED_SUFFIX_SIZE)18 PHY_LED_TRIGGER_SPEED_SUFFIX_SIZE)
19 19
20struct phy_led_trigger {20struct phy_led_trigger {
include/linux/pipe_fs_i.h+0−2
@@ -38,7 +38,6 @@ struct pipe_buffer { · 37 unmodified lines
38 * @readers: number of current readers of this pipe38 * @readers: number of current readers of this pipe
39 * @writers: number of current writers of this pipe39 * @writers: number of current writers of this pipe
40 * @files: number of struct file referring this pipe (protected by ->i_lock)40 * @files: number of struct file referring this pipe (protected by ->i_lock)
41 * @waiting_writers: number of writers blocked waiting for room
42 * @r_counter: reader counter41 * @r_counter: reader counter
43 * @w_counter: writer counter42 * @w_counter: writer counter
44 * @fasync_readers: reader side fasync43 * @fasync_readers: reader side fasync
@@ -56,7 +55,6 @@ struct pipe_inode_info { · 11 unmodified lines
56 unsigned int readers;55 unsigned int readers;
57 unsigned int writers;56 unsigned int writers;
58 unsigned int files;57 unsigned int files;
59 unsigned int waiting_writers;
60 unsigned int r_counter;58 unsigned int r_counter;
61 unsigned int w_counter;59 unsigned int w_counter;
62 struct page *tmp_page;60 struct page *tmp_page;
include/linux/platform_data/ti-prm.h+21−0
@@ -0,0 +1,21 @@
1/* SPDX-License-Identifier: GPL-2.0-only */
2/*
3 * TI PRM (Power & Reset Manager) platform data
4 *
5 * Copyright (C) 2019 Texas Instruments, Inc.
6 *
7 * Tero Kristo <t-kristo@ti.com>
8 */
9
10#ifndef _LINUX_PLATFORM_DATA_TI_PRM_H
11#define _LINUX_PLATFORM_DATA_TI_PRM_H
12
13struct clockdomain;
14
15struct ti_prm_platform_data {
16 void (*clkdm_deny_idle)(struct clockdomain *clkdm);
17 void (*clkdm_allow_idle)(struct clockdomain *clkdm);
18 struct clockdomain * (*clkdm_lookup)(const char *name);
19};
20
21#endif /* _LINUX_PLATFORM_DATA_TI_PRM_H */
include/linux/platform_data/ti-sysc.h+2−0
@@ -49,6 +49,8 @@ struct sysc_regbits { · 48 unmodified lines
49 s8 emufree_shift;49 s8 emufree_shift;
50};50};
51 51
52#define SYSC_QUIRK_FORCE_MSTANDBY BIT(20)
53#define SYSC_MODULE_QUIRK_AESS BIT(19)
52#define SYSC_MODULE_QUIRK_SGX BIT(18)54#define SYSC_MODULE_QUIRK_SGX BIT(18)
53#define SYSC_MODULE_QUIRK_HDQ1W BIT(17)55#define SYSC_MODULE_QUIRK_HDQ1W BIT(17)
54#define SYSC_MODULE_QUIRK_I2C BIT(16)56#define SYSC_MODULE_QUIRK_I2C BIT(16)
include/linux/pm_qos.h+50−36
@@ -34,6 +34,8 @@ enum pm_qos_flags_status { · 33 unmodified lines
34#define PM_QOS_RESUME_LATENCY_NO_CONSTRAINT PM_QOS_LATENCY_ANY34#define PM_QOS_RESUME_LATENCY_NO_CONSTRAINT PM_QOS_LATENCY_ANY
35#define PM_QOS_RESUME_LATENCY_NO_CONSTRAINT_NS PM_QOS_LATENCY_ANY_NS35#define PM_QOS_RESUME_LATENCY_NO_CONSTRAINT_NS PM_QOS_LATENCY_ANY_NS
36#define PM_QOS_LATENCY_TOLERANCE_DEFAULT_VALUE 036#define PM_QOS_LATENCY_TOLERANCE_DEFAULT_VALUE 0
37#define PM_QOS_MIN_FREQUENCY_DEFAULT_VALUE 0
38#define PM_QOS_MAX_FREQUENCY_DEFAULT_VALUE FREQ_QOS_MAX_DEFAULT_VALUE
37#define PM_QOS_LATENCY_TOLERANCE_NO_CONSTRAINT (-1)39#define PM_QOS_LATENCY_TOLERANCE_NO_CONSTRAINT (-1)
38 40
39#define PM_QOS_FLAG_NO_POWER_OFF (1 << 0)41#define PM_QOS_FLAG_NO_POWER_OFF (1 << 0)
@@ -49,21 +51,6 @@ struct pm_qos_flags_request { · 9 unmodified lines
49 s32 flags; /* Do not change to 64 bit */51 s32 flags; /* Do not change to 64 bit */
50};52};
51 53
52enum dev_pm_qos_req_type {
53 DEV_PM_QOS_RESUME_LATENCY = 1,
54 DEV_PM_QOS_LATENCY_TOLERANCE,
55 DEV_PM_QOS_FLAGS,
56};
57
58struct dev_pm_qos_request {
59 enum dev_pm_qos_req_type type;
60 union {
61 struct plist_node pnode;
62 struct pm_qos_flags_request flr;
63 } data;
64 struct device *dev;
65};
66
67enum pm_qos_type {54enum pm_qos_type {
68 PM_QOS_UNITIALIZED,55 PM_QOS_UNITIALIZED,
69 PM_QOS_MAX, /* return the largest value */56 PM_QOS_MAX, /* return the largest value */
@@ -90,9 +77,51 @@ struct pm_qos_flags { · 20 unmodified lines
90 s32 effective_flags; /* Do not change to 64 bit */77 s32 effective_flags; /* Do not change to 64 bit */
91};78};
92 79
80
81#define FREQ_QOS_MIN_DEFAULT_VALUE 0
82#define FREQ_QOS_MAX_DEFAULT_VALUE S32_MAX
83
84enum freq_qos_req_type {
85 FREQ_QOS_MIN = 1,
86 FREQ_QOS_MAX,
87};
88
89struct freq_constraints {
90 struct pm_qos_constraints min_freq;
91 struct blocking_notifier_head min_freq_notifiers;
92 struct pm_qos_constraints max_freq;
93 struct blocking_notifier_head max_freq_notifiers;
94};
95
96struct freq_qos_request {
97 enum freq_qos_req_type type;
98 struct plist_node pnode;
99 struct freq_constraints *qos;
100};
101
102
103enum dev_pm_qos_req_type {
104 DEV_PM_QOS_RESUME_LATENCY = 1,
105 DEV_PM_QOS_LATENCY_TOLERANCE,
106 DEV_PM_QOS_MIN_FREQUENCY,
107 DEV_PM_QOS_MAX_FREQUENCY,
108 DEV_PM_QOS_FLAGS,
109};
110
111struct dev_pm_qos_request {
112 enum dev_pm_qos_req_type type;
113 union {
114 struct plist_node pnode;
115 struct pm_qos_flags_request flr;
116 struct freq_qos_request freq;
117 } data;
118 struct device *dev;
119};
120
93struct dev_pm_qos {121struct dev_pm_qos {
94 struct pm_qos_constraints resume_latency;122 struct pm_qos_constraints resume_latency;
95 struct pm_qos_constraints latency_tolerance;123 struct pm_qos_constraints latency_tolerance;
124 struct freq_constraints freq;
96 struct pm_qos_flags flags;125 struct pm_qos_flags flags;
97 struct dev_pm_qos_request *resume_latency_req;126 struct dev_pm_qos_request *resume_latency_req;
98 struct dev_pm_qos_request *latency_tolerance_req;127 struct dev_pm_qos_request *latency_tolerance_req;
@@ -191,6 +220,10 @@ static inline s32 dev_pm_qos_read_value(struct device *dev, · 92 unmodified lines
191 switch (type) {220 switch (type) {
192 case DEV_PM_QOS_RESUME_LATENCY:221 case DEV_PM_QOS_RESUME_LATENCY:
193 return PM_QOS_RESUME_LATENCY_NO_CONSTRAINT;222 return PM_QOS_RESUME_LATENCY_NO_CONSTRAINT;
223 case DEV_PM_QOS_MIN_FREQUENCY:
224 return PM_QOS_MIN_FREQUENCY_DEFAULT_VALUE;
225 case DEV_PM_QOS_MAX_FREQUENCY:
226 return PM_QOS_MAX_FREQUENCY_DEFAULT_VALUE;
194 default:227 default:
195 WARN_ON(1);228 WARN_ON(1);
196 return 0;229 return 0;
@@ -255,27 +288,6 @@ static inline s32 dev_pm_qos_raw_resume_latency(struct device *dev) · 58 unmodified lines
255}288}
256#endif289#endif
257 290
258#define FREQ_QOS_MIN_DEFAULT_VALUE 0
259#define FREQ_QOS_MAX_DEFAULT_VALUE (-1)
260
261enum freq_qos_req_type {
262 FREQ_QOS_MIN = 1,
263 FREQ_QOS_MAX,
264};
265
266struct freq_constraints {
267 struct pm_qos_constraints min_freq;
268 struct blocking_notifier_head min_freq_notifiers;
269 struct pm_qos_constraints max_freq;
270 struct blocking_notifier_head max_freq_notifiers;
271};
272
273struct freq_qos_request {
274 enum freq_qos_req_type type;
275 struct plist_node pnode;
276 struct freq_constraints *qos;
277};
278
279static inline int freq_qos_request_active(struct freq_qos_request *req)291static inline int freq_qos_request_active(struct freq_qos_request *req)
280{292{
281 return !IS_ERR_OR_NULL(req->qos);293 return !IS_ERR_OR_NULL(req->qos);
@@ -291,6 +303,8 @@ int freq_qos_add_request(struct freq_constraints *qos, · 9 unmodified lines
291 enum freq_qos_req_type type, s32 value);303 enum freq_qos_req_type type, s32 value);
292int freq_qos_update_request(struct freq_qos_request *req, s32 new_value);304int freq_qos_update_request(struct freq_qos_request *req, s32 new_value);
293int freq_qos_remove_request(struct freq_qos_request *req);305int freq_qos_remove_request(struct freq_qos_request *req);
306int freq_qos_apply(struct freq_qos_request *req,
307 enum pm_qos_req_action action, s32 value);
294 308
295int freq_qos_add_notifier(struct freq_constraints *qos,309int freq_qos_add_notifier(struct freq_constraints *qos,
296 enum freq_qos_req_type type,310 enum freq_qos_req_type type,
include/linux/pm_wakeup.h+9−0
@@ -63,6 +63,11 @@ struct wakeup_source { · 62 unmodified lines
63 bool autosleep_enabled:1;63 bool autosleep_enabled:1;
64};64};
65 65
66#define for_each_wakeup_source(ws) \
67 for ((ws) = wakeup_sources_walk_start(); \
68 (ws); \
69 (ws) = wakeup_sources_walk_next((ws)))
70
66#ifdef CONFIG_PM_SLEEP71#ifdef CONFIG_PM_SLEEP
67 72
68/*73/*
@@ -92,6 +97,10 @@ extern void wakeup_source_remove(struct wakeup_source *ws); · 23 unmodified lines
92extern struct wakeup_source *wakeup_source_register(struct device *dev,97extern struct wakeup_source *wakeup_source_register(struct device *dev,
93 const char *name);98 const char *name);
94extern void wakeup_source_unregister(struct wakeup_source *ws);99extern void wakeup_source_unregister(struct wakeup_source *ws);
100extern int wakeup_sources_read_lock(void);
101extern void wakeup_sources_read_unlock(int idx);
102extern struct wakeup_source *wakeup_sources_walk_start(void);
103extern struct wakeup_source *wakeup_sources_walk_next(struct wakeup_source *ws);
95extern int device_wakeup_enable(struct device *dev);104extern int device_wakeup_enable(struct device *dev);
96extern int device_wakeup_disable(struct device *dev);105extern int device_wakeup_disable(struct device *dev);
97extern void device_set_wakeup_capable(struct device *dev, bool capable);106extern void device_set_wakeup_capable(struct device *dev, bool capable);
include/linux/printk.h+1−2
@@ -302,9 +302,8 @@ extern int kptr_restrict; · 301 unmodified lines
302 printk(KERN_CRIT pr_fmt(fmt), ##__VA_ARGS__)302 printk(KERN_CRIT pr_fmt(fmt), ##__VA_ARGS__)
303#define pr_err(fmt, ...) \303#define pr_err(fmt, ...) \
304 printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)304 printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
305#define pr_warning(fmt, ...) \305#define pr_warn(fmt, ...) \
306 printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)306 printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
307#define pr_warn pr_warning
308#define pr_notice(fmt, ...) \307#define pr_notice(fmt, ...) \
309 printk(KERN_NOTICE pr_fmt(fmt), ##__VA_ARGS__)308 printk(KERN_NOTICE pr_fmt(fmt), ##__VA_ARGS__)
310#define pr_info(fmt, ...) \309#define pr_info(fmt, ...) \
include/linux/proc_fs.h+2−2
@@ -58,8 +58,8 @@ extern int remove_proc_subtree(const char *, struct proc_dir_entry *); · 57 unmodified lines
58struct proc_dir_entry *proc_create_net_data(const char *name, umode_t mode,58struct proc_dir_entry *proc_create_net_data(const char *name, umode_t mode,
59 struct proc_dir_entry *parent, const struct seq_operations *ops,59 struct proc_dir_entry *parent, const struct seq_operations *ops,
60 unsigned int state_size, void *data);60 unsigned int state_size, void *data);
61#define proc_create_net(name, mode, parent, state_size, ops) \61#define proc_create_net(name, mode, parent, ops, state_size) \
62 proc_create_net_data(name, mode, parent, state_size, ops, NULL)62 proc_create_net_data(name, mode, parent, ops, state_size, NULL)
63struct proc_dir_entry *proc_create_net_single(const char *name, umode_t mode,63struct proc_dir_entry *proc_create_net_single(const char *name, umode_t mode,
64 struct proc_dir_entry *parent,64 struct proc_dir_entry *parent,
65 int (*show)(struct seq_file *, void *), void *data);65 int (*show)(struct seq_file *, void *), void *data);
include/linux/pwm.h+1−4
@@ -243,10 +243,7 @@ pwm_set_relative_duty_cycle(struct pwm_state *state, unsigned int duty_cycle, · 242 unmodified lines
243 * @request: optional hook for requesting a PWM243 * @request: optional hook for requesting a PWM
244 * @free: optional hook for freeing a PWM244 * @free: optional hook for freeing a PWM
245 * @capture: capture and report PWM signal245 * @capture: capture and report PWM signal
246 * @apply: atomically apply a new PWM config. The state argument246 * @apply: atomically apply a new PWM config
247 * should be adjusted with the real hardware config (if the
248 * approximate the period or duty_cycle value, state should
249 * reflect it)
250 * @get_state: get the current PWM state. This function is only247 * @get_state: get the current PWM state. This function is only
251 * called once per PWM device when the PWM chip is248 * called once per PWM device when the PWM chip is
252 * registered.249 * registered.
include/linux/qcom_scm.h+26−0
@@ -24,6 +24,26 @@ struct qcom_scm_vmperm { · 23 unmodified lines
24 int perm;24 int perm;
25};25};
26 26
27enum qcom_scm_ocmem_client {
28 QCOM_SCM_OCMEM_UNUSED_ID = 0x0,
29 QCOM_SCM_OCMEM_GRAPHICS_ID,
30 QCOM_SCM_OCMEM_VIDEO_ID,
31 QCOM_SCM_OCMEM_LP_AUDIO_ID,
32 QCOM_SCM_OCMEM_SENSORS_ID,
33 QCOM_SCM_OCMEM_OTHER_OS_ID,
34 QCOM_SCM_OCMEM_DEBUG_ID,
35};
36
37enum qcom_scm_sec_dev_id {
38 QCOM_SCM_MDSS_DEV_ID = 1,
39 QCOM_SCM_OCMEM_DEV_ID = 5,
40 QCOM_SCM_PCIE0_DEV_ID = 11,
41 QCOM_SCM_PCIE1_DEV_ID = 12,
42 QCOM_SCM_GFX_DEV_ID = 18,
43 QCOM_SCM_UFS_DEV_ID = 19,
44 QCOM_SCM_ICE_DEV_ID = 20,
45};
46
27#define QCOM_SCM_VMID_HLOS 0x347#define QCOM_SCM_VMID_HLOS 0x3
28#define QCOM_SCM_VMID_MSS_MSA 0xF48#define QCOM_SCM_VMID_MSS_MSA 0xF
29#define QCOM_SCM_VMID_WLAN 0x1849#define QCOM_SCM_VMID_WLAN 0x18
@@ -41,6 +61,11 @@ extern bool qcom_scm_is_available(void); · 11 unmodified lines
41extern bool qcom_scm_hdcp_available(void);61extern bool qcom_scm_hdcp_available(void);
42extern int qcom_scm_hdcp_req(struct qcom_scm_hdcp_req *req, u32 req_cnt,62extern int qcom_scm_hdcp_req(struct qcom_scm_hdcp_req *req, u32 req_cnt,
43 u32 *resp);63 u32 *resp);
64extern bool qcom_scm_ocmem_lock_available(void);
65extern int qcom_scm_ocmem_lock(enum qcom_scm_ocmem_client id, u32 offset,
66 u32 size, u32 mode);
67extern int qcom_scm_ocmem_unlock(enum qcom_scm_ocmem_client id, u32 offset,
68 u32 size);
44extern bool qcom_scm_pas_supported(u32 peripheral);69extern bool qcom_scm_pas_supported(u32 peripheral);
45extern int qcom_scm_pas_init_image(u32 peripheral, const void *metadata,70extern int qcom_scm_pas_init_image(u32 peripheral, const void *metadata,
46 size_t size);71 size_t size);
@@ -55,6 +80,7 @@ extern int qcom_scm_assign_mem(phys_addr_t mem_addr, size_t mem_sz, · 8 unmodified lines
55extern void qcom_scm_cpu_power_down(u32 flags);80extern void qcom_scm_cpu_power_down(u32 flags);
56extern u32 qcom_scm_get_version(void);81extern u32 qcom_scm_get_version(void);
57extern int qcom_scm_set_remote_state(u32 state, u32 id);82extern int qcom_scm_set_remote_state(u32 state, u32 id);
83extern bool qcom_scm_restore_sec_cfg_available(void);
58extern int qcom_scm_restore_sec_cfg(u32 device_id, u32 spare);84extern int qcom_scm_restore_sec_cfg(u32 device_id, u32 spare);
59extern int qcom_scm_iommu_secure_ptbl_size(u32 spare, size_t *size);85extern int qcom_scm_iommu_secure_ptbl_size(u32 spare, size_t *size);
60extern int qcom_scm_iommu_secure_ptbl_init(u64 addr, u32 size, u32 spare);86extern int qcom_scm_iommu_secure_ptbl_init(u64 addr, u32 size, u32 spare);
include/linux/rbtree_augmented.h+2−4
@@ -283,14 +283,12 @@ __rb_erase_augmented(struct rb_node *node, struct rb_root *root, · 282 unmodified lines
283 __rb_change_child(node, successor, tmp, root);283 __rb_change_child(node, successor, tmp, root);
284 284
285 if (child2) {285 if (child2) {
286 successor->__rb_parent_color = pc;
287 rb_set_parent_color(child2, parent, RB_BLACK);286 rb_set_parent_color(child2, parent, RB_BLACK);
288 rebalance = NULL;287 rebalance = NULL;
289 } else {288 } else {
290 unsigned long pc2 = successor->__rb_parent_color;289 rebalance = rb_is_black(successor) ? parent : NULL;
291 successor->__rb_parent_color = pc;
292 rebalance = __rb_is_black(pc2) ? parent : NULL;
293 }290 }
291 successor->__rb_parent_color = pc;
294 tmp = successor;292 tmp = successor;
295 }293 }
296 294
include/linux/rculist_nulls.h+37−0
@@ -100,6 +100,43 @@ static inline void hlist_nulls_add_head_rcu(struct hlist_nulls_node *n, · 99 unmodified lines
100 first->pprev = &n->next;100 first->pprev = &n->next;
101}101}
102 102
103/**
104 * hlist_nulls_add_tail_rcu
105 * @n: the element to add to the hash list.
106 * @h: the list to add to.
107 *
108 * Description:
109 * Adds the specified element to the specified hlist_nulls,
110 * while permitting racing traversals.
111 *
112 * The caller must take whatever precautions are necessary
113 * (such as holding appropriate locks) to avoid racing
114 * with another list-mutation primitive, such as hlist_nulls_add_head_rcu()
115 * or hlist_nulls_del_rcu(), running on this same list.
116 * However, it is perfectly legal to run concurrently with
117 * the _rcu list-traversal primitives, such as
118 * hlist_nulls_for_each_entry_rcu(), used to prevent memory-consistency
119 * problems on Alpha CPUs. Regardless of the type of CPU, the
120 * list-traversal primitive must be guarded by rcu_read_lock().
121 */
122static inline void hlist_nulls_add_tail_rcu(struct hlist_nulls_node *n,
123 struct hlist_nulls_head *h)
124{
125 struct hlist_nulls_node *i, *last = NULL;
126
127 /* Note: write side code, so rcu accessors are not needed. */
128 for (i = h->first; !is_a_nulls(i); i = i->next)
129 last = i;
130
131 if (last) {
132 n->next = last->next;
133 n->pprev = &last->next;
134 rcu_assign_pointer(hlist_next_rcu(last), n);
135 } else {
136 hlist_nulls_add_head_rcu(n, h);
137 }
138}
139
103/**140/**
104 * hlist_nulls_for_each_entry_rcu - iterate over rcu list of given type141 * hlist_nulls_for_each_entry_rcu - iterate over rcu list of given type
105 * @tpos: the type * to use as a loop cursor.142 * @tpos: the type * to use as a loop cursor.
include/linux/reset-controller.h+2−1
@@ -62,7 +62,8 @@ struct reset_control_lookup { · 61 unmodified lines
62 * @of_node: corresponding device tree node as phandle target62 * @of_node: corresponding device tree node as phandle target
63 * @of_reset_n_cells: number of cells in reset line specifiers63 * @of_reset_n_cells: number of cells in reset line specifiers
64 * @of_xlate: translation function to translate from specifier as found in the64 * @of_xlate: translation function to translate from specifier as found in the
65 * device tree to id as given to the reset control ops65 * device tree to id as given to the reset control ops, defaults
66 * to :c:func:`of_reset_simple_xlate`.
66 * @nr_resets: number of reset controls in this reset controller device67 * @nr_resets: number of reset controls in this reset controller device
67 */68 */
68struct reset_controller_dev {69struct reset_controller_dev {
include/linux/reset.h+46−0
@@ -203,12 +203,34 @@ static inline struct reset_control *reset_control_get_shared( · 202 unmodified lines
203 return __reset_control_get(dev, id, 0, true, false, false);203 return __reset_control_get(dev, id, 0, true, false, false);
204}204}
205 205
206/**
207 * reset_control_get_optional_exclusive - optional reset_control_get_exclusive()
208 * @dev: device to be reset by the controller
209 * @id: reset line name
210 *
211 * Optional variant of reset_control_get_exclusive(). If the requested reset
212 * is not specified in the device tree, this function returns NULL instead of
213 * an error.
214 *
215 * See reset_control_get_exclusive() for more information.
216 */
206static inline struct reset_control *reset_control_get_optional_exclusive(217static inline struct reset_control *reset_control_get_optional_exclusive(
207 struct device *dev, const char *id)218 struct device *dev, const char *id)
208{219{
209 return __reset_control_get(dev, id, 0, false, true, true);220 return __reset_control_get(dev, id, 0, false, true, true);
210}221}
211 222
223/**
224 * reset_control_get_optional_shared - optional reset_control_get_shared()
225 * @dev: device to be reset by the controller
226 * @id: reset line name
227 *
228 * Optional variant of reset_control_get_shared(). If the requested reset
229 * is not specified in the device tree, this function returns NULL instead of
230 * an error.
231 *
232 * See reset_control_get_shared() for more information.
233 */
212static inline struct reset_control *reset_control_get_optional_shared(234static inline struct reset_control *reset_control_get_optional_shared(
213 struct device *dev, const char *id)235 struct device *dev, const char *id)
214{236{
@@ -354,12 +376,36 @@ static inline struct reset_control *devm_reset_control_get_shared( · 139 unmodified lines
354 return __devm_reset_control_get(dev, id, 0, true, false, false);376 return __devm_reset_control_get(dev, id, 0, true, false, false);
355}377}
356 378
379/**
380 * devm_reset_control_get_optional_exclusive - resource managed
381 * reset_control_get_optional_exclusive()
382 * @dev: device to be reset by the controller
383 * @id: reset line name
384 *
385 * Managed reset_control_get_optional_exclusive(). For reset controllers
386 * returned from this function, reset_control_put() is called automatically on
387 * driver detach.
388 *
389 * See reset_control_get_optional_exclusive() for more information.
390 */
357static inline struct reset_control *devm_reset_control_get_optional_exclusive(391static inline struct reset_control *devm_reset_control_get_optional_exclusive(
358 struct device *dev, const char *id)392 struct device *dev, const char *id)
359{393{
360 return __devm_reset_control_get(dev, id, 0, false, true, true);394 return __devm_reset_control_get(dev, id, 0, false, true, true);
361}395}
362 396
397/**
398 * devm_reset_control_get_optional_shared - resource managed
399 * reset_control_get_optional_shared()
400 * @dev: device to be reset by the controller
401 * @id: reset line name
402 *
403 * Managed reset_control_get_optional_shared(). For reset controllers returned
404 * from this function, reset_control_put() is called automatically on driver
405 * detach.
406 *
407 * See reset_control_get_optional_shared() for more information.
408 */
363static inline struct reset_control *devm_reset_control_get_optional_shared(409static inline struct reset_control *devm_reset_control_get_optional_shared(
364 struct device *dev, const char *id)410 struct device *dev, const char *id)
365{411{
include/linux/sched.h+8−0
@@ -1210,6 +1210,8 @@ struct task_struct { · 1209 unmodified lines
1210#endif /* CONFIG_TRACING */1210#endif /* CONFIG_TRACING */
1211 1211
1212#ifdef CONFIG_KCOV1212#ifdef CONFIG_KCOV
1213 /* See kernel/kcov.c for more details. */
1214
1213 /* Coverage collection mode enabled for this task (0 if disabled): */1215 /* Coverage collection mode enabled for this task (0 if disabled): */
1214 unsigned int kcov_mode;1216 unsigned int kcov_mode;
1215 1217
@@ -1221,6 +1223,12 @@ struct task_struct { · 5 unmodified lines
1221 1223
1222 /* KCOV descriptor wired with this task or NULL: */1224 /* KCOV descriptor wired with this task or NULL: */
1223 struct kcov *kcov;1225 struct kcov *kcov;
1226
1227 /* KCOV common handle for remote coverage collection: */
1228 u64 kcov_handle;
1229
1230 /* KCOV sequence number: */
1231 int kcov_sequence;
1224#endif1232#endif
1225 1233
1226#ifdef CONFIG_MEMCG1234#ifdef CONFIG_MEMCG
include/linux/sched/cpufreq.h+3−0
@@ -12,6 +12,8 @@ · 11 unmodified lines
12#define SCHED_CPUFREQ_MIGRATION (1U << 1)12#define SCHED_CPUFREQ_MIGRATION (1U << 1)
13 13
14#ifdef CONFIG_CPU_FREQ14#ifdef CONFIG_CPU_FREQ
15struct cpufreq_policy;
16
15struct update_util_data {17struct update_util_data {
16 void (*func)(struct update_util_data *data, u64 time, unsigned int flags);18 void (*func)(struct update_util_data *data, u64 time, unsigned int flags);
17};19};
@@ -20,6 +22,7 @@ void cpufreq_add_update_util_hook(int cpu, struct update_util_data *data, · 2 unmodified lines
20 void (*func)(struct update_util_data *data, u64 time,22 void (*func)(struct update_util_data *data, u64 time,
21 unsigned int flags));23 unsigned int flags));
22void cpufreq_remove_update_util_hook(int cpu);24void cpufreq_remove_update_util_hook(int cpu);
25bool cpufreq_this_cpu_can_update(struct cpufreq_policy *policy);
23 26
24static inline unsigned long map_util_freq(unsigned long util,27static inline unsigned long map_util_freq(unsigned long util,
25 unsigned long freq, unsigned long cap)28 unsigned long freq, unsigned long cap)
include/linux/skbuff.h+3−2
@@ -3529,8 +3529,9 @@ int __skb_vlan_pop(struct sk_buff *skb, u16 *vlan_tci); · 3528 unmodified lines
3529int skb_vlan_pop(struct sk_buff *skb);3529int skb_vlan_pop(struct sk_buff *skb);
3530int skb_vlan_push(struct sk_buff *skb, __be16 vlan_proto, u16 vlan_tci);3530int skb_vlan_push(struct sk_buff *skb, __be16 vlan_proto, u16 vlan_tci);
3531int skb_mpls_push(struct sk_buff *skb, __be32 mpls_lse, __be16 mpls_proto,3531int skb_mpls_push(struct sk_buff *skb, __be32 mpls_lse, __be16 mpls_proto,
3532 int mac_len);3532 int mac_len, bool ethernet);
3533int skb_mpls_pop(struct sk_buff *skb, __be16 next_proto, int mac_len);3533int skb_mpls_pop(struct sk_buff *skb, __be16 next_proto, int mac_len,
3534 bool ethernet);
3534int skb_mpls_update_lse(struct sk_buff *skb, __be32 mpls_lse);3535int skb_mpls_update_lse(struct sk_buff *skb, __be32 mpls_lse);
3535int skb_mpls_dec_ttl(struct sk_buff *skb);3536int skb_mpls_dec_ttl(struct sk_buff *skb);
3536struct sk_buff *pskb_extract(struct sk_buff *skb, int off, int to_copy,3537struct sk_buff *pskb_extract(struct sk_buff *skb, int off, int to_copy,
include/linux/soc/mmp/cputype.h+87−0
@@ -0,0 +1,87 @@
1/* SPDX-License-Identifier: GPL-2.0 */
2#ifndef __ASM_MACH_CPUTYPE_H
3#define __ASM_MACH_CPUTYPE_H
4
5#if defined(CONFIG_ARM) || defined(CONFIG_ARM64)
6#include <asm/cputype.h>
7#endif
8
9/*
10 * CPU Stepping CPU_ID CHIP_ID
11 *
12 * PXA168 S0 0x56158400 0x0000C910
13 * PXA168 A0 0x56158400 0x00A0A168
14 * PXA910 Y1 0x56158400 0x00F2C920
15 * PXA910 A0 0x56158400 0x00F2C910
16 * PXA910 A1 0x56158400 0x00A0C910
17 * PXA920 Y0 0x56158400 0x00F2C920
18 * PXA920 A0 0x56158400 0x00A0C920
19 * PXA920 A1 0x56158400 0x00A1C920
20 * MMP2 Z0 0x560f5811 0x00F00410
21 * MMP2 Z1 0x560f5811 0x00E00410
22 * MMP2 A0 0x560f5811 0x00A0A610
23 * MMP3 A0 0x562f5842 0x00A02128
24 * MMP3 B0 0x562f5842 0x00B02128
25 */
26
27extern unsigned int mmp_chip_id;
28
29#ifdef CONFIG_CPU_PXA168
30static inline int cpu_is_pxa168(void)
31{
32 return (((read_cpuid_id() >> 8) & 0xff) == 0x84) &&
33 ((mmp_chip_id & 0xfff) == 0x168);
34}
35#else
36#define cpu_is_pxa168() (0)
37#endif
38
39/* cpu_is_pxa910() is shared on both pxa910 and pxa920 */
40#ifdef CONFIG_CPU_PXA910
41static inline int cpu_is_pxa910(void)
42{
43 return (((read_cpuid_id() >> 8) & 0xff) == 0x84) &&
44 (((mmp_chip_id & 0xfff) == 0x910) ||
45 ((mmp_chip_id & 0xfff) == 0x920));
46}
47#else
48#define cpu_is_pxa910() (0)
49#endif
50
51#if defined(CONFIG_CPU_MMP2) || defined(CONFIG_MACH_MMP2_DT)
52static inline int cpu_is_mmp2(void)
53{
54 return (((read_cpuid_id() >> 8) & 0xff) == 0x58) &&
55 (((mmp_chip_id & 0xfff) == 0x410) ||
56 ((mmp_chip_id & 0xfff) == 0x610));
57}
58#else
59#define cpu_is_mmp2() (0)
60#endif
61
62#ifdef CONFIG_MACH_MMP3_DT
63static inline int cpu_is_mmp3(void)
64{
65 return (((read_cpuid_id() >> 8) & 0xff) == 0x58) &&
66 ((mmp_chip_id & 0xffff) == 0x2128);
67}
68
69static inline int cpu_is_mmp3_a0(void)
70{
71 return (cpu_is_mmp3() &&
72 ((mmp_chip_id & 0x00ff0000) == 0x00a00000));
73}
74
75static inline int cpu_is_mmp3_b0(void)
76{
77 return (cpu_is_mmp3() &&
78 ((mmp_chip_id & 0x00ff0000) == 0x00b00000));
79}
80
81#else
82#define cpu_is_mmp3() (0)
83#define cpu_is_mmp3_a0() (0)
84#define cpu_is_mmp3_b0() (0)
85#endif
86
87#endif /* __ASM_MACH_CPUTYPE_H */
include/linux/soc/qcom/llcc-qcom.h+20−74
@@ -38,33 +38,27 @@ struct llcc_slice_desc { · 37 unmodified lines
38};38};
39 39
40/**40/**
41 * llcc_slice_config - Data associated with the llcc slice41 * llcc_edac_reg_data - llcc edac registers data for each error type
42 * @usecase_id: usecase id for which the llcc slice is used42 * @name: Name of the error
43 * @slice_id: llcc slice id assigned to each slice43 * @synd_reg: Syndrome register address
44 * @max_cap: maximum capacity of the llcc slice44 * @count_status_reg: Status register address to read the error count
45 * @priority: priority of the llcc slice45 * @ways_status_reg: Status register address to read the error ways
46 * @fixed_size: whether the llcc slice can grow beyond its size46 * @reg_cnt: Number of registers
47 * @bonus_ways: bonus ways associated with llcc slice47 * @count_mask: Mask value to get the error count
48 * @res_ways: reserved ways associated with llcc slice48 * @ways_mask: Mask value to get the error ways
49 * @cache_mode: mode of the llcc slice49 * @count_shift: Shift value to get the error count
50 * @probe_target_ways: Probe only reserved and bonus ways on a cache miss50 * @ways_shift: Shift value to get the error ways
51 * @dis_cap_alloc: Disable capacity based allocation
52 * @retain_on_pc: Retain through power collapse
53 * @activate_on_init: activate the slice on init
54 */51 */
55struct llcc_slice_config {52struct llcc_edac_reg_data {
56 u32 usecase_id;53 char *name;
57 u32 slice_id;54 u64 synd_reg;
58 u32 max_cap;55 u64 count_status_reg;
59 u32 priority;56 u64 ways_status_reg;
60 bool fixed_size;57 u32 reg_cnt;
61 u32 bonus_ways;58 u32 count_mask;
62 u32 res_ways;59 u32 ways_mask;
63 u32 cache_mode;60 u8 count_shift;
64 u32 probe_target_ways;61 u8 ways_shift;
65 bool dis_cap_alloc;
66 bool retain_on_pc;
67 bool activate_on_init;
68};62};
69 63
70/**64/**
@@ -93,30 +87,6 @@ struct llcc_drv_data { · 22 unmodified lines
93 int ecc_irq;87 int ecc_irq;
94};88};
95 89
96/**
97 * llcc_edac_reg_data - llcc edac registers data for each error type
98 * @name: Name of the error
99 * @synd_reg: Syndrome register address
100 * @count_status_reg: Status register address to read the error count
101 * @ways_status_reg: Status register address to read the error ways
102 * @reg_cnt: Number of registers
103 * @count_mask: Mask value to get the error count
104 * @ways_mask: Mask value to get the error ways
105 * @count_shift: Shift value to get the error count
106 * @ways_shift: Shift value to get the error ways
107 */
108struct llcc_edac_reg_data {
109 char *name;
110 u64 synd_reg;
111 u64 count_status_reg;
112 u64 ways_status_reg;
113 u32 reg_cnt;
114 u32 count_mask;
115 u32 ways_mask;
116 u8 count_shift;
117 u8 ways_shift;
118};
119
120#if IS_ENABLED(CONFIG_QCOM_LLCC)90#if IS_ENABLED(CONFIG_QCOM_LLCC)
121/**91/**
122 * llcc_slice_getd - get llcc slice descriptor92 * llcc_slice_getd - get llcc slice descriptor
@@ -154,20 +124,6 @@ int llcc_slice_activate(struct llcc_slice_desc *desc); · 31 unmodified lines
154 */124 */
155int llcc_slice_deactivate(struct llcc_slice_desc *desc);125int llcc_slice_deactivate(struct llcc_slice_desc *desc);
156 126
157/**
158 * qcom_llcc_probe - program the sct table
159 * @pdev: platform device pointer
160 * @table: soc sct table
161 * @sz: Size of the config table
162 */
163int qcom_llcc_probe(struct platform_device *pdev,
164 const struct llcc_slice_config *table, u32 sz);
165
166/**
167 * qcom_llcc_remove - remove the sct table
168 * @pdev: Platform device pointer
169 */
170int qcom_llcc_remove(struct platform_device *pdev);
171#else127#else
172static inline struct llcc_slice_desc *llcc_slice_getd(u32 uid)128static inline struct llcc_slice_desc *llcc_slice_getd(u32 uid)
173{129{
@@ -197,16 +153,6 @@ static inline int llcc_slice_deactivate(struct llcc_slice_desc *desc) · 23 unmodified lines
197{153{
198 return -EINVAL;154 return -EINVAL;
199}155}
200static inline int qcom_llcc_probe(struct platform_device *pdev,
201 const struct llcc_slice_config *table, u32 sz)
202{
203 return -ENODEV;
204}
205
206static inline int qcom_llcc_remove(struct platform_device *pdev)
207{
208 return -ENODEV;
209}
210#endif156#endif
211 157
212#endif158#endif
include/linux/socket.h+13−7
@@ -378,12 +378,19 @@ extern int __sys_recvmmsg(int fd, struct mmsghdr __user *mmsg, · 377 unmodified lines
378extern int __sys_sendmmsg(int fd, struct mmsghdr __user *mmsg,378extern int __sys_sendmmsg(int fd, struct mmsghdr __user *mmsg,
379 unsigned int vlen, unsigned int flags,379 unsigned int vlen, unsigned int flags,
380 bool forbid_cmsg_compat);380 bool forbid_cmsg_compat);
381extern long __sys_sendmsg_sock(struct socket *sock,381extern long __sys_sendmsg_sock(struct socket *sock, struct msghdr *msg,
382 struct user_msghdr __user *msg,
383 unsigned int flags);382 unsigned int flags);
384extern long __sys_recvmsg_sock(struct socket *sock,383extern long __sys_recvmsg_sock(struct socket *sock, struct msghdr *msg,
385 struct user_msghdr __user *msg,384 struct user_msghdr __user *umsg,
385 struct sockaddr __user *uaddr,
386 unsigned int flags);386 unsigned int flags);
387extern int sendmsg_copy_msghdr(struct msghdr *msg,
388 struct user_msghdr __user *umsg, unsigned flags,
389 struct iovec **iov);
390extern int recvmsg_copy_msghdr(struct msghdr *msg,
391 struct user_msghdr __user *umsg, unsigned flags,
392 struct sockaddr __user **uaddr,
393 struct iovec **iov);
387 394
388/* helpers which do the actual work for syscalls */395/* helpers which do the actual work for syscalls */
389extern int __sys_recvfrom(int fd, void __user *ubuf, size_t size,396extern int __sys_recvfrom(int fd, void __user *ubuf, size_t size,
@@ -399,9 +406,8 @@ extern int __sys_accept4(int fd, struct sockaddr __user *upeer_sockaddr, · 9 unmodified lines
399 int __user *upeer_addrlen, int flags);406 int __user *upeer_addrlen, int flags);
400extern int __sys_socket(int family, int type, int protocol);407extern int __sys_socket(int family, int type, int protocol);
401extern int __sys_bind(int fd, struct sockaddr __user *umyaddr, int addrlen);408extern int __sys_bind(int fd, struct sockaddr __user *umyaddr, int addrlen);
402extern int __sys_connect_file(struct file *file,409extern int __sys_connect_file(struct file *file, struct sockaddr_storage *addr,
403 struct sockaddr __user *uservaddr, int addrlen,410 int addrlen, int file_flags);
404 int file_flags);
405extern int __sys_connect(int fd, struct sockaddr __user *uservaddr,411extern int __sys_connect(int fd, struct sockaddr __user *uservaddr,
406 int addrlen);412 int addrlen);
407extern int __sys_listen(int fd, int backlog);413extern int __sys_listen(int fd, int backlog);
include/linux/sunrpc/auth.h+0−3
@@ -10,8 +10,6 @@ · 9 unmodified lines
10#ifndef _LINUX_SUNRPC_AUTH_H10#ifndef _LINUX_SUNRPC_AUTH_H
11#define _LINUX_SUNRPC_AUTH_H11#define _LINUX_SUNRPC_AUTH_H
12 12
13#ifdef __KERNEL__
14
15#include <linux/sunrpc/sched.h>13#include <linux/sunrpc/sched.h>
16#include <linux/sunrpc/msg_prot.h>14#include <linux/sunrpc/msg_prot.h>
17#include <linux/sunrpc/xdr.h>15#include <linux/sunrpc/xdr.h>
@@ -194,5 +192,4 @@ struct rpc_cred *get_rpccred(struct rpc_cred *cred) · 176 unmodified lines
194 return NULL;192 return NULL;
195}193}
196 194
197#endif /* __KERNEL__ */
198#endif /* _LINUX_SUNRPC_AUTH_H */195#endif /* _LINUX_SUNRPC_AUTH_H */
include/linux/sunrpc/auth_gss.h+0−2
@@ -13,7 +13,6 @@ · 12 unmodified lines
13#ifndef _LINUX_SUNRPC_AUTH_GSS_H13#ifndef _LINUX_SUNRPC_AUTH_GSS_H
14#define _LINUX_SUNRPC_AUTH_GSS_H14#define _LINUX_SUNRPC_AUTH_GSS_H
15 15
16#ifdef __KERNEL__
17#include <linux/refcount.h>16#include <linux/refcount.h>
18#include <linux/sunrpc/auth.h>17#include <linux/sunrpc/auth.h>
19#include <linux/sunrpc/svc.h>18#include <linux/sunrpc/svc.h>
@@ -90,6 +89,5 @@ struct gss_cred { · 70 unmodified lines
90 unsigned long gc_upcall_timestamp;89 unsigned long gc_upcall_timestamp;
91};90};
92 91
93#endif /* __KERNEL__ */
94#endif /* _LINUX_SUNRPC_AUTH_GSS_H */92#endif /* _LINUX_SUNRPC_AUTH_GSS_H */
95 93
include/linux/sunrpc/clnt.h+1−3
@@ -109,8 +109,6 @@ struct rpc_procinfo { · 108 unmodified lines
109 const char * p_name; /* name of procedure */109 const char * p_name; /* name of procedure */
110};110};
111 111
112#ifdef __KERNEL__
113
114struct rpc_create_args {112struct rpc_create_args {
115 struct net *net;113 struct net *net;
116 int protocol;114 int protocol;
@@ -149,6 +147,7 @@ struct rpc_add_xprt_test { · 32 unmodified lines
149#define RPC_CLNT_CREATE_NO_IDLE_TIMEOUT (1UL << 8)147#define RPC_CLNT_CREATE_NO_IDLE_TIMEOUT (1UL << 8)
150#define RPC_CLNT_CREATE_NO_RETRANS_TIMEOUT (1UL << 9)148#define RPC_CLNT_CREATE_NO_RETRANS_TIMEOUT (1UL << 9)
151#define RPC_CLNT_CREATE_SOFTERR (1UL << 10)149#define RPC_CLNT_CREATE_SOFTERR (1UL << 10)
150#define RPC_CLNT_CREATE_REUSEPORT (1UL << 11)
152 151
153struct rpc_clnt *rpc_create(struct rpc_create_args *args);152struct rpc_clnt *rpc_create(struct rpc_create_args *args);
154struct rpc_clnt *rpc_bind_new_program(struct rpc_clnt *,153struct rpc_clnt *rpc_bind_new_program(struct rpc_clnt *,
@@ -237,5 +236,4 @@ static inline int rpc_reply_expected(struct rpc_task *task) · 82 unmodified lines
237 (task->tk_msg.rpc_proc->p_decode != NULL);236 (task->tk_msg.rpc_proc->p_decode != NULL);
238}237}
239 238
240#endif /* __KERNEL__ */
241#endif /* _LINUX_SUNRPC_CLNT_H */239#endif /* _LINUX_SUNRPC_CLNT_H */
include/linux/sunrpc/gss_api.h+0−2
@@ -13,7 +13,6 @@ · 12 unmodified lines
13#ifndef _LINUX_SUNRPC_GSS_API_H13#ifndef _LINUX_SUNRPC_GSS_API_H
14#define _LINUX_SUNRPC_GSS_API_H14#define _LINUX_SUNRPC_GSS_API_H
15 15
16#ifdef __KERNEL__
17#include <linux/sunrpc/xdr.h>16#include <linux/sunrpc/xdr.h>
18#include <linux/sunrpc/msg_prot.h>17#include <linux/sunrpc/msg_prot.h>
19#include <linux/uio.h>18#include <linux/uio.h>
@@ -160,6 +159,5 @@ struct gss_api_mech * gss_mech_get(struct gss_api_mech *); · 140 unmodified lines
160 * corresponding call to gss_mech_put. */159 * corresponding call to gss_mech_put. */
161void gss_mech_put(struct gss_api_mech *);160void gss_mech_put(struct gss_api_mech *);
162 161
163#endif /* __KERNEL__ */
164#endif /* _LINUX_SUNRPC_GSS_API_H */162#endif /* _LINUX_SUNRPC_GSS_API_H */
165 163
include/linux/sunrpc/gss_err.h+0−3
@@ -34,8 +34,6 @@ · 33 unmodified lines
34#ifndef _LINUX_SUNRPC_GSS_ERR_H34#ifndef _LINUX_SUNRPC_GSS_ERR_H
35#define _LINUX_SUNRPC_GSS_ERR_H35#define _LINUX_SUNRPC_GSS_ERR_H
36 36
37#ifdef __KERNEL__
38
39typedef unsigned int OM_uint32;37typedef unsigned int OM_uint32;
40 38
41/*39/*
@@ -163,5 +161,4 @@ typedef unsigned int OM_uint32; · 121 unmodified lines
163/* XXXX This is a necessary evil until the spec is fixed */161/* XXXX This is a necessary evil until the spec is fixed */
164#define GSS_S_CRED_UNAVAIL GSS_S_FAILURE162#define GSS_S_CRED_UNAVAIL GSS_S_FAILURE
165 163
166#endif /* __KERNEL__ */
167#endif /* __LINUX_SUNRPC_GSS_ERR_H */164#endif /* __LINUX_SUNRPC_GSS_ERR_H */
include/linux/sunrpc/msg_prot.h+0−3
@@ -8,8 +8,6 @@ · 7 unmodified lines
8#ifndef _LINUX_SUNRPC_MSGPROT_H_8#ifndef _LINUX_SUNRPC_MSGPROT_H_
9#define _LINUX_SUNRPC_MSGPROT_H_9#define _LINUX_SUNRPC_MSGPROT_H_
10 10
11#ifdef __KERNEL__ /* user programs should get these from the rpc header files */
12
13#define RPC_VERSION 211#define RPC_VERSION 2
14 12
15/* size of an XDR encoding unit in bytes, i.e. 32bit */13/* size of an XDR encoding unit in bytes, i.e. 32bit */
@@ -217,5 +215,4 @@ typedef __be32 rpc_fraghdr; · 201 unmodified lines
217/* Assume INET6_ADDRSTRLEN will always be larger than INET_ADDRSTRLEN... */215/* Assume INET6_ADDRSTRLEN will always be larger than INET_ADDRSTRLEN... */
218#define RPCBIND_MAXUADDRLEN RPCBIND_MAXUADDR6LEN216#define RPCBIND_MAXUADDRLEN RPCBIND_MAXUADDR6LEN
219 217
220#endif /* __KERNEL__ */
221#endif /* _LINUX_SUNRPC_MSGPROT_H_ */218#endif /* _LINUX_SUNRPC_MSGPROT_H_ */
include/linux/sunrpc/rpc_pipe_fs.h+0−3
@@ -2,8 +2,6 @@ · 1 unmodified line
2#ifndef _LINUX_SUNRPC_RPC_PIPE_FS_H2#ifndef _LINUX_SUNRPC_RPC_PIPE_FS_H
3#define _LINUX_SUNRPC_RPC_PIPE_FS_H3#define _LINUX_SUNRPC_RPC_PIPE_FS_H
4 4
5#ifdef __KERNEL__
6
7#include <linux/workqueue.h>5#include <linux/workqueue.h>
8 6
9struct rpc_pipe_dir_head {7struct rpc_pipe_dir_head {
@@ -133,4 +131,3 @@ extern void unregister_rpc_pipefs(void); · 123 unmodified lines
133extern bool gssd_running(struct net *net);131extern bool gssd_running(struct net *net);
134 132
135#endif133#endif
136#endif
include/linux/sunrpc/svcauth.h+0−4
@@ -10,8 +10,6 @@ · 9 unmodified lines
10#ifndef _LINUX_SUNRPC_SVCAUTH_H_10#ifndef _LINUX_SUNRPC_SVCAUTH_H_
11#define _LINUX_SUNRPC_SVCAUTH_H_11#define _LINUX_SUNRPC_SVCAUTH_H_
12 12
13#ifdef __KERNEL__
14
15#include <linux/string.h>13#include <linux/string.h>
16#include <linux/sunrpc/msg_prot.h>14#include <linux/sunrpc/msg_prot.h>
17#include <linux/sunrpc/cache.h>15#include <linux/sunrpc/cache.h>
@@ -185,6 +183,4 @@ static inline unsigned long hash_mem(char const *buf, int length, int bits) · 167 unmodified lines
185 return full_name_hash(NULL, buf, length) >> (32 - bits);183 return full_name_hash(NULL, buf, length) >> (32 - bits);
186}184}
187 185
188#endif /* __KERNEL__ */
189
190#endif /* _LINUX_SUNRPC_SVCAUTH_H_ */186#endif /* _LINUX_SUNRPC_SVCAUTH_H_ */
include/linux/sunrpc/svcauth_gss.h+0−2
@@ -9,7 +9,6 @@ · 8 unmodified lines
9#ifndef _LINUX_SUNRPC_SVCAUTH_GSS_H9#ifndef _LINUX_SUNRPC_SVCAUTH_GSS_H
10#define _LINUX_SUNRPC_SVCAUTH_GSS_H10#define _LINUX_SUNRPC_SVCAUTH_GSS_H
11 11
12#ifdef __KERNEL__
13#include <linux/sched.h>12#include <linux/sched.h>
14#include <linux/sunrpc/types.h>13#include <linux/sunrpc/types.h>
15#include <linux/sunrpc/xdr.h>14#include <linux/sunrpc/xdr.h>
@@ -24,5 +23,4 @@ void gss_svc_shutdown_net(struct net *net); · 8 unmodified lines
24int svcauth_gss_register_pseudoflavor(u32 pseudoflavor, char * name);23int svcauth_gss_register_pseudoflavor(u32 pseudoflavor, char * name);
25u32 svcauth_gss_flavor(struct auth_domain *dom);24u32 svcauth_gss_flavor(struct auth_domain *dom);
26 25
27#endif /* __KERNEL__ */
28#endif /* _LINUX_SUNRPC_SVCAUTH_GSS_H */26#endif /* _LINUX_SUNRPC_SVCAUTH_GSS_H */
include/linux/sunrpc/xdr.h+0−3
@@ -11,8 +11,6 @@ · 10 unmodified lines
11#ifndef _SUNRPC_XDR_H_11#ifndef _SUNRPC_XDR_H_
12#define _SUNRPC_XDR_H_12#define _SUNRPC_XDR_H_
13 13
14#ifdef __KERNEL__
15
16#include <linux/uio.h>14#include <linux/uio.h>
17#include <asm/byteorder.h>15#include <asm/byteorder.h>
18#include <asm/unaligned.h>16#include <asm/unaligned.h>
@@ -552,6 +550,5 @@ xdr_stream_decode_uint32_array(struct xdr_stream *xdr, · 533 unmodified lines
552 *array = be32_to_cpup(p);550 *array = be32_to_cpup(p);
553 return retval;551 return retval;
554}552}
555#endif /* __KERNEL__ */
556 553
557#endif /* _SUNRPC_XDR_H_ */554#endif /* _SUNRPC_XDR_H_ */
include/linux/sunrpc/xprt.h+2−5
@@ -19,8 +19,6 @@ · 18 unmodified lines
19#include <linux/sunrpc/xdr.h>19#include <linux/sunrpc/xdr.h>
20#include <linux/sunrpc/msg_prot.h>20#include <linux/sunrpc/msg_prot.h>
21 21
22#ifdef __KERNEL__
23
24#define RPC_MIN_SLOT_TABLE (2U)22#define RPC_MIN_SLOT_TABLE (2U)
25#define RPC_DEF_SLOT_TABLE (16U)23#define RPC_DEF_SLOT_TABLE (16U)
26#define RPC_MAX_SLOT_TABLE_LIMIT (65536U)24#define RPC_MAX_SLOT_TABLE_LIMIT (65536U)
@@ -207,7 +205,8 @@ struct rpc_xprt { · 180 unmodified lines
207 unsigned int min_reqs; /* min number of slots */205 unsigned int min_reqs; /* min number of slots */
208 unsigned int num_reqs; /* total slots */206 unsigned int num_reqs; /* total slots */
209 unsigned long state; /* transport state */207 unsigned long state; /* transport state */
210 unsigned char resvport : 1; /* use a reserved port */208 unsigned char resvport : 1, /* use a reserved port */
209 reuseport : 1; /* reuse port on reconnect */
211 atomic_t swapper; /* we're swapping over this210 atomic_t swapper; /* we're swapping over this
212 transport */211 transport */
213 unsigned int bind_index; /* bind function index */212 unsigned int bind_index; /* bind function index */
@@ -505,6 +504,4 @@ static inline void xprt_inject_disconnect(struct rpc_xprt *xprt) · 291 unmodified lines
505}504}
506#endif505#endif
507 506
508#endif /* __KERNEL__*/
509
510#endif /* _LINUX_SUNRPC_XPRT_H */507#endif /* _LINUX_SUNRPC_XPRT_H */
include/linux/sunrpc/xprtsock.h+0−4
@@ -8,8 +8,6 @@ · 7 unmodified lines
8#ifndef _LINUX_SUNRPC_XPRTSOCK_H8#ifndef _LINUX_SUNRPC_XPRTSOCK_H
9#define _LINUX_SUNRPC_XPRTSOCK_H9#define _LINUX_SUNRPC_XPRTSOCK_H
10 10
11#ifdef __KERNEL__
12
13int init_socket_xprt(void);11int init_socket_xprt(void);
14void cleanup_socket_xprt(void);12void cleanup_socket_xprt(void);
15 13
@@ -91,6 +89,4 @@ struct sock_xprt { · 75 unmodified lines
91#define XPRT_SOCK_WAKE_PENDING (6)89#define XPRT_SOCK_WAKE_PENDING (6)
92#define XPRT_SOCK_WAKE_DISCONNECT (7)90#define XPRT_SOCK_WAKE_DISCONNECT (7)
93 91
94#endif /* __KERNEL__ */
95
96#endif /* _LINUX_SUNRPC_XPRTSOCK_H */92#endif /* _LINUX_SUNRPC_XPRTSOCK_H */
include/linux/syscalls.h+0−3
@@ -1231,10 +1231,7 @@ asmlinkage long sys_ni_syscall(void); · 1230 unmodified lines
1231 * the ksys_xyzyyz() functions prototyped below.1231 * the ksys_xyzyyz() functions prototyped below.
1232 */1232 */
1233 1233
1234int ksys_mount(const char __user *dev_name, const char __user *dir_name,
1235 const char __user *type, unsigned long flags, void __user *data);
1236int ksys_umount(char __user *name, int flags);1234int ksys_umount(char __user *name, int flags);
1237int ksys_dup(unsigned int fildes);
1238int ksys_chroot(const char __user *filename);1235int ksys_chroot(const char __user *filename);
1239ssize_t ksys_write(unsigned int fd, const char __user *buf, size_t count);1236ssize_t ksys_write(unsigned int fd, const char __user *buf, size_t count);
1240int ksys_chdir(const char __user *filename);1237int ksys_chdir(const char __user *filename);
include/linux/sysctl.h+2−4
@@ -120,8 +120,7 @@ static inline void *proc_sys_poll_event(struct ctl_table_poll *poll) · 119 unmodified lines
120 struct ctl_table_poll name = __CTL_TABLE_POLL_INITIALIZER(name)120 struct ctl_table_poll name = __CTL_TABLE_POLL_INITIALIZER(name)
121 121
122/* A sysctl table is an array of struct ctl_table: */122/* A sysctl table is an array of struct ctl_table: */
123struct ctl_table 123struct ctl_table {
124{
125 const char *procname; /* Text ID for /proc/sys, or zero */124 const char *procname; /* Text ID for /proc/sys, or zero */
126 void *data;125 void *data;
127 int maxlen;126 int maxlen;
@@ -140,8 +139,7 @@ struct ctl_node { · 12 unmodified lines
140 139
141/* struct ctl_table_header is used to maintain dynamic lists of140/* struct ctl_table_header is used to maintain dynamic lists of
142 struct ctl_table trees. */141 struct ctl_table trees. */
143struct ctl_table_header142struct ctl_table_header {
144{
145 union {143 union {
146 struct {144 struct {
147 struct ctl_table *ctl_table;145 struct ctl_table *ctl_table;
include/linux/thermal.h+0−11
@@ -544,15 +544,4 @@ static inline void thermal_notify_framework(struct thermal_zone_device *tz, · 543 unmodified lines
544{ }544{ }
545#endif /* CONFIG_THERMAL */545#endif /* CONFIG_THERMAL */
546 546
547#if defined(CONFIG_NET) && IS_ENABLED(CONFIG_THERMAL)
548extern int thermal_generate_netlink_event(struct thermal_zone_device *tz,
549 enum events event);
550#else
551static inline int thermal_generate_netlink_event(struct thermal_zone_device *tz,
552 enum events event)
553{
554 return 0;
555}
556#endif
557
558#endif /* __THERMAL_H__ */547#endif /* __THERMAL_H__ */
include/linux/thread_info.h+2−0
@@ -147,6 +147,8 @@ check_copy_size(const void *addr, size_t bytes, bool is_source) · 146 unmodified lines
147 __bad_copy_to();147 __bad_copy_to();
148 return false;148 return false;
149 }149 }
150 if (WARN_ON_ONCE(bytes > INT_MAX))
151 return false;
150 check_object_size(addr, bytes, is_source);152 check_object_size(addr, bytes, is_source);
151 return true;153 return true;
152}154}
include/linux/time.h+13−0
@@ -97,4 +97,17 @@ static inline bool itimerspec64_valid(const struct itimerspec64 *its) · 96 unmodified lines
97 */97 */
98#define time_after32(a, b) ((s32)((u32)(b) - (u32)(a)) < 0)98#define time_after32(a, b) ((s32)((u32)(b) - (u32)(a)) < 0)
99#define time_before32(b, a) time_after32(a, b)99#define time_before32(b, a) time_after32(a, b)
100
101/**
102 * time_between32 - check if a 32-bit timestamp is within a given time range
103 * @t: the time which may be within [l,h]
104 * @l: the lower bound of the range
105 * @h: the higher bound of the range
106 *
107 * time_before32(t, l, h) returns true if @l <= @t <= @h. All operands are
108 * treated as 32-bit integers.
109 *
110 * Equivalent to !(time_before32(@t, @l) || time_after32(@t, @h)).
111 */
112#define time_between32(t, l, h) ((u32)(h) - (u32)(l) >= (u32)(t) - (u32)(l))
100#endif113#endif
include/linux/tpm.h+1−0
@@ -403,6 +403,7 @@ extern int tpm_pcr_extend(struct tpm_chip *chip, u32 pcr_idx, · 402 unmodified lines
403extern int tpm_send(struct tpm_chip *chip, void *cmd, size_t buflen);403extern int tpm_send(struct tpm_chip *chip, void *cmd, size_t buflen);
404extern int tpm_get_random(struct tpm_chip *chip, u8 *data, size_t max);404extern int tpm_get_random(struct tpm_chip *chip, u8 *data, size_t max);
405extern struct tpm_chip *tpm_default_chip(void);405extern struct tpm_chip *tpm_default_chip(void);
406void tpm2_flush_context(struct tpm_chip *chip, u32 handle);
406#else407#else
407static inline int tpm_is_tpm2(struct tpm_chip *chip)408static inline int tpm_is_tpm2(struct tpm_chip *chip)
408{409{
include/linux/vmstat.h+50−0
@@ -31,6 +31,12 @@ struct reclaim_stat { · 30 unmodified lines
31 unsigned nr_unmap_fail;31 unsigned nr_unmap_fail;
32};32};
33 33
34enum writeback_stat_item {
35 NR_DIRTY_THRESHOLD,
36 NR_DIRTY_BG_THRESHOLD,
37 NR_VM_WRITEBACK_STAT_ITEMS,
38};
39
34#ifdef CONFIG_VM_EVENT_COUNTERS40#ifdef CONFIG_VM_EVENT_COUNTERS
35/*41/*
36 * Light weight per cpu counter implementation.42 * Light weight per cpu counter implementation.
@@ -381,4 +387,48 @@ static inline void __mod_zone_freepage_state(struct zone *zone, int nr_pages, · 344 unmodified lines
381 387
382extern const char * const vmstat_text[];388extern const char * const vmstat_text[];
383 389
390static inline const char *zone_stat_name(enum zone_stat_item item)
391{
392 return vmstat_text[item];
393}
394
395#ifdef CONFIG_NUMA
396static inline const char *numa_stat_name(enum numa_stat_item item)
397{
398 return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
399 item];
400}
401#endif /* CONFIG_NUMA */
402
403static inline const char *node_stat_name(enum node_stat_item item)
404{
405 return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
406 NR_VM_NUMA_STAT_ITEMS +
407 item];
408}
409
410static inline const char *lru_list_name(enum lru_list lru)
411{
412 return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
413}
414
415static inline const char *writeback_stat_name(enum writeback_stat_item item)
416{
417 return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
418 NR_VM_NUMA_STAT_ITEMS +
419 NR_VM_NODE_STAT_ITEMS +
420 item];
421}
422
423#if defined(CONFIG_VM_EVENT_COUNTERS) || defined(CONFIG_MEMCG)
424static inline const char *vm_event_name(enum vm_event_item item)
425{
426 return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
427 NR_VM_NUMA_STAT_ITEMS +
428 NR_VM_NODE_STAT_ITEMS +
429 NR_VM_WRITEBACK_STAT_ITEMS +
430 item];
431}
432#endif /* CONFIG_VM_EVENT_COUNTERS || CONFIG_MEMCG */
433
384#endif /* _LINUX_VMSTAT_H */434#endif /* _LINUX_VMSTAT_H */