Package: src:linux
Version: 5.10.106-1
Severity: normal
X-Debbugs-Cc: pa...@labath.sk, mgorny@moritz.systems

Dear Maintainer,

Using PTRACE_CONT with a signal number should immediately deliver that
signal to the application. This is what happens whenever the
applications is stopped due to some signal other than SIGSTOP. It is
also what happens with SIGSTOPs on other linux distros I tried (this
includes a 5.10-based gentoo kernel), but for some reason, it does not
happen with the debian kernel. I assume this is due to some upstream
bug/quirk, which has since been fixed.

To reproduce, compile&run the attached program:
-----
$ g++ repr-stop.cc
$ ./a.out
Unexpectedly stopped with User defined signal 1
a.out: repr-stop.cc:34: void parent(pid_t): Assertion `WIFEXITED(status)' 
failed.
Aborted
-----

The expected behavior is for the program to terminate with exit code
zero and print the "hello from %x" message.


-- Package-specific info:
** Version:
Linux version 5.10.0-13-amd64 (debian-ker...@lists.debian.org) (gcc-10 (Debian 
10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2) #1 SMP 
Debian 5.10.106-1 (2022-03-17)

** Command line:
BOOT_IMAGE=/boot/vmlinuz-5.10.0-13-amd64 root=/dev/mapper/VOY-debian ro 
net.ifnames=0 quiet

** Not tainted

** Kernel log:
No relevant messages in kernel log.

** Model information
sys_vendor: HP
product_name: HP ProBook 450 G7
product_version: 
chassis_vendor: HP
chassis_version: 
bios_vendor: HP
bios_version: S71 Ver. 01.07.02
board_vendor: HP
board_name: 86A0
board_version: KBC Version 02.2F.00

** Loaded modules:
tun
ctr
ccm
dm_crypt
cmac
algif_hash
algif_skcipher
af_alg
bnep
btusb
btrtl
btbcm
btintel
bluetooth
uvcvideo
videobuf2_vmalloc
snd_soc_skl_hda_dsp
videobuf2_memops
snd_soc_hdac_hdmi
jitterentropy_rng
videobuf2_v4l2
videobuf2_common
drbg
videodev
ansi_cprng
ecdh_generic
mc
ecc
snd_hda_codec_hdmi
snd_hda_codec_realtek
snd_hda_codec_generic
snd_soc_dmic
snd_sof_pci
snd_sof_intel_byt
snd_sof_intel_ipc
snd_sof_intel_hda_common
snd_sof_xtensa_dsp
intel_pmc_core_pltdrv
intel_pmc_core
snd_sof
snd_sof_intel_hda
snd_soc_hdac_hda
snd_hda_ext_core
snd_soc_acpi_intel_match
snd_soc_acpi
ledtrig_audio
snd_hda_intel
joydev
snd_intel_dspcfg
soundwire_intel
soundwire_generic_allocation
snd_soc_core
snd_compress
x86_pkg_temp_thermal
soundwire_cadence
intel_powerclamp
coretemp
snd_hda_codec
kvm_intel
kvm
iwlmvm
iTCO_wdt
intel_pmc_bxt
hid_multitouch
iTCO_vendor_support
hp_wmi
mmc_block
watchdog
irqbypass
hid_generic
mei_hdcp
crc32_pclmul
intel_rapl_msr
sparse_keymap
wmi_bmof
ghash_clmulni_intel
rapl
intel_cstate
intel_uncore
mac80211
binfmt_misc
snd_hda_core
ahci
libarc4
snd_hwdep
libahci
soundwire_bus
xhci_pci
pcspkr
efi_pstore
libata
xhci_hcd
iwlwifi
snd_pcm
nls_ascii
r8169
i2c_i801
snd_timer
nls_cp437
i2c_smbus
snd
realtek
vfat
mdio_devres
soundcore
fat
cfg80211
libphy
scsi_mod
usbcore
sdhci_pci
mei_me
mei
cqhci
sdhci
processor_thermal_device
intel_lpss_pci
ucsi_acpi
typec_ucsi
i2c_hid
intel_lpss
intel_rapl_common
idma64
mmc_core
rfkill
usb_common
intel_pch_thermal
intel_soc_dts_iosf
tpm_crb
typec
hid
wmi
battery
int3403_thermal
int340x_thermal_zone
tpm_tis
tpm_tis_core
tpm
hp_accel
rng_core
lis3lv02d
acpi_pad
int3400_thermal
hp_wireless
ac
button
acpi_thermal_rel
parport_pc
ppdev
lp
parport
fuse
configfs
efivarfs
ip_tables
x_tables
autofs4
ext4
crc16
mbcache
jbd2
crc32c_generic
i915
dm_mod
i2c_algo_bit
drm_kms_helper
cec
crc32c_intel
drm
aesni_intel
nvme
nvme_core
glue_helper
libaes
crypto_simd
cryptd
evdev
t10_pi
crc_t10dif
serio_raw
crct10dif_generic
crct10dif_pclmul
crct10dif_common
video

** PCI devices:
00:00.0 Host bridge [0600]: Intel Corporation Comet Lake-U v1 4c Host 
Bridge/DRAM Controller [8086:9b61] (rev 0c)
        Subsystem: Hewlett-Packard Company Comet Lake-U v1 4c Host Bridge/DRAM 
Controller [103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort+ >SERR- <PERR- INTx-
        Latency: 0
        IOMMU group: 0
        Capabilities: <access denied>
        Kernel driver in use: skl_uncore

00:02.0 VGA compatible controller [0300]: Intel Corporation CometLake-U GT2 
[UHD Graphics] [8086:9b41] (rev 02) (prog-if 00 [VGA controller])
        DeviceName: Onboard IGD
        Subsystem: Hewlett-Packard Company UHD Graphics [103c:86a0]
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 133
        IOMMU group: 1
        Region 0: Memory at f0000000 (64-bit, non-prefetchable) [size=16M]
        Region 2: Memory at e0000000 (64-bit, prefetchable) [size=256M]
        Region 4: I/O ports at 4000 [size=64]
        Expansion ROM at 000c0000 [virtual] [disabled] [size=128K]
        Capabilities: <access denied>
        Kernel driver in use: i915
        Kernel modules: i915

00:04.0 Signal processing controller [1180]: Intel Corporation Xeon E3-1200 
v5/E3-1500 v5/6th Gen Core Processor Thermal Subsystem [8086:1903] (rev 0c)
        Subsystem: Hewlett-Packard Company Xeon E3-1200 v5/E3-1500 v5/6th Gen 
Core Processor Thermal Subsystem [103c:86a0]
        Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 2
        Region 0: Memory at 4000100000 (64-bit, non-prefetchable) [size=32K]
        Capabilities: <access denied>
        Kernel driver in use: proc_thermal
        Kernel modules: processor_thermal_device

00:12.0 Signal processing controller [1180]: Intel Corporation Comet Lake 
Thermal Subsytem [8086:02f9]
        Subsystem: Hewlett-Packard Company Comet Lake Thermal Subsytem 
[103c:86a0]
        Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 3
        Region 0: Memory at 4000111000 (64-bit, non-prefetchable) [size=4K]
        Capabilities: <access denied>
        Kernel driver in use: intel_pch_thermal
        Kernel modules: intel_pch_thermal

00:14.0 USB controller [0c03]: Intel Corporation Comet Lake PCH-LP USB 3.1 xHCI 
Host Controller [8086:02ed] (prog-if 30 [XHCI])
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP USB 3.1 xHCI Host 
Controller [103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- 
<TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 148
        IOMMU group: 4
        Region 0: Memory at f1200000 (64-bit, non-prefetchable) [size=64K]
        Capabilities: <access denied>
        Kernel driver in use: xhci_hcd
        Kernel modules: xhci_pci

00:14.2 RAM memory [0500]: Intel Corporation Comet Lake PCH-LP Shared SRAM 
[8086:02ef]
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP Shared SRAM 
[103c:86a0]
        Control: I/O- Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        IOMMU group: 4
        Region 0: Memory at f1216000 (64-bit, non-prefetchable) [disabled] 
[size=8K]
        Region 2: Memory at 4000110000 (64-bit, non-prefetchable) [disabled] 
[size=4K]
        Capabilities: <access denied>

00:14.3 Network controller [0280]: Intel Corporation Comet Lake PCH-LP CNVi 
WiFi [8086:02f0]
        Subsystem: Intel Corporation Wi-Fi 6 AX201 160MHz [8086:0074]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 5
        Region 0: Memory at f1210000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: <access denied>
        Kernel driver in use: iwlwifi
        Kernel modules: iwlwifi

00:14.5 SD Host controller [0805]: Intel Corporation Comet Lake PCH-LP SCS3 
[8086:02f5] (prog-if 01)
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP SCS3 [103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin D routed to IRQ 19
        IOMMU group: 4
        Region 0: Memory at 400010f000 (64-bit, non-prefetchable) [size=4K]
        Capabilities: <access denied>
        Kernel driver in use: sdhci-pci
        Kernel modules: sdhci_pci

00:15.0 Serial bus controller [0c80]: Intel Corporation Serial IO I2C Host 
Controller [8086:02e8]
        Subsystem: Hewlett-Packard Company Serial IO I2C Host Controller 
[103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 6
        Region 0: Memory at 400010e000 (64-bit, non-prefetchable) [virtual] 
[size=4K]
        Capabilities: <access denied>
        Kernel driver in use: intel-lpss
        Kernel modules: intel_lpss_pci

00:16.0 Communication controller [0780]: Intel Corporation Comet Lake 
Management Engine Interface [8086:02e0]
        Subsystem: Hewlett-Packard Company Comet Lake Management Engine 
Interface [103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 134
        IOMMU group: 7
        Region 0: Memory at 400010d000 (64-bit, non-prefetchable) [size=4K]
        Capabilities: <access denied>
        Kernel driver in use: mei_me
        Kernel modules: mei_me

00:17.0 SATA controller [0106]: Intel Corporation Comet Lake SATA AHCI 
Controller [8086:02d3] (prog-if 01 [AHCI 1.0])
        Subsystem: Hewlett-Packard Company Comet Lake SATA AHCI Controller 
[103c:86a0]
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- 
<TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 149
        IOMMU group: 8
        Region 0: Memory at f1214000 (32-bit, non-prefetchable) [size=8K]
        Region 1: Memory at f121a000 (32-bit, non-prefetchable) [size=256]
        Region 2: I/O ports at 4080 [size=8]
        Region 3: I/O ports at 4088 [size=4]
        Region 4: I/O ports at 4060 [size=32]
        Region 5: Memory at f1219000 (32-bit, non-prefetchable) [size=2K]
        Capabilities: <access denied>
        Kernel driver in use: ahci
        Kernel modules: ahci

00:1d.0 PCI bridge [0604]: Intel Corporation Device [8086:02b0] (rev f0) 
(prog-if 00 [Normal decode])
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 122
        IOMMU group: 9
        Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
        I/O behind bridge: 00003000-00003fff [size=4K]
        Memory behind bridge: f1100000-f11fffff [size=1M]
        Prefetchable memory behind bridge: [disabled]
        Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort+ <SERR- <PERR-
        BridgeCtl: Parity- SERR+ NoISA- VGA- VGA16- MAbort- >Reset- FastB2B-
                PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
        Capabilities: <access denied>
        Kernel driver in use: pcieport

00:1d.4 PCI bridge [0604]: Intel Corporation Device [8086:02b4] (rev f0) 
(prog-if 00 [Normal decode])
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 123
        IOMMU group: 10
        Bus: primary=00, secondary=02, subordinate=02, sec-latency=0
        I/O behind bridge: [disabled]
        Memory behind bridge: f1000000-f10fffff [size=1M]
        Prefetchable memory behind bridge: [disabled]
        Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort+ <SERR- <PERR-
        BridgeCtl: Parity- SERR+ NoISA- VGA- VGA16- MAbort- >Reset- FastB2B-
                PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
        Capabilities: <access denied>
        Kernel driver in use: pcieport

00:1f.0 ISA bridge [0601]: Intel Corporation Comet Lake PCH-LP LPC Premium 
Controller/eSPI Controller [8086:0284]
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP LPC Premium 
Controller/eSPI Controller [103c:86a0]
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap- 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        IOMMU group: 11

00:1f.3 Multimedia audio controller [0401]: Intel Corporation Comet Lake PCH-LP 
cAVS [8086:02c8]
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP cAVS [103c:86a0]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 64
        Interrupt: pin A routed to IRQ 150
        IOMMU group: 11
        Region 0: Memory at 4000108000 (64-bit, non-prefetchable) [size=16K]
        Region 4: Memory at 4000000000 (64-bit, non-prefetchable) [size=1M]
        Capabilities: <access denied>
        Kernel driver in use: sof-audio-pci
        Kernel modules: snd_hda_intel, snd_sof_pci

00:1f.4 SMBus [0c05]: Intel Corporation Comet Lake PCH-LP SMBus Host Controller 
[8086:02a3]
        Subsystem: Hewlett-Packard Company Comet Lake PCH-LP SMBus Host 
Controller [103c:86a0]
        Control: I/O+ Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx-
        Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- 
<TAbort- <MAbort- >SERR- <PERR- INTx-
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 11
        Region 0: Memory at 400010c000 (64-bit, non-prefetchable) [size=256]
        Region 4: I/O ports at efa0 [size=32]
        Kernel driver in use: i801_smbus
        Kernel modules: i2c_i801

00:1f.5 Serial bus controller [0c80]: Intel Corporation Comet Lake SPI (flash) 
Controller [8086:02a4]
        Subsystem: Hewlett-Packard Company Comet Lake SPI (flash) Controller 
[103c:86a0]
        Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap- 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        IOMMU group: 11
        Region 0: Memory at fe010000 (32-bit, non-prefetchable) [size=4K]

01:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. 
RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 15)
        Subsystem: Hewlett-Packard Company RTL8111/8168/8411 PCI Express 
Gigabit Ethernet Controller [103c:86a0]
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin A routed to IRQ 16
        IOMMU group: 12
        Region 0: I/O ports at 3000 [size=256]
        Region 2: Memory at f1104000 (64-bit, non-prefetchable) [size=4K]
        Region 4: Memory at f1100000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: <access denied>
        Kernel driver in use: r8169
        Kernel modules: r8169

02:00.0 Non-Volatile memory controller [0108]: Intel Corporation SSD 660P 
Series [8086:f1a8] (rev 03) (prog-if 02 [NVM Express])
        Subsystem: Intel Corporation SSD 660P Series [8086:390d]
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- 
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- 
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 16
        NUMA node: 0
        IOMMU group: 13
        Region 0: Memory at f1000000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: <access denied>
        Kernel driver in use: nvme
        Kernel modules: nvme


** USB devices:
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 06cb:00df Synaptics, Inc. 
Bus 001 Device 002: ID 04ca:7095 Lite-On Technology Corp. HP HD Camera
Bus 001 Device 004: ID 8087:0026 Intel Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


-- System Information:
Debian Release: 11.3
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: arm64

Kernel: Linux 5.10.0-13-amd64 (SMP w/8 CPU threads)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_GB:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages linux-image-5.10.0-13-amd64 depends on:
ii  initramfs-tools [linux-initramfs-tool]  0.140
ii  kmod                                    28-1
ii  linux-base                              4.6

Versions of packages linux-image-5.10.0-13-amd64 recommends:
ii  apparmor             2.13.6-10
ii  firmware-linux-free  20200122-1

Versions of packages linux-image-5.10.0-13-amd64 suggests:
pn  debian-kernel-handbook  <none>
ii  grub-efi-amd64          2.04-20
pn  linux-doc-5.10          <none>

Versions of packages linux-image-5.10.0-13-amd64 is related to:
pn  firmware-amd-graphics     <none>
pn  firmware-atheros          <none>
pn  firmware-bnx2             <none>
pn  firmware-bnx2x            <none>
pn  firmware-brcm80211        <none>
pn  firmware-cavium           <none>
pn  firmware-intel-sound      <none>
pn  firmware-intelwimax       <none>
pn  firmware-ipw2x00          <none>
pn  firmware-ivtv             <none>
ii  firmware-iwlwifi          20210315-3
pn  firmware-libertas         <none>
pn  firmware-linux-nonfree    <none>
ii  firmware-misc-nonfree     20210315-3
pn  firmware-myricom          <none>
pn  firmware-netxen           <none>
pn  firmware-qlogic           <none>
ii  firmware-realtek          20210315-3
pn  firmware-samsung          <none>
pn  firmware-siano            <none>
pn  firmware-ti-connectivity  <none>
pn  xen-hypervisor            <none>

-- no debconf information
#include <sys/ptrace.h>
#include <sys/wait.h>
#include <unistd.h>
#include <cassert>
#include <csignal>
#include <cstdio>
#include <cstring>

void h(int) {
        fprintf(stderr, "hello from %x\n", gettid());
}

void __attribute__((noreturn)) child() {
        signal(SIGUSR1, h);
        ptrace(PTRACE_TRACEME);
        raise(SIGSTOP);
        _exit(0);
}

void parent(pid_t ch) {
        int status;

        pid_t w = waitpid(ch, &status, 0);
        assert(w == ch);
        assert(WIFSTOPPED(status));
        assert(WSTOPSIG(status) == SIGSTOP);
        ptrace(PTRACE_CONT, ch, 0, SIGUSR1);

        w = waitpid(ch, &status, 0);
        assert(w == ch);
        if (WIFSTOPPED(status)) {
                fprintf(stderr, "Unexpectedly stopped with %s\n", 
strsignal(WSTOPSIG(status)));
        }
        assert(WIFEXITED(status));
        assert(WEXITSTATUS(status) == 0);
}

int main() {
        pid_t f = fork();
        assert(f >= 0);
        if (f == 0)
                child();
        parent(f);

}

Reply via email to