All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: linux-kernel@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	stable@vger.kernel.org,
	Christophe Leroy <christophe.leroy@csgroup.eu>,
	Masahiro Yamada <masahiroy@kernel.org>,
	Michael Ellerman <mpe@ellerman.id.au>
Subject: [PATCH 5.15 034/107] powerpc: align syscall table for ppc32
Date: Tue,  6 Sep 2022 15:30:15 +0200	[thread overview]
Message-ID: <20220906132823.236001530@linuxfoundation.org> (raw)
In-Reply-To: <20220906132821.713989422@linuxfoundation.org>

From: Masahiro Yamada <masahiroy@kernel.org>

commit c7acee3d2f128a38b68fb7af85dbbd91bfd0b4ad upstream.

Christophe Leroy reported that commit 7b4537199a4a ("kbuild: link
symbol CRCs at final link,  removing CONFIG_MODULE_REL_CRCS") broke
mpc85xx_defconfig + CONFIG_RELOCATABLE=y.

    LD      vmlinux
    SYSMAP  System.map
    SORTTAB vmlinux
    CHKREL  vmlinux
  WARNING: 451 bad relocations
  c0b312a9 R_PPC_UADDR32     .head.text-0x3ff9ed54
  c0b312ad R_PPC_UADDR32     .head.text-0x3ffac224
  c0b312b1 R_PPC_UADDR32     .head.text-0x3ffb09f4
  c0b312b5 R_PPC_UADDR32     .head.text-0x3fe184dc
  c0b312b9 R_PPC_UADDR32     .head.text-0x3fe183a8
      ...

The compiler emits a bunch of R_PPC_UADDR32, which is not supported by
arch/powerpc/kernel/reloc_32.S.

The reason is there exists an unaligned symbol.

  $ powerpc-linux-gnu-nm -n vmlinux
    ...
  c0b31258 d spe_aligninfo
  c0b31298 d __func__.0
  c0b312a9 D sys_call_table
  c0b319b8 d __func__.0

Commit 7b4537199a4a is not the root cause. Even before that, I can
reproduce the same issue for mpc85xx_defconfig + CONFIG_RELOCATABLE=y
+ CONFIG_MODVERSIONS=n.

It is just that nobody noticed because when CONFIG_MODVERSIONS is
enabled, a __crc_* symbol inserted before sys_call_table was hiding the
unalignment issue.

Adding alignment to the syscall table for ppc32 fixes the issue.

Cc: stable@vger.kernel.org
Reported-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Christophe Leroy <christophe.leroy@csgroup.eu>
[mpe: Trim change log discussion, add Cc stable]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/lkml/38605f6a-a568-f884-f06f-ea4da5b214f0@csgroup.eu/
Link: https://lore.kernel.org/r/20220820165129.1147589-1-masahiroy@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 arch/powerpc/kernel/systbl.S |    1 +
 1 file changed, 1 insertion(+)

--- a/arch/powerpc/kernel/systbl.S
+++ b/arch/powerpc/kernel/systbl.S
@@ -18,6 +18,7 @@
 	.p2align	3
 #define __SYSCALL(nr, entry)	.8byte entry
 #else
+	.p2align	2
 #define __SYSCALL(nr, entry)	.long entry
 #endif
 



  parent reply	other threads:[~2022-09-06 13:50 UTC|newest]

Thread overview: 133+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-06 13:29 [PATCH 5.15 000/107] 5.15.66-rc1 review Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 001/107] drm/msm/dsi: fix the inconsistent indenting Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 002/107] drm/msm/dp: delete DP_RECOVERED_CLOCK_OUT_EN to fix tps4 Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 003/107] drm/msm/dsi: Fix number of regulators for msm8996_dsi_cfg Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 004/107] drm/msm/dsi: Fix number of regulators for SDM660 Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 005/107] platform/x86: pmc_atom: Fix SLP_TYPx bitfield mask Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 006/107] iio: adc: mcp3911: make use of the sign bit Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 007/107] skmsg: Fix wrong last sg check in sk_msg_recvmsg() Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 008/107] bpf: Restrict bpf_sys_bpf to CAP_PERFMON Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 009/107] bpf, cgroup: Fix kernel BUG in purge_effective_progs Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 010/107] ieee802154/adf7242: defer destroy_workqueue call Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 011/107] drm/i915/backlight: extract backlight code to a separate file Greg Kroah-Hartman
2022-09-06 22:13   ` Lyude Paul
2022-09-07 11:41     ` Sasha Levin
2022-09-07 20:37       ` Lyude Paul
2022-09-06 13:29 ` [PATCH 5.15 012/107] drm/i915/display: avoid warnings when registering dual panel backlight Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 013/107] ALSA: hda: intel-nhlt: remove use of __func__ in dev_dbg Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 014/107] ALSA: hda: intel-nhlt: Correct the handling of fmt_config flexible array Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 015/107] wifi: cfg80211: debugfs: fix return type in ht40allow_map_read() Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 016/107] Revert "xhci: turn off port power in shutdown" Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 017/107] net: sparx5: fix handling uneven length packets in manual extraction Greg Kroah-Hartman
2022-09-06 13:29 ` [PATCH 5.15 018/107] net: smsc911x: Stop and start PHY during suspend and resume Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 019/107] openvswitch: fix memory leak at failed datapath creation Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 020/107] net: dsa: xrs700x: Use irqsave variant for u64 stats update Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 021/107] net: sched: tbf: dont call qdisc_put() while holding tree lock Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 022/107] net/sched: fix netdevice reference leaks in attach_default_qdiscs() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 023/107] ethernet: rocker: fix sleep in atomic context bug in neigh_timer_handler Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 024/107] mlxbf_gige: compute MDIO period based on i1clk Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 025/107] kcm: fix strp_init() order and cleanup Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 026/107] sch_cake: Return __NET_XMIT_STOLEN when consuming enqueued skb Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 027/107] tcp: annotate data-race around challenge_timestamp Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 028/107] Revert "sch_cake: Return __NET_XMIT_STOLEN when consuming enqueued skb" Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 029/107] net/smc: Remove redundant refcount increase Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 030/107] soundwire: qcom: fix device status array range Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 031/107] serial: fsl_lpuart: RS485 RTS polariy is inverse Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 032/107] staging: rtl8712: fix use after free bugs Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 033/107] staging: r8188eu: add firmware dependency Greg Kroah-Hartman
2022-09-06 13:30 ` Greg Kroah-Hartman [this message]
2022-09-06 13:30 ` [PATCH 5.15 035/107] vt: Clear selection before changing the font Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 036/107] musb: fix USB_MUSB_TUSB6010 dependency Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 037/107] tty: serial: lpuart: disable flow control while waiting for the transmit engine to complete Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 038/107] Input: iforce - wake up after clearing IFORCE_XMIT_RUNNING flag Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 039/107] iio: ad7292: Prevent regulator double disable Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 040/107] iio: adc: mcp3911: use correct formula for AD conversion Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 041/107] misc: fastrpc: fix memory corruption on probe Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 042/107] misc: fastrpc: fix memory corruption on open Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 043/107] USB: serial: ftdi_sio: add Omron CS1W-CIF31 device id Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 044/107] mmc: core: Fix UHS-I SD 1.8V workaround branch Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 045/107] mmc: core: Fix inconsistent sd3_bus_mode at UHS-I SD voltage switch failure Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 046/107] binder: fix UAF of ref->proc caused by race condition Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 047/107] binder: fix alloc->vma_vm_mm null-ptr dereference Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 048/107] cifs: fix small mempool leak in SMB2_negotiate() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 049/107] KVM: VMX: Heed the msr argument in msr_write_intercepted() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 050/107] drm/i915/reg: Fix spelling mistake "Unsupport" -> "Unsupported" Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 051/107] clk: core: Honor CLK_OPS_PARENT_ENABLE for clk gate ops Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 052/107] Revert "clk: core: Honor CLK_OPS_PARENT_ENABLE for clk gate ops" Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 053/107] clk: core: Fix runtime PM sequence in clk_core_unprepare() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 054/107] Input: rk805-pwrkey - fix module autoloading Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 055/107] clk: bcm: rpi: Fix error handling of raspberrypi_fw_get_rate Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 056/107] clk: bcm: rpi: Use correct order for the parameters of devm_kcalloc() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 057/107] clk: bcm: rpi: Prevent out-of-bounds access Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 058/107] clk: bcm: rpi: Add missing newline Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 059/107] hwmon: (gpio-fan) Fix array out of bounds access Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 060/107] gpio: pca953x: Add mutex_lock for regcache sync in PM Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 061/107] KVM: x86: Mask off unsupported and unknown bits of IA32_ARCH_CAPABILITIES Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 062/107] xen/grants: prevent integer overflow in gnttab_dma_alloc_pages() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 063/107] mm: pagewalk: Fix race between unmap and page walker Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 064/107] xen-blkback: Advertise feature-persistent as user requested Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 065/107] xen-blkfront: " Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 066/107] xen-blkfront: Cache feature_persistent value before advertisement Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 067/107] thunderbolt: Use the actual buffer in tb_async_error() Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 068/107] usb: dwc3: pci: Add support for Intel Raptor Lake Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 069/107] media: mceusb: Use new usb_control_msg_*() routines Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 070/107] xhci: Add grace period after xHC start to prevent premature runtime suspend Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 071/107] USB: serial: cp210x: add Decagon UCA device id Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 072/107] USB: serial: option: add support for OPPO R11 diag port Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 073/107] USB: serial: option: add Quectel EM060K modem Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 074/107] USB: serial: option: add support for Cinterion MV32-WA/WB RmNet mode Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 075/107] usb: typec: altmodes/displayport: correct pin assignment for UFP receptacles Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 076/107] usb: typec: intel_pmc_mux: Add new ACPI ID for Meteor Lake IOM device Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 077/107] usb: typec: tcpm: Return ENOTSUPP for power supply prop writes Greg Kroah-Hartman
2022-09-06 13:30 ` [PATCH 5.15 078/107] usb: dwc2: fix wrong order of phy_power_on and phy_init Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 079/107] usb: cdns3: fix issue with rearming ISO OUT endpoint Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 080/107] usb: cdns3: fix incorrect handling TRB_SMM flag for ISOC transfer Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 081/107] USB: cdc-acm: Add Icom PMR F3400 support (0c26:0020) Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 082/107] usb-storage: Add ignore-residue quirk for NXP PN7462AU Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 083/107] s390/hugetlb: fix prepare_hugepage_range() check for 2 GB hugepages Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 084/107] s390: fix nospec table alignments Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 085/107] USB: core: Prevent nested device-reset calls Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 086/107] usb: xhci-mtk: relax TT periodic bandwidth allocation Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 087/107] usb: xhci-mtk: fix bandwidth release issue Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 088/107] usb: gadget: mass_storage: Fix cdrom data transfers on MAC-OS Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 089/107] driver core: Dont probe devices after bus_type.match() probe deferral Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 090/107] wifi: mac80211: Dont finalize CSA in IBSS mode if state is disconnected Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 091/107] wifi: mac80211: Fix UAF in ieee80211_scan_rx() Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 092/107] ip: fix triggering of icmp redirect Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 093/107] net: Use u64_stats_fetch_begin_irq() for stats fetch Greg Kroah-Hartman
2022-09-06 13:31   ` Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 094/107] net: mac802154: Fix a condition in the receive path Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 095/107] ALSA: hda/realtek: Add speaker AMP init for Samsung laptops with ALC298 Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 096/107] ALSA: seq: oss: Fix data-race for max_midi_devs access Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 097/107] ALSA: seq: Fix data-race at module auto-loading Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 098/107] drm/i915/glk: ECS Liva Q2 needs GLK HDMI port timing quirk Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 099/107] drm/i915: Skip wm/ddb readout for disabled pipes Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 100/107] tty: n_gsm: add sanity check for gsm->receive in gsm_receive_buf() Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 101/107] kbuild: Unify options for BTF generation for vmlinux and modules Greg Kroah-Hartman
2022-09-06 18:45   ` Florian Fainelli
2022-09-07  5:40     ` Greg Kroah-Hartman
2022-09-07  7:02       ` Jiri Olsa
2022-09-07  8:13       ` Ron Economos
2022-09-06 13:31 ` [PATCH 5.15 102/107] kbuild: Add skip_encoding_btf_enum64 option to pahole Greg Kroah-Hartman
2022-09-16 10:21   ` Thorsten Leemhuis
2022-09-16 13:01     ` Jiri Olsa
2022-09-16 16:25     ` Martin Rodriguez Reboredo
2022-09-06 13:31 ` [PATCH 5.15 103/107] usb: dwc3: fix PHY disable sequence Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 104/107] usb: dwc3: qcom: fix use-after-free on runtime-PM wakeup Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 105/107] usb: dwc3: disable USB core PHY management Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 106/107] USB: serial: ch341: fix lost character on LCR updates Greg Kroah-Hartman
2022-09-06 13:31 ` [PATCH 5.15 107/107] USB: serial: ch341: fix disabled rx timer on older devices Greg Kroah-Hartman
2022-09-06 18:33 ` [PATCH 5.15 000/107] 5.15.66-rc1 review Florian Fainelli
2022-09-06 18:42   ` Florian Fainelli
2022-09-06 20:20 ` Naresh Kamboju
2022-09-06 20:46 ` Sudip Mukherjee
2022-09-07  5:49   ` Greg Kroah-Hartman
2022-09-07  9:27     ` Sudip Mukherjee (Codethink)
2022-09-06 21:48 ` Shuah Khan
2022-09-07  4:44 ` Guenter Roeck
2022-09-07  9:40 ` Sudip Mukherjee (Codethink)
2022-09-07 11:30   ` Sudip Mukherjee
2022-09-07 11:45     ` Greg Kroah-Hartman
2022-09-07  9:52 ` Bagas Sanjaya
2022-09-07 12:48 ` Ron Economos
2022-09-08 10:50 ` Jon Hunter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220906132823.236001530@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=mpe@ellerman.id.au \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.