linux/drivers
Linus Torvalds d4173023e6 Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace
Pull siginfo cleanups from Eric Biederman:
 "Long ago when 2.4 was just a testing release copy_siginfo_to_user was
  made to copy individual fields to userspace, possibly for efficiency
  and to ensure initialized values were not copied to userspace.

  Unfortunately the design was complex, it's assumptions unstated, and
  humans are fallible and so while it worked much of the time that
  design failed to ensure unitialized memory is not copied to userspace.

  This set of changes is part of a new design to clean up siginfo and
  simplify things, and hopefully make the siginfo handling robust enough
  that a simple inspection of the code can be made to ensure we don't
  copy any unitializied fields to userspace.

  The design is to unify struct siginfo and struct compat_siginfo into a
  single definition that is shared between all architectures so that
  anyone adding to the set of information shared with struct siginfo can
  see the whole picture. Hopefully ensuring all future si_code
  assignments are arch independent.

  The design is to unify copy_siginfo_to_user32 and
  copy_siginfo_from_user32 so that those function are complete and cope
  with all of the different cases documented in signinfo_layout. I don't
  think there was a single implementation of either of those functions
  that was complete and correct before my changes unified them.

  The design is to introduce a series of helpers including
  force_siginfo_fault that take the values that are needed in struct
  siginfo and build the siginfo structure for their callers. Ensuring
  struct siginfo is built correctly.

  The remaining work for 4.17 (unless someone thinks it is post -rc1
  material) is to push usage of those helpers down into the
  architectures so that architecture specific code will not need to deal
  with the fiddly work of intializing struct siginfo, and then when
  struct siginfo is guaranteed to be fully initialized change copy
  siginfo_to_user into a simple wrapper around copy_to_user.

  Further there is work in progress on the issues that have been
  documented requires arch specific knowledge to sort out.

  The changes below fix or at least document all of the issues that have
  been found with siginfo generation. Then proceed to unify struct
  siginfo the 32 bit helpers that copy siginfo to and from userspace,
  and generally clean up anything that is not arch specific with regards
  to siginfo generation.

  It is a lot but with the unification you can of siginfo you can
  already see the code reduction in the kernel"

* 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: (45 commits)
  signal/memory-failure: Use force_sig_mceerr and send_sig_mceerr
  mm/memory_failure: Remove unused trapno from memory_failure
  signal/ptrace: Add force_sig_ptrace_errno_trap and use it where needed
  signal/powerpc: Remove unnecessary signal_code parameter of do_send_trap
  signal: Helpers for faults with specialized siginfo layouts
  signal: Add send_sig_fault and force_sig_fault
  signal: Replace memset(info,...) with clear_siginfo for clarity
  signal: Don't use structure initializers for struct siginfo
  signal/arm64: Better isolate the COMPAT_TASK portion of ptrace_hbptriggered
  ptrace: Use copy_siginfo in setsiginfo and getsiginfo
  signal: Unify and correct copy_siginfo_to_user32
  signal: Remove the code to clear siginfo before calling copy_siginfo_from_user32
  signal: Unify and correct copy_siginfo_from_user32
  signal/blackfin: Remove pointless UID16_SIGINFO_COMPAT_NEEDED
  signal/blackfin: Move the blackfin specific si_codes to asm-generic/siginfo.h
  signal/tile: Move the tile specific si_codes to asm-generic/siginfo.h
  signal/frv: Move the frv specific si_codes to asm-generic/siginfo.h
  signal/ia64: Move the ia64 specific si_codes to asm-generic/siginfo.h
  signal/powerpc: Remove redefinition of NSIGTRAP on powerpc
  signal: Move addr_lsb into the _sigfault union for clarity
  ...
2018-01-30 14:18:52 -08:00
..
accessibility
acpi Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2018-01-30 14:18:52 -08:00
amba A couple of dma-mapping updates: 2017-11-14 16:54:12 -08:00
android binder: fix proc->files use-after-free 2017-12-18 15:47:12 +01:00
ata libata: apply MAX_SEC_1024 to all LITEON EP1 series devices 2017-12-19 05:30:38 -08:00
atm Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-11-29 13:10:25 -08:00
auxdisplay auxdisplay: img-ascii-lcd: Only build on archs that have IOMEM 2017-11-27 12:36:45 -08:00
base Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2018-01-30 14:18:52 -08:00
bcma bcma: Fix 'allmodconfig' and BCMA builds on MIPS targets 2018-01-16 21:13:55 +02:00
block Merge branch 'for-4.16/block' of git://git.kernel.dk/linux-block 2018-01-29 11:51:49 -08:00
bluetooth
bus Merge branches 'pm-domains', 'pm-kconfig', 'pm-cpuidle' and 'powercap' 2018-01-18 02:54:45 +01:00
cdrom Merge branch 'for-4.15/block' of git://git.kernel.dk/linux-block 2017-11-14 15:32:19 -08:00
char The big changes for IPMI that just went in had a few problems. These 2017-12-11 17:01:59 -08:00
clk clk: use atomic runtime pm api in clk_core_is_enabled 2017-12-26 17:34:03 -08:00
clocksource clocksource/drivers/stm32: Start the timer's counter sooner 2018-01-08 17:57:26 +01:00
connector
cpufreq Merge branch 'pm-cpufreq-thermal' into pm-cpufreq 2018-01-18 02:52:42 +01:00
cpuidle cpuidle: Avoid NULL argument in cpuidle_switch_governor() 2018-01-05 14:01:30 +01:00
crypto crypto: inside-secure - do not use areq->result for partial results 2017-12-22 19:48:01 +11:00
dax device-dax: implement ->split() to catch invalid munmap attempts 2017-11-29 18:40:42 -08:00
dca
devfreq PM / devfreq: Fix potential NULL pointer dereference in governor_store 2018-01-02 09:36:54 +09:00
dio
dma Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-01-30 10:15:30 -08:00
dma-buf Tracing updates for 4.15: 2017-11-17 14:58:01 -08:00
edac EDAC, mv64x60: Fix an error handling path 2018-01-09 20:14:23 +01:00
eisa
extcon extcon: axp288: Remove unused platform data 2018-01-03 10:11:02 +09:00
firewire Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2017-11-13 17:56:58 -08:00
firmware arm64 updates for 4.16: 2018-01-30 13:57:43 -08:00
fmc
fpga Char/Misc patches for 4.15-rc1 2017-11-16 09:10:59 -08:00
fsi
gpio sound updates for 4.16-rc1 2018-01-29 09:41:47 -08:00
gpu Merge branch 'linux-4.15' of git://github.com/skeggsb/linux into drm-fixes 2018-01-26 15:27:07 +10:00
hid Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid 2017-12-30 10:16:51 -08:00
hsi HSI changes for the v4.15 series 2017-11-15 13:35:43 -08:00
hv vmbus: unregister device_obj->channels_kset 2017-12-18 15:47:12 +01:00
hwmon hwmon: (dell-smm) Disable fan support for Dell Vostro 3360 2018-01-27 09:34:22 -08:00
hwspinlock hwspinlock update for v4.15 2017-11-17 20:16:20 -08:00
hwtracing arm64 updates for 4.16: 2018-01-30 13:57:43 -08:00
i2c Power management updates for v4.16-rc1 2018-01-29 09:47:41 -08:00
ide Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide 2017-11-19 08:04:41 -10:00
idle Merge branch 'pm-cpuidle' 2017-11-13 01:34:14 +01:00
iio Merge remote-tracking branches 'asoc/topic/hisilicon', 'asoc/topic/iio', 'asoc/topic/max98373' and 'asoc/topic/max98926' into asoc-next 2018-01-18 11:55:59 +00:00
infiniband Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-01-30 10:15:30 -08:00
input Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2018-01-25 17:30:47 -08:00
iommu iommu/arm-smmu-v3: Cope with duplicated Stream IDs 2018-01-02 16:45:51 +00:00
ipack
irqchip arm64 updates for 4.16: 2018-01-30 13:57:43 -08:00
isdn treewide: setup_timer() -> timer_setup() (2 field) 2017-11-21 15:57:09 -08:00
leds - New Drivers 2018-01-29 10:59:24 -08:00
lightnvm lightnvm: pblk: refactor pblk_ppa_comp function 2018-01-05 08:50:12 -07:00
macintosh Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2017-11-13 17:56:58 -08:00
mailbox Change to POLL api and fixes for FlexRM and OMAP driver 2017-11-15 13:39:18 -08:00
mcb
md Merge branch 'for-4.16/block' of git://git.kernel.dk/linux-block 2018-01-29 11:51:49 -08:00
media media fixes for v4.15-rc3 2017-12-08 13:18:47 -08:00
memory mtd: onenand: omap2: Configure driver from DT 2018-01-12 16:41:15 +01:00
memstick misc: rtsx: Move Realtek Card Reader Driver to misc 2017-11-29 10:16:44 +00:00
message Modules updates for v4.15 2017-11-15 13:46:33 -08:00
mfd regmap: Updates for v4.16 2018-01-29 11:35:24 -08:00
misc - New Drivers 2018-01-29 10:59:24 -08:00
mmc There are two major achievements for MMC in this release, which deserves to be 2018-01-29 11:26:11 -08:00
mtd This pull request contains updates for both UBI and UBIFS: 2018-01-29 13:31:47 -08:00
mux mux: core: fix double get_device() 2018-01-09 14:19:41 +01:00
net Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-01-30 10:15:30 -08:00
nfc treewide: setup_timer() -> timer_setup() (2 field) 2017-11-21 15:57:09 -08:00
ntb treewide: setup_timer() -> timer_setup() 2017-11-21 15:57:07 -08:00
nubus nubus: Add support for the driver model 2018-01-16 16:47:29 +01:00
nvdimm libnvdimm, btt: Fix an incompatibility in the log layout 2017-12-21 14:59:27 -08:00
nvme Merge branch 'for-4.16/block' of git://git.kernel.dk/linux-block 2018-01-29 11:51:49 -08:00
nvmem nvmem: meson-mx-efuse: fix reading from an offset other than 0 2017-12-23 16:46:23 +01:00
of arm64 updates for 4.16: 2018-01-30 13:57:43 -08:00
opp PM / OPP: Make local function ti_opp_supply_set_opp() static 2017-12-28 12:48:16 +01:00
oprofile
parisc parisc: Show unhashed EISA EEPROM address 2018-01-02 21:01:02 +01:00
parport Char/Misc patches for 4.15-rc1 2017-11-16 09:10:59 -08:00
pci Merge branch 'pm-core' 2018-01-18 02:55:09 +01:00
pcmcia drivers/pcmcia/sa1111_badge4.c: avoid unused function warning 2017-11-17 16:10:04 -08:00
perf perf: dsu: Use signed field for dsu_pmu->num_counters 2018-01-15 18:02:17 +00:00
phy phy: work around 'phys' references to usb-nop-xceiv devices 2018-01-19 16:12:37 +01:00
pinctrl genirq/irqdomain: Rename early argument of irq_domain_activate_irq() 2017-12-29 21:13:04 +01:00
platform - New Drivers 2018-01-29 10:59:24 -08:00
pnp PNP: pnpbios: Use PTR_ERR_OR_ZERO() 2017-12-16 02:59:45 +01:00
power PM / AVS: rockchip-io: account for const type of of_device_id.data 2018-01-05 13:36:33 +01:00
powercap powercap: intel_rapl: Fix trailing semicolon 2018-01-17 12:56:24 +01:00
pps treewide: setup_timer() -> timer_setup() 2017-11-21 15:57:07 -08:00
ps3
ptp xen: features and fixes for v4.15-rc1 2017-11-16 13:06:27 -08:00
pwm pwm: Changes for v4.15-rc1 2017-11-22 21:09:18 -10:00
rapidio Merge branch 'akpm' (patches from Andrew) 2017-11-17 16:56:17 -08:00
ras mm/memory_failure: Remove unused trapno from memory_failure 2018-01-23 12:17:42 -06:00
regulator Merge remote-tracking branch 'regulator/topic/tps65218' into regulator-next 2018-01-26 17:57:05 +00:00
remoteproc remoteproc updates for v4.15 2017-11-17 20:14:10 -08:00
reset ARM: SoC driver updates for v4.15 2017-11-16 16:05:01 -08:00
rpmsg rpmsg updates for v4.15 2017-11-17 20:12:08 -08:00
rtc Merge branch 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2017-11-25 08:37:16 -10:00
s390 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux 2018-01-05 12:17:33 -08:00
sbus Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc 2017-11-17 20:21:44 -08:00
scsi Power management updates for v4.16-rc1 2018-01-29 09:47:41 -08:00
sfi
sh A couple of dma-mapping updates: 2017-11-14 16:54:12 -08:00
sn
soc meson-gx-socinfo: Fix package id parsing 2017-11-30 15:29:44 -08:00
spi Merge remote-tracking branch 'spi/topic/xilinx' into spi-next 2018-01-26 17:57:34 +00:00
spmi
ssb ssb: Disable PCI host for PCI_DRIVERS_GENERIC 2018-01-16 21:15:58 +02:00
staging inode->i_version rework for v4.16 2018-01-29 13:33:53 -08:00
target Merge branch 'for-4.16/block' of git://git.kernel.dk/linux-block 2018-01-29 11:51:49 -08:00
tc
tee optee: fix invalid of_node_put() in optee_driver_init() 2017-11-29 10:24:57 +01:00
thermal cpu_cooling: Drop static-power related stuff 2017-12-07 22:52:01 +01:00
thunderbolt thunderbolt: Mask ring interrupt properly when polling starts 2017-12-16 16:37:51 +01:00
tty - New Drivers 2018-01-29 10:59:24 -08:00
uio
usb Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2018-01-30 14:18:52 -08:00
uwb treewide: setup_timer() -> timer_setup() 2017-11-21 15:57:07 -08:00
vfio VFIO Updates for Linux v4.15 2017-11-14 16:47:47 -08:00
vhost Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-01-30 10:15:30 -08:00
video m68k updates for 4.16 2018-01-29 16:37:15 -08:00
virt
virtio virtio_mmio: fix devm cleanup 2017-12-14 21:01:40 +02:00
vlynq
vme Char/Misc patches for 4.15-rc1 2017-11-16 09:10:59 -08:00
w1 Char/Misc patches for 4.15-rc1 2017-11-16 09:10:59 -08:00
watchdog watchdog: Add RAVE SP watchdog driver 2018-01-08 10:08:36 +00:00
xen xen: fixes for 4.15-rc8 2018-01-12 10:00:15 -08:00
zorro
Kconfig Merge branches 'pm-cpufreq-sched' and 'pm-opp' 2017-11-13 01:40:52 +01:00
Makefile usb: build drivers/usb/common/ when USB_SUPPORT is set 2017-11-28 15:17:49 +01:00