Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

61.0.A.11.xxx won't compile due to broken /include/linux/memcontrol.h #19

Open
hdoublearp opened this issue Mar 13, 2022 · 1 comment
Open

Comments

@hdoublearp
Copy link

hdoublearp commented Mar 13, 2022

As title suggests. Build environment is Ubuntu 20.04 LTS (x86_64) with clang and aarch64-linux-gnu- cross compiler. Attempting to build this for the Xperia 1 III (XQ-BC62).

Using the copyleft DTS archive copied to arch/arm64/boot/dts/, target lahaina_qgki along with pdx215_diffconfig.

Issue: there seems to be a broken include in branch 61.0.A.11.xxx. I have reproduced the issue a few times now with clean build environments.

Compile error at ./include/linux/memcontrol.h:959:1: error: expected identifier or '('
{
^

Compiler output:

~/kernel-copyleft-61.0.A.11.xxx$ ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- make CC=clang -j$(nproc --all)
  HOSTCC  scripts/mod/mk_elfconfig
  CC      scripts/mod/devicetable-offsets.s
  CC      scripts/mod/empty.o
  DTC     arch/arm64/boot/dts/somc/lahaina-v2-sagami-pdx215_generic.dtb
  MKELF   scripts/mod/elfconfig.h
  HOSTCC  scripts/mod/modpost.o
  HOSTCC  scripts/mod/sumversion.o
arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:236.3-16: Warning (reg_format): /soc/sony,camera_modules@0:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:317.3-16: Warning (reg_format): /soc/sony,camera_modules@1:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:406.3-16: Warning (reg_format): /soc/sony,camera_modules@2:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:478.3-16: Warning (reg_format): /soc/sony,camera_modules@3:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:551.3-16: Warning (reg_format): /soc/sony,camera_modules@4:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
arch/arm64/boot/dts/somc/lahaina-v2-sagami-pdx215_generic.dtb: Warning (pci_device_bus_num): Failed prerequisite 'reg_format'
arch/arm64/boot/dts/somc/lahaina-v2-sagami-pdx215_generic.dtb: Warning (i2c_bus_reg): Failed prerequisite 'reg_format'
arch/arm64/boot/dts/somc/lahaina-v2-sagami-pdx215_generic.dtb: Warning (spi_bus_reg): Failed prerequisite 'reg_format'
arch/arm64/boot/dts/somc/../qcom/lahaina-audio.dtsi:92.21-194.4: Warning (gpios_property): /soc/qcom,msm-audio-apr/qcom,q6core-audio/sound: Missing property '#gpio-cells' in node /soc/qcom,msm-audio-apr/qcom,q6core-audio/msm_cdc_pinctrl_pri or bad phandle (referred from qcom,pri-mi2s-gpios[0])
  also defined at arch/arm64/boot/dts/somc/../qcom/lahaina-audio-overlay.dtsi:286.14-385.3
  also defined at arch/arm64/boot/dts/somc/../qcom/lahaina-mtp.dtsi:149.14-151.3
  also defined at arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:1045.14-1108.3
arch/arm64/boot/dts/somc/../qcom/lahaina-audio.dtsi:92.21-194.4: Warning (gpios_property): /soc/qcom,msm-audio-apr/qcom,q6core-audio/sound: Missing property '#gpio-cells' in node /soc/qcom,msm-audio-apr/qcom,q6core-audio/msm_cdc_pinctrl_sen or bad phandle (referred from qcom,sen-mi2s-gpios[0])
  also defined at arch/arm64/boot/dts/somc/../qcom/lahaina-audio-overlay.dtsi:286.14-385.3
  also defined at arch/arm64/boot/dts/somc/../qcom/lahaina-mtp.dtsi:149.14-151.3
  also defined at arch/arm64/boot/dts/somc/lahaina-sagami-common.dtsi:1045.14-1108.3
  UPD     scripts/mod/devicetable-offsets.h
  HOSTCC  scripts/mod/file2alias.o
  HOSTLD  scripts/mod/modpost
  CC      kernel/bounds.s
  CALL    scripts/atomic/check-atomics.sh
  UPD     include/generated/timeconst.h
  UPD     include/generated/bounds.h
  CC      arch/arm64/kernel/asm-offsets.s
In file included from arch/arm64/kernel/asm-offsets.c:16:
In file included from ./include/linux/suspend.h:5:
In file included from ./include/linux/swap.h:9:
./include/linux/memcontrol.h:959:1: error: expected identifier or '('
{
^
1 error generated.
make[1]: *** [scripts/Makefile.build:104: arch/arm64/kernel/asm-offsets.s] Error 1
make: *** [Makefile:1220: prepare0] Error 2
@jerpelea
Copy link
Collaborator

jerpelea commented Dec 9, 2022

I will try to replicate the error.
If you remove the include does it compile clean ?

Please try the compiler included in AOSP

Best regards
Alin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants