Hi Sakari, I love your patch! Perhaps something to improve: [auto build test WARNING on media-tree/master] [also build test WARNING on v5.17-rc1 next-20220124] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Sakari-Ailus/Set-bus_info-field-in-framework/20220123-004134 base: git://linuxtv.org/media_tree.git master config: mips-randconfig-r036-20220124 (https://download.01.org/0day-ci/archive/20220125/202201250515.dkk038WS-lkp@intel.com/config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 2e58a18910867ba6795066e044293e6daf89edf5) reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # install mips cross compiling tool for clang build # apt-get install binutils-mips-linux-gnu # https://github.com/0day-ci/linux/commit/512d690d3258afe250b666da9ee728ae54877083 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Sakari-Ailus/Set-bus_info-field-in-framework/20220123-004134 git checkout 512d690d3258afe250b666da9ee728ae54877083 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash drivers/media/platform/allegro-dvt/ drivers/media/platform/exynos-gsc/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): >> drivers/media/platform/allegro-dvt/allegro-core.c:3253:22: warning: unused variable 'dev' struct allegro_dev = video_get_drvdata(vdev); ^ fatal error: error in backend: Nested variants found in inline asm string: ' .set push .set noat .set push .set arch=r4000 .if ( 0x00 ) != -1)) 0x00 ) != -1)) : ($( static struct ftrace_branch_data __attribute__((__aligned__(4))) __attribute__((__section__("_ftrace_branch"))) __if_trace = $( .func = __func__, .file = "arch/mips/include/asm/cmpxchg.h", .line = 163, $); 0x00 ) != -1)) : $))) ) && ( 0 ); .set push; .set mips64r2; .rept 1; sync 0x00; .endr; .set pop; .else; ; .endif 1: ll $0, $2 # __cmpxchg_asm bne $0, ${3:z}, 2f .set pop move $$1, ${4:z} .set arch=r4000 sc $$1, $1 beqz $$1, 1b .set pop 2: .if ( 0x00 ) != -1)) 0x00 ) != -1)) : ($( static struct ftrace_branch_data __attribute__((__aligned__(4))) __attribute__((__section__("_ftrace_branch"))) __if_trace = $( .func = __func__, .file = "arch/mips/include/asm/cmpxchg.h", .line = 163, $); 0x00 ) != -1)) : $))) ) && ( 0 ); .set push; .set mips64r2; .rept 1; sync 0x00; .endr; .set pop; .else; ; .endif ' PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang -Wp,-MMD,drivers/media/platform/allegro-dvt/.allegro-core.o.d -nostdinc -Iarch/mips/include -I./arch/mips/include/generated -Iinclude -I./include -Iarch/mips/include/uapi -I./arch/mips/include/generated/uapi -Iinclude/uapi -I./include/generated/uapi -include include/linux/compiler-version.h -include include/linux/kconfig.h -include include/linux/compiler_types.h -D__KERNEL__ -DVMLINUX_LOAD_ADDRESS=0xffffffff80100000 -DLINKER_LOAD_ADDRESS=0x80100000 -DDATAOFFSET=0 -Qunused-arguments -fmacro-prefix-map== -DKBUILD_EXTRA_WARN1 -Wall -Wundef -Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -Werror=implicit-function-declaration -Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 --target=mipsel-linux -fintegrated-as -Werror=unknown-warning-option -Werror=ignored-optimization-argument -mno-check-zero-division -mabi=32 -G 0 -mno-abicalls -fno-pic -pipe -msoft-float -DGAS_HAS_SET_HARDFLOAT -Wa,-msoft-float -ffreestanding -EL -fno-stack-check -march=mips32 -Wa,--trap -DTOOLCHAIN_SUPPORTS_VIRT -Iarch/mips/include/asm/mach-generic -Iarch/mips/include/asm/mach-generic -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -Wno-frame-address -Wno-address-of-packed-member -O2 -Wframe-larger-than=1024 -fno-stack-protector -Wimplicit-fallthrough -Wno-gnu -mno-global-merge -Wno-unused-but-set-variable -Wno-unused-const-variable -ftrivial-auto-var-init=pattern -fno-stack-clash-protection -pg -Wdeclaration-after-statement -Wvla -Wno-pointer-sign -Wno-array-bounds -fno-strict-overflow -fno-stack-check -Werror=date-time -Werror=incompatible-pointer-types -Wextra -Wunused -Wno-unused-parameter -Wmissing-declarations -Wmissing-format-attribute -Wmissing-prototypes -Wold-style-definition -Wmissing-include-dirs -Wunused-but-set-variable -Wunused-const-variable -Wno-missing-field-initializers -Wno-sign-compare -Wno-type-limits -I drivers/media/platform/allegro-dvt -I ./drivers/media/platform/allegro-dvt -DKBUILD_MODFILE="drivers/media/platform/allegro-dvt/allegro" -DKBUILD_BASENAME="allegro_core" -DKBUILD_MODNAME="allegro" -D__KBUILD_MODNAME=kmod_allegro -c -o drivers/media/platform/allegro-dvt/allegro-core.o drivers/media/platform/allegro-dvt/allegro-core.c 1. parser at end of file 2. Code generation 3. Running pass 'Function Pass Manager' on module 'drivers/media/platform/allegro-dvt/allegro-core.c'. 4. Running pass 'Mips Assembly Printer' on function '@pm_runtime_resume_and_get' #0 0x000055cb759f39ef Signals.cpp:0:0 #1 0x000055cb759f18cc llvm::sys::CleanupOnSignal(unsigned long) (/opt/cross/clang-2e58a18910/bin/clang-14+0x34288cc) #2 0x000055cb759317d7 llvm::CrashRecoveryContext::HandleExit(int) (/opt/cross/clang-2e58a18910/bin/clang-14+0x33687d7) #3 0x000055cb759e9f7e llvm::sys::Process::Exit(int, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3420f7e) #4 0x000055cb73653dcb (/opt/cross/clang-2e58a18910/bin/clang-14+0x108adcb) #5 0x000055cb7593828c llvm::report_fatal_error(llvm::Twine const&, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x336f28c) #6 0x000055cb7661bd77 llvm::AsmPrinter::emitInlineAsm(llvm::MachineInstr const (/opt/cross/clang-2e58a18910/bin/clang-14+0x4052d77) #7 0x000055cb76617cd4 llvm::AsmPrinter::emitFunctionBody() (/opt/cross/clang-2e58a18910/bin/clang-14+0x404ecd4) #8 0x000055cb740b6d07 llvm::MipsAsmPrinter::runOnMachineFunction(llvm::MachineFunction&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x1aedd07) #9 0x000055cb74d5bbfd llvm::MachineFunctionPass::runOnFunction(llvm::Function&) (.part.53) MachineFunctionPass.cpp:0:0 #10 0x000055cb751947b7 llvm::FPPassManager::runOnFunction(llvm::Function&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bcb7b7) #11 0x000055cb75194931 llvm::FPPassManager::runOnModule(llvm::Module&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bcb931) #12 0x000055cb75195c0f llvm::legacy::PassManagerImpl::run(llvm::Module&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bccc0f) #13 0x000055cb75d03607 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::StringRef, clang::BackendAction, std::unique_ptr >) (/opt/cross/clang-2e58a18910/bin/clang-14+0x373a607) #14 0x000055cb76933c03 clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x436ac03) #15 0x000055cb7743e539 clang::ParseAST(clang::Sema&, bool, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x4e75539) #16 0x000055cb76932a4f clang::CodeGenAction::ExecuteAction() (/opt/cross/clang-2e58a18910/bin/clang-14+0x4369a4f) #17 0x000055cb76332591 clang::FrontendAction::Execute() (/opt/cross/clang-2e58a18910/bin/clang-14+0x3d69591) #18 0x000055cb762c9c1a clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3d00c1a) #19 0x000055cb763f66fb (/opt/cross/clang-2e58a18910/bin/clang-14+0x3e2d6fb) #20 0x000055cb73654b14 cc1_main(llvm::ArrayRef::callback_fn >, std::__cxx11::basic_string, std::allocator const::'lambda'()>(long) Job.cpp:0:0 #23 0x000055cb75931693 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3368693) #24 0x000055cb76165a8e clang::driver::CC1Command::Execute(llvm::ArrayRef >, std::__cxx11::basic_string, std::allocator const (.part.216) Job.cpp:0:0 #25 0x000055cb7613c167 clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b73167) #26 0x000055cb7613cb47 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl&) const (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b73b47) #27 0x000055cb761464b9 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b7d4b9) #28 0x000055cb7357c45f main (/opt/cross/clang-2e58a18910/bin/clang-14+0xfb345f) #29 0x00007f8bd5928d0a __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x26d0a) #30 0x000055cb73651b7a _start (/opt/cross/clang-2e58a18910/bin/clang-14+0x1088b7a) clang-14: error: clang frontend command failed with exit code 70 (use -v to see invocation) clang version 14.0.0 (git://gitmirror/llvm_project 2e58a18910867ba6795066e044293e6daf89edf5) Target: mipsel-unknown-linux Thread model: posix InstalledDir: /opt/cross/clang-2e58a18910/bin clang-14: note: diagnostic msg: Makefile arch drivers include kernel nr_bisected scripts source usr -- >> drivers/media/platform/exynos-gsc/gsc-m2m.c:289:18: warning: unused variable 'gsc' struct gsc_dev = ctx->gsc_dev; ^ fatal error: error in backend: Nested variants found in inline asm string: ' .set push .set mips64r2 .if ( 0x00 ) != -1)) 0x00 ) != -1)) : ($( static struct ftrace_branch_data __attribute__((__aligned__(4))) __attribute__((__section__("_ftrace_branch"))) __if_trace = $( .func = __func__, .file = "arch/mips/include/asm/bitops.h", .line = 105, $); 0x00 ) != -1)) : $))) ) && ( 0 ); .set push; .set mips64r2; .rept 1; sync 0x00; .endr; .set pop; .else; ; .endif 1: ll $0, $1 or $0, $2 sc $0, $1 beqz $0, 1b .set pop ' PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang -Wp,-MMD,drivers/media/platform/exynos-gsc/.gsc-m2m.o.d -nostdinc -Iarch/mips/include -I./arch/mips/include/generated -Iinclude -I./include -Iarch/mips/include/uapi -I./arch/mips/include/generated/uapi -Iinclude/uapi -I./include/generated/uapi -include include/linux/compiler-version.h -include include/linux/kconfig.h -include include/linux/compiler_types.h -D__KERNEL__ -DVMLINUX_LOAD_ADDRESS=0xffffffff80100000 -DLINKER_LOAD_ADDRESS=0x80100000 -DDATAOFFSET=0 -Qunused-arguments -fmacro-prefix-map== -DKBUILD_EXTRA_WARN1 -Wall -Wundef -Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -Werror=implicit-function-declaration -Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 --target=mipsel-linux -fintegrated-as -Werror=unknown-warning-option -Werror=ignored-optimization-argument -mno-check-zero-division -mabi=32 -G 0 -mno-abicalls -fno-pic -pipe -msoft-float -DGAS_HAS_SET_HARDFLOAT -Wa,-msoft-float -ffreestanding -EL -fno-stack-check -march=mips32 -Wa,--trap -DTOOLCHAIN_SUPPORTS_VIRT -Iarch/mips/include/asm/mach-generic -Iarch/mips/include/asm/mach-generic -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -Wno-frame-address -Wno-address-of-packed-member -O2 -Wframe-larger-than=1024 -fno-stack-protector -Wimplicit-fallthrough -Wno-gnu -mno-global-merge -Wno-unused-but-set-variable -Wno-unused-const-variable -ftrivial-auto-var-init=pattern -fno-stack-clash-protection -pg -Wdeclaration-after-statement -Wvla -Wno-pointer-sign -Wno-array-bounds -fno-strict-overflow -fno-stack-check -Werror=date-time -Werror=incompatible-pointer-types -Wextra -Wunused -Wno-unused-parameter -Wmissing-declarations -Wmissing-format-attribute -Wmissing-prototypes -Wold-style-definition -Wmissing-include-dirs -Wunused-but-set-variable -Wunused-const-variable -Wno-missing-field-initializers -Wno-sign-compare -Wno-type-limits -I drivers/media/platform/exynos-gsc -I ./drivers/media/platform/exynos-gsc -DKBUILD_MODFILE="drivers/media/platform/exynos-gsc/exynos-gsc" -DKBUILD_BASENAME="gsc_m2m" -DKBUILD_MODNAME="exynos_gsc" -D__KBUILD_MODNAME=kmod_exynos_gsc -c -o drivers/media/platform/exynos-gsc/gsc-m2m.o drivers/media/platform/exynos-gsc/gsc-m2m.c 1. parser at end of file 2. Code generation 3. Running pass 'Function Pass Manager' on module 'drivers/media/platform/exynos-gsc/gsc-m2m.c'. 4. Running pass 'Mips Assembly Printer' on function '@gsc_m2m_open' #0 0x0000560afb7049ef Signals.cpp:0:0 #1 0x0000560afb7028cc llvm::sys::CleanupOnSignal(unsigned long) (/opt/cross/clang-2e58a18910/bin/clang-14+0x34288cc) #2 0x0000560afb6427d7 llvm::CrashRecoveryContext::HandleExit(int) (/opt/cross/clang-2e58a18910/bin/clang-14+0x33687d7) #3 0x0000560afb6faf7e llvm::sys::Process::Exit(int, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3420f7e) #4 0x0000560af9364dcb (/opt/cross/clang-2e58a18910/bin/clang-14+0x108adcb) #5 0x0000560afb64928c llvm::report_fatal_error(llvm::Twine const&, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x336f28c) #6 0x0000560afc32cd77 llvm::AsmPrinter::emitInlineAsm(llvm::MachineInstr const (/opt/cross/clang-2e58a18910/bin/clang-14+0x4052d77) #7 0x0000560afc328cd4 llvm::AsmPrinter::emitFunctionBody() (/opt/cross/clang-2e58a18910/bin/clang-14+0x404ecd4) #8 0x0000560af9dc7d07 llvm::MipsAsmPrinter::runOnMachineFunction(llvm::MachineFunction&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x1aedd07) #9 0x0000560afaa6cbfd llvm::MachineFunctionPass::runOnFunction(llvm::Function&) (.part.53) MachineFunctionPass.cpp:0:0 #10 0x0000560afaea57b7 llvm::FPPassManager::runOnFunction(llvm::Function&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bcb7b7) #11 0x0000560afaea5931 llvm::FPPassManager::runOnModule(llvm::Module&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bcb931) #12 0x0000560afaea6c0f llvm::legacy::PassManagerImpl::run(llvm::Module&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x2bccc0f) #13 0x0000560afba14607 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::StringRef, clang::BackendAction, std::unique_ptr >) (/opt/cross/clang-2e58a18910/bin/clang-14+0x373a607) #14 0x0000560afc644c03 clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x436ac03) #15 0x0000560afd14f539 clang::ParseAST(clang::Sema&, bool, bool) (/opt/cross/clang-2e58a18910/bin/clang-14+0x4e75539) #16 0x0000560afc643a4f clang::CodeGenAction::ExecuteAction() (/opt/cross/clang-2e58a18910/bin/clang-14+0x4369a4f) #17 0x0000560afc043591 clang::FrontendAction::Execute() (/opt/cross/clang-2e58a18910/bin/clang-14+0x3d69591) #18 0x0000560afbfdac1a clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3d00c1a) #19 0x0000560afc1076fb (/opt/cross/clang-2e58a18910/bin/clang-14+0x3e2d6fb) #20 0x0000560af9365b14 cc1_main(llvm::ArrayRef::callback_fn >, std::__cxx11::basic_string, std::allocator const::'lambda'()>(long) Job.cpp:0:0 #23 0x0000560afb642693 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3368693) #24 0x0000560afbe76a8e clang::driver::CC1Command::Execute(llvm::ArrayRef >, std::__cxx11::basic_string, std::allocator const (.part.216) Job.cpp:0:0 #25 0x0000560afbe4d167 clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b73167) #26 0x0000560afbe4db47 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl&) const (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b73b47) #27 0x0000560afbe574b9 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl&) (/opt/cross/clang-2e58a18910/bin/clang-14+0x3b7d4b9) #28 0x0000560af928d45f main (/opt/cross/clang-2e58a18910/bin/clang-14+0xfb345f) #29 0x00007f5f10baed0a __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x26d0a) #30 0x0000560af9362b7a _start (/opt/cross/clang-2e58a18910/bin/clang-14+0x1088b7a) clang-14: error: clang frontend command failed with exit code 70 (use -v to see invocation) clang version 14.0.0 (git://gitmirror/llvm_project 2e58a18910867ba6795066e044293e6daf89edf5) Target: mipsel-unknown-linux Thread model: posix InstalledDir: /opt/cross/clang-2e58a18910/bin clang-14: note: diagnostic msg: Makefile arch drivers include kernel nr_bisected scripts source usr vim +/dev +3253 drivers/media/platform/allegro-dvt/allegro-core.c f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3248 f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3249 static int allegro_querycap(struct file *file, void *fh, f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3250 struct v4l2_capability *cap) f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3251 { f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3252 struct video_device *vdev = video_devdata(file); f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 @3253 struct allegro_dev *dev = video_get_drvdata(vdev); f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3254 f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3255 strscpy(cap->driver, KBUILD_MODNAME, sizeof(cap->driver)); f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3256 strscpy(cap->card, "Allegro DVT Video Encoder", sizeof(cap->card)); f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3257 f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3258 return 0; f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3259 } f20387dfd06569 drivers/staging/media/allegro-dvt/allegro-core.c Michael Tretter 2019-05-28 3260 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org