ID Workflow Result Correct Bug Created Started Finished Revision
a710f326 repro-c Reproduced: ✅ ❓ BUG: unable to handle kernel paging request in iowrite32 2026/08/10 07:52 2026/08/10 08:20 2026/08/10 08:47 5d63f80b
Agent: prod-syz-agent-1
External Bug ID: ---

Inputs:
BaseBranch master
BaseCommit RC
BaseRepository git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
BugTitle BUG: unable to handle kernel paging request in iowrite32
CrashLogID 5509095265665024
CrashReportID 6457757022027776
KernelCommit 562bfb501c54a4d676528fbb70552f520fe6603b
KernelConfig
Show (280572 bytes)
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86_64 syzkaller Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77)"
CONFIG_GCC_VERSION=0
CONFIG_CC_IS_CLANG=y
CONFIG_CLANG_VERSION=220108
CONFIG_AS_IS_LLVM=y
CONFIG_AS_VERSION=220108
CONFIG_LD_VERSION=0
CONFIG_LD_IS_LLD=y
CONFIG_LLD_VERSION=220108
CONFIG_RUSTC_VERSION=109600
CONFIG_RUST_IS_AVAILABLE=y
CONFIG_RUSTC_LLVM_VERSION=220102
CONFIG_RUSTC_LLVM_MAJOR_VERSION=22
CONFIG_RUSTC_CLANG_LLVM_COMPATIBLE=y
CONFIG_CC_CAN_LINK=y
CONFIG_CC_HAS_ASM_GOTO_OUTPUT=y
CONFIG_CC_HAS_ASM_GOTO_TIED_OUTPUT=y
CONFIG_TOOLS_SUPPORT_RELR=y
CONFIG_CC_HAS_ASM_INLINE=y
CONFIG_CC_HAS_ASSUME=y
CONFIG_CC_HAS_NO_PROFILE_FN_ATTR=y
CONFIG_CC_HAS_COUNTED_BY=y
CONFIG_CC_HAS_COUNTED_BY_PTR=y
CONFIG_CC_HAS_ALLOC_TOKEN=y
CONFIG_CC_HAS_MULTIDIMENSIONAL_NONSTRING=y
CONFIG_LD_CAN_USE_KEEP_IN_OVERLAY=y
CONFIG_RUSTC_HAS_SPAN_FILE=y
CONFIG_RUSTC_HAS_UNNECESSARY_TRANSMUTES=y
CONFIG_RUSTC_HAS_FILE_WITH_NUL=y
CONFIG_RUSTC_HAS_FILE_AS_C_STR=y
CONFIG_PAHOLE_VERSION=130
CONFIG_CONSTRUCTORS=y
CONFIG_IRQ_WORK=y
CONFIG_BUILDTIME_TABLE_SORT=y
CONFIG_THREAD_INFO_IN_TASK=y

#
# General setup
#
CONFIG_INIT_ENV_ARG_LIMIT=32
# CONFIG_COMPILE_TEST is not set
# CONFIG_WERROR is not set
CONFIG_LOCALVERSION=""
CONFIG_LOCALVERSION_AUTO=y
CONFIG_BUILD_SALT=""
CONFIG_HAVE_KERNEL_GZIP=y
CONFIG_HAVE_KERNEL_BZIP2=y
CONFIG_HAVE_KERNEL_LZMA=y
CONFIG_HAVE_KERNEL_XZ=y
CONFIG_HAVE_KERNEL_LZO=y
CONFIG_HAVE_KERNEL_LZ4=y
CONFIG_HAVE_KERNEL_ZSTD=y
CONFIG_KERNEL_GZIP=y
# CONFIG_KERNEL_BZIP2 is not set
# CONFIG_KERNEL_LZMA is not set
# CONFIG_KERNEL_XZ is not set
# CONFIG_KERNEL_LZO is not set
# CONFIG_KERNEL_LZ4 is not set
# CONFIG_KERNEL_ZSTD is not set
CONFIG_DEFAULT_INIT=""
CONFIG_DEFAULT_HOSTNAME="(none)"
CONFIG_SYSVIPC=y
CONFIG_SYSVIPC_SYSCTL=y
CONFIG_SYSVIPC_COMPAT=y
CONFIG_POSIX_MQUEUE=y
CONFIG_POSIX_MQUEUE_SYSCTL=y
CONFIG_WATCH_QUEUE=y
CONFIG_CROSS_MEMORY_ATTACH=y
CONFIG_AUDIT=y
CONFIG_HAVE_ARCH_AUDITSYSCALL=y
CONFIG_AUDITSYSCALL=y

#
# IRQ subsystem
#
CONFIG_GENERIC_IRQ_PROBE=y
CONFIG_GENERIC_IRQ_SHOW=y
CONFIG_GENERIC_IRQ_EFFECTIVE_AFF_MASK=y
CONFIG_GENERIC_PENDING_IRQ=y
CONFIG_GENERIC_IRQ_MIGRATION=y
CONFIG_HARDIRQS_SW_RESEND=y
CONFIG_IRQ_DOMAIN=y
CONFIG_IRQ_DOMAIN_HIERARCHY=y
CONFIG_GENERIC_MSI_IRQ=y
CONFIG_GENERIC_IRQ_MATRIX_ALLOCATOR=y
CONFIG_GENERIC_IRQ_RESERVATION_MODE=y
CONFIG_IRQ_FORCED_THREADING=y
CONFIG_SPARSE_IRQ=y
# CONFIG_GENERIC_IRQ_DEBUGFS is not set
# end of IRQ subsystem

CONFIG_CLOCKSOURCE_WATCHDOG=y
CONFIG_ARCH_CLOCKSOURCE_INIT=y
CONFIG_ARCH_WANTS_CLOCKSOURCE_READ_INLINE=y
CONFIG_GENERIC_CLOCKEVENTS=y
CONFIG_GENERIC_CLOCKEVENTS_BROADCAST=y
CONFIG_GENERIC_CLOCKEVENTS_BROADCAST_IDLE=y
CONFIG_GENERIC_CLOCKEVENTS_MIN_ADJUST=y
CONFIG_GENERIC_CLOCKEVENTS_COUPLED=y
CONFIG_GENERIC_CLOCKEVENTS_COUPLED_INLINE=y
CONFIG_GENERIC_CMOS_UPDATE=y
CONFIG_HRTIMER_REARM_DEFERRED=y
CONFIG_HAVE_POSIX_CPU_TIMERS_TASK_WORK=y
CONFIG_POSIX_CPU_TIMERS_TASK_WORK=y
CONFIG_CONTEXT_TRACKING=y
CONFIG_CONTEXT_TRACKING_IDLE=y

#
# Timers subsystem
#
CONFIG_TICK_ONESHOT=y
CONFIG_NO_HZ_COMMON=y
# CONFIG_HZ_PERIODIC is not set
CONFIG_NO_HZ_IDLE=y
# CONFIG_NO_HZ_FULL is not set
CONFIG_CONTEXT_TRACKING_USER=y
# CONFIG_CONTEXT_TRACKING_USER_FORCE is not set
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
CONFIG_POSIX_AUX_CLOCKS=y
# end of Timers subsystem

CONFIG_BPF=y
CONFIG_HAVE_EBPF_JIT=y
CONFIG_ARCH_WANT_DEFAULT_BPF_JIT=y

#
# BPF subsystem
#
CONFIG_BPF_SYSCALL=y
CONFIG_BPF_JIT=y
CONFIG_BPF_JIT_ALWAYS_ON=y
CONFIG_BPF_JIT_DEFAULT_ON=y
# CONFIG_BPF_UNPRIV_DEFAULT_OFF is not set
CONFIG_BPF_PRELOAD=y
CONFIG_BPF_PRELOAD_UMD=y
CONFIG_BPF_LSM=y
# end of BPF subsystem

CONFIG_PREEMPT_BUILD=y
CONFIG_ARCH_HAS_PREEMPT_LAZY=y
CONFIG_PREEMPT=y
# CONFIG_PREEMPT_LAZY is not set
# CONFIG_PREEMPT_RT is not set
CONFIG_PREEMPT_COUNT=y
CONFIG_PREEMPTION=y
CONFIG_PREEMPT_DYNAMIC=y
CONFIG_SCHED_CORE=y

#
# CPU/Task time and stats accounting
#
CONFIG_VIRT_CPU_ACCOUNTING=y
# CONFIG_TICK_CPU_ACCOUNTING is not set
CONFIG_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_IRQ_TIME_ACCOUNTING=y
CONFIG_HAVE_SCHED_AVG_IRQ=y
CONFIG_BSD_PROCESS_ACCT=y
CONFIG_BSD_PROCESS_ACCT_V3=y
CONFIG_TASKSTATS=y
CONFIG_TASK_DELAY_ACCT=y
CONFIG_TASK_XACCT=y
CONFIG_TASK_IO_ACCOUNTING=y
CONFIG_PSI=y
# CONFIG_PSI_DEFAULT_DISABLED is not set
# end of CPU/Task time and stats accounting

CONFIG_CPU_ISOLATION=y

#
# RCU Subsystem
#
CONFIG_TREE_RCU=y
CONFIG_PREEMPT_RCU=y
# CONFIG_RCU_EXPERT is not set
CONFIG_TREE_SRCU=y
CONFIG_TASKS_RCU_GENERIC=y
CONFIG_NEED_TASKS_RCU=y
CONFIG_TASKS_RCU=y
CONFIG_TASKS_TRACE_RCU=y
CONFIG_RCU_STALL_COMMON=y
CONFIG_RCU_NEED_SEGCBLIST=y
# end of RCU Subsystem

CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y
# CONFIG_IKHEADERS is not set
CONFIG_LOG_BUF_SHIFT=18
CONFIG_LOG_CPU_MAX_BUF_SHIFT=12
# CONFIG_PRINTK_INDEX is not set
CONFIG_HAVE_UNSTABLE_SCHED_CLOCK=y

#
# Scheduler features
#
# CONFIG_UCLAMP_TASK is not set
# CONFIG_SCHED_PROXY_EXEC is not set
# end of Scheduler features

CONFIG_ARCH_SUPPORTS_NUMA_BALANCING=y
CONFIG_ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH=y
CONFIG_CC_HAS_INT128=y
CONFIG_CC_IMPLICIT_FALLTHROUGH="-Wimplicit-fallthrough"
CONFIG_CC_MS_EXTENSIONS="-fms-extensions"
CONFIG_GCC10_NO_ARRAY_BOUNDS=y
CONFIG_GCC_NO_STRINGOP_OVERFLOW=y
CONFIG_ARCH_SUPPORTS_INT128=y
CONFIG_NUMA_BALANCING=y
CONFIG_SCHED_CACHE=y
CONFIG_NUMA_BALANCING_DEFAULT_ENABLED=y
CONFIG_SLAB_OBJ_EXT=y
CONFIG_CGROUPS=y
CONFIG_PAGE_COUNTER=y
# CONFIG_CGROUP_FAVOR_DYNMODS is not set
CONFIG_MEMCG=y
CONFIG_MEMCG_V1=y
CONFIG_BLK_CGROUP=y
CONFIG_CGROUP_WRITEBACK=y
CONFIG_CGROUP_SCHED=y
CONFIG_GROUP_SCHED_WEIGHT=y
CONFIG_GROUP_SCHED_BANDWIDTH=y
CONFIG_FAIR_GROUP_SCHED=y
CONFIG_CFS_BANDWIDTH=y
# CONFIG_RT_GROUP_SCHED is not set
CONFIG_SCHED_MM_CID=y
CONFIG_CGROUP_PIDS=y
CONFIG_CGROUP_RDMA=y
# CONFIG_CGROUP_DMEM is not set
CONFIG_CGROUP_FREEZER=y
CONFIG_CGROUP_HUGETLB=y
CONFIG_CPUSETS=y
# CONFIG_CPUSETS_V1 is not set
CONFIG_CGROUP_DEVICE=y
CONFIG_CGROUP_CPUACCT=y
CONFIG_CGROUP_PERF=y
CONFIG_CGROUP_BPF=y
CONFIG_CGROUP_MISC=y
CONFIG_CGROUP_DEBUG=y
CONFIG_SOCK_CGROUP_DATA=y
CONFIG_NAMESPACES=y
CONFIG_UTS_NS=y
CONFIG_TIME_NS=y
CONFIG_TIME_NS_VDSO=y
CONFIG_IPC_NS=y
CONFIG_USER_NS=y
CONFIG_PID_NS=y
CONFIG_NET_NS=y
CONFIG_CHECKPOINT_RESTORE=y
# CONFIG_SCHED_AUTOGROUP is not set
CONFIG_RELAY=y
CONFIG_BLK_DEV_INITRD=y
CONFIG_INITRAMFS_SOURCE=""
CONFIG_RD_GZIP=y
CONFIG_RD_BZIP2=y
CONFIG_RD_LZMA=y
CONFIG_RD_XZ=y
CONFIG_RD_LZO=y
CONFIG_RD_LZ4=y
CONFIG_RD_ZSTD=y
# CONFIG_BOOT_CONFIG is not set
CONFIG_CMDLINE_LOG_WRAP_IDEAL_LEN=1021
CONFIG_INITRAMFS_PRESERVE_MTIME=y
CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE=y
# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
CONFIG_LD_ORPHAN_WARN=y
CONFIG_LD_ORPHAN_WARN_LEVEL="warn"
CONFIG_SYSCTL=y
CONFIG_HAVE_UID16=y
CONFIG_SYSCTL_EXCEPTION_TRACE=y
CONFIG_SYSFS_SYSCALL=y
CONFIG_HAVE_PCSPKR_PLATFORM=y
CONFIG_EXPERT=y
CONFIG_UID16=y
CONFIG_MULTIUSER=y
CONFIG_SGETMASK_SYSCALL=y
CONFIG_FHANDLE=y
CONFIG_POSIX_TIMERS=y
CONFIG_PRINTK=y
CONFIG_BUG=y
CONFIG_ELF_CORE=y
CONFIG_PCSPKR_PLATFORM=y
# CONFIG_BASE_SMALL is not set
CONFIG_FUTEX=y
CONFIG_FUTEX_PI=y
CONFIG_FUTEX_PRIVATE_HASH=y
CONFIG_FUTEX_MPOL=y
CONFIG_HAVE_FUTEX_ROBUST_UNLOCK=y
CONFIG_FUTEX_ROBUST_UNLOCK=y
CONFIG_EPOLL=y
CONFIG_SIGNALFD=y
CONFIG_TIMERFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_AIO=y
CONFIG_IO_URING=y
CONFIG_IO_URING_MOCK_FILE=y
CONFIG_ADVISE_SYSCALLS=y
CONFIG_MEMBARRIER=y
CONFIG_KCMP=y
CONFIG_RSEQ=y
CONFIG_RSEQ_SLICE_EXTENSION=y
# CONFIG_RSEQ_STATS is not set
# CONFIG_RSEQ_DEBUG_DEFAULT_ENABLE is not set
CONFIG_CACHESTAT_SYSCALL=y
CONFIG_KALLSYMS=y
# CONFIG_KALLSYMS_SELFTEST is not set
CONFIG_KALLSYMS_ALL=y
CONFIG_ARCH_HAS_MEMBARRIER_SYNC_CORE=y
CONFIG_ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS=y
CONFIG_HAVE_PERF_EVENTS=y
CONFIG_GUEST_PERF_EVENTS=y
CONFIG_PERF_GUEST_MEDIATED_PMU=y

#
# Kernel Performance Events And Counters
#
CONFIG_PERF_EVENTS=y
# CONFIG_DEBUG_PERF_USE_VMALLOC is not set
# end of Kernel Performance Events And Counters

CONFIG_SYSTEM_DATA_VERIFICATION=y
CONFIG_PROFILING=y
# CONFIG_RUST is not set
CONFIG_TRACEPOINTS=y

#
# Kexec and crash features
#
CONFIG_CRASH_RESERVE=y
CONFIG_VMCORE_INFO=y
CONFIG_KEXEC_CORE=y
CONFIG_KEXEC=y
# CONFIG_KEXEC_FILE is not set
# CONFIG_KEXEC_JUMP is not set
CONFIG_CRASH_DUMP=y
CONFIG_CRASH_HOTPLUG=y
CONFIG_CRASH_MAX_MEMORY_RANGES=8192
# end of Kexec and crash features

#
# Live Update and Kexec HandOver
#
# CONFIG_KEXEC_HANDOVER is not set
# end of Live Update and Kexec HandOver
# end of General setup

CONFIG_64BIT=y
CONFIG_X86_64=y
CONFIG_X86=y
CONFIG_INSTRUCTION_DECODER=y
CONFIG_OUTPUT_FORMAT="elf64-x86-64"
CONFIG_LOCKDEP_SUPPORT=y
CONFIG_STACKTRACE_SUPPORT=y
CONFIG_MMU=y
CONFIG_ARCH_MMAP_RND_BITS_MIN=28
CONFIG_ARCH_MMAP_RND_BITS_MAX=32
CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MIN=8
CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MAX=16
CONFIG_GENERIC_ISA_DMA=y
CONFIG_GENERIC_CSUM=y
CONFIG_GENERIC_BUG=y
CONFIG_GENERIC_BUG_RELATIVE_POINTERS=y
CONFIG_ARCH_MAY_HAVE_PC_FDC=y
CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_ARCH_HAS_CPU_RELAX=y
CONFIG_ARCH_HIBERNATION_POSSIBLE=y
CONFIG_ARCH_SUSPEND_POSSIBLE=y
CONFIG_AUDIT_ARCH=y
CONFIG_KASAN_SHADOW_OFFSET=0xdffffc0000000000
CONFIG_HAVE_INTEL_TXT=y
CONFIG_ARCH_SUPPORTS_UPROBES=y
CONFIG_FIX_EARLYCON_MEM=y
CONFIG_PGTABLE_LEVELS=5

#
# Processor type and features
#
CONFIG_SMP=y
CONFIG_X86_X2APIC=y
# CONFIG_X86_POSTED_MSI is not set
CONFIG_X86_MPPARSE=y
# CONFIG_X86_CPU_RESCTRL is not set
CONFIG_X86_FRED=y
CONFIG_X86_EXTENDED_PLATFORM=y
# CONFIG_X86_NUMACHIP is not set
# CONFIG_X86_VSMP is not set
# CONFIG_X86_INTEL_MID is not set
# CONFIG_X86_GOLDFISH is not set
# CONFIG_X86_INTEL_LPSS is not set
# CONFIG_X86_AMD_PLATFORM_DEVICE is not set
CONFIG_IOSF_MBI=y
# CONFIG_IOSF_MBI_DEBUG is not set
CONFIG_X86_SUPPORTS_MEMORY_FAILURE=y
CONFIG_SCHED_OMIT_FRAME_POINTER=y
CONFIG_HYPERVISOR_GUEST=y
CONFIG_PARAVIRT=y
CONFIG_PARAVIRT_SPINLOCKS=y
CONFIG_X86_HV_CALLBACK_VECTOR=y
# CONFIG_XEN is not set
CONFIG_KVM_GUEST=y
CONFIG_ARCH_CPUIDLE_HALTPOLL=y
CONFIG_PVH=y
# CONFIG_PARAVIRT_TIME_ACCOUNTING is not set
CONFIG_PARAVIRT_CLOCK=y
# CONFIG_JAILHOUSE_GUEST is not set
# CONFIG_ACRN_GUEST is not set
# CONFIG_BHYVE_GUEST is not set
CONFIG_CC_HAS_MARCH_NATIVE=y
# CONFIG_X86_NATIVE_CPU is not set
CONFIG_X86_INTERNODE_CACHE_SHIFT=6
CONFIG_X86_L1_CACHE_SHIFT=6
CONFIG_X86_TSC=y
CONFIG_X86_HAVE_PAE=y
CONFIG_X86_CX8=y
CONFIG_X86_CMOV=y
CONFIG_X86_MINIMUM_CPU_FAMILY=64
CONFIG_X86_DEBUGCTLMSR=y
CONFIG_IA32_FEAT_CTL=y
CONFIG_X86_VMX_FEATURE_NAMES=y
CONFIG_PROCESSOR_SELECT=y
CONFIG_CPU_SUP_INTEL=y
CONFIG_CPU_SUP_AMD=y
# CONFIG_CPU_SUP_HYGON is not set
# CONFIG_CPU_SUP_CENTAUR is not set
# CONFIG_CPU_SUP_ZHAOXIN is not set
CONFIG_BROADCAST_TLB_FLUSH=y
CONFIG_HPET_TIMER=y
CONFIG_HPET_EMULATE_RTC=y
CONFIG_DMI=y
# CONFIG_GART_IOMMU is not set
CONFIG_BOOT_VESA_SUPPORT=y
# CONFIG_MAXSMP is not set
CONFIG_NR_CPUS_RANGE_BEGIN=2
CONFIG_NR_CPUS_RANGE_END=512
CONFIG_NR_CPUS_DEFAULT=64
CONFIG_NR_CPUS=8
CONFIG_SCHED_MC_PRIO=y
CONFIG_X86_LOCAL_APIC=y
CONFIG_ACPI_MADT_WAKEUP=y
CONFIG_X86_IO_APIC=y
CONFIG_X86_REROUTE_FOR_BROKEN_BOOT_IRQS=y
CONFIG_X86_MCE=y
# CONFIG_X86_MCELOG_LEGACY is not set
CONFIG_X86_MCE_INTEL=y
CONFIG_X86_MCE_AMD=y
CONFIG_X86_MCE_THRESHOLD=y
# CONFIG_X86_MCE_INJECT is not set

#
# Performance monitoring
#
CONFIG_PERF_EVENTS_INTEL_UNCORE=y
CONFIG_PERF_EVENTS_INTEL_RAPL=y
CONFIG_PERF_EVENTS_INTEL_CSTATE=y
# CONFIG_PERF_EVENTS_AMD_POWER is not set
CONFIG_PERF_EVENTS_AMD_UNCORE=y
# CONFIG_PERF_EVENTS_AMD_BRS is not set
# end of Performance monitoring

CONFIG_X86_16BIT=y
CONFIG_X86_ESPFIX64=y
CONFIG_X86_VSYSCALL_EMULATION=y
CONFIG_X86_IOPL_IOPERM=y
CONFIG_MICROCODE=y
# CONFIG_MICROCODE_LATE_LOADING is not set
# CONFIG_MICROCODE_DBG is not set
CONFIG_X86_MSR=y
CONFIG_X86_CPUID=y
CONFIG_X86_DIRECT_GBPAGES=y
# CONFIG_X86_CPA_STATISTICS is not set
CONFIG_NUMA=y
CONFIG_AMD_NUMA=y
CONFIG_X86_64_ACPI_NUMA=y
CONFIG_NODES_SHIFT=6
CONFIG_ARCH_SPARSEMEM_ENABLE=y
CONFIG_ARCH_SPARSEMEM_DEFAULT=y
# CONFIG_ARCH_MEMORY_PROBE is not set
CONFIG_ARCH_PROC_KCORE_TEXT=y
CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000
# CONFIG_X86_PMEM_LEGACY is not set
# CONFIG_X86_CHECK_BIOS_CORRUPTION is not set
CONFIG_MTRR=y
# CONFIG_MTRR_SANITIZER is not set
CONFIG_X86_PAT=y
CONFIG_X86_UMIP=y
CONFIG_CC_HAS_IBT=y
CONFIG_X86_CET=y
CONFIG_X86_KERNEL_IBT=y
CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS=y
CONFIG_ARCH_PKEY_BITS=4
# CONFIG_X86_INTEL_TSX_MODE_OFF is not set
CONFIG_X86_INTEL_TSX_MODE_ON=y
# CONFIG_X86_INTEL_TSX_MODE_AUTO is not set
CONFIG_X86_SGX=y
CONFIG_X86_USER_SHADOW_STACK=y
# CONFIG_INTEL_TDX_HOST is not set
# CONFIG_EFI is not set
CONFIG_HZ_100=y
# CONFIG_HZ_250 is not set
# CONFIG_HZ_300 is not set
# CONFIG_HZ_1000 is not set
CONFIG_HZ=100
CONFIG_SCHED_HRTICK=y
CONFIG_ARCH_SUPPORTS_KEXEC=y
CONFIG_ARCH_SUPPORTS_KEXEC_FILE=y
CONFIG_ARCH_SUPPORTS_KEXEC_PURGATORY=y
CONFIG_ARCH_SUPPORTS_KEXEC_SIG=y
CONFIG_ARCH_SUPPORTS_KEXEC_SIG_FORCE=y
CONFIG_ARCH_SUPPORTS_KEXEC_BZIMAGE_VERIFY_SIG=y
CONFIG_ARCH_SUPPORTS_KEXEC_JUMP=y
CONFIG_ARCH_SUPPORTS_KEXEC_HANDOVER=y
CONFIG_ARCH_SUPPORTS_CRASH_DUMP=y
CONFIG_ARCH_DEFAULT_CRASH_DUMP=y
CONFIG_ARCH_SUPPORTS_CRASH_HOTPLUG=y
CONFIG_ARCH_HAS_GENERIC_CRASHKERNEL_RESERVATION=y
CONFIG_PHYSICAL_START=0x1000000
# CONFIG_RELOCATABLE is not set
CONFIG_PHYSICAL_ALIGN=0x200000
CONFIG_HOTPLUG_CPU=y
# CONFIG_COMPAT_VDSO is not set
CONFIG_LEGACY_VSYSCALL_XONLY=y
# CONFIG_LEGACY_VSYSCALL_NONE is not set
CONFIG_CMDLINE_BOOL=y
CONFIG_CMDLINE="earlyprintk=serial net.ifnames=0 sysctl.kernel.hung_task_all_cpu_backtrace=1 ima_policy=tcb nf-conntrack-ftp.ports=20000 nf-conntrack-tftp.ports=20000 nf-conntrack-sip.ports=20000 nf-conntrack-irc.ports=20000 nf-conntrack-sane.ports=20000 binder.debug_mask=0 rcupdate.rcu_expedited=1 rcupdate.rcu_cpu_stall_cputime=1 no_hash_pointers page_owner=on sysctl.vm.nr_hugepages=4 sysctl.vm.nr_overcommit_hugepages=4 secretmem.enable=1 sysctl.max_rcu_stall_to_panic=1 msr.allow_writes=off coredump_filter=0xffff root=/dev/sda console=ttyS0 vsyscall=native numa=fake=2 kvm-intel.nested=1 spec_store_bypass_disable=prctl nopcid vivid.n_devs=64 vivid.multiplanar=1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2,1,2 netrom.nr_ndevs=32 rose.rose_ndevs=32 smp.csd_lock_timeout=100000 watchdog_thresh=55 workqueue.watchdog_thresh=140 sysctl.net.core.netdev_unregister_timeout_secs=140 dummy_hcd.num=32 max_loop=32 nbds_max=32 comedi.comedi_num_legacy_minors=4 panic_on_warn=1"
# CONFIG_CMDLINE_OVERRIDE is not set
CONFIG_MODIFY_LDT_SYSCALL=y
# CONFIG_STRICT_SIGALTSTACK_SIZE is not set
CONFIG_HAVE_LIVEPATCH=y
CONFIG_HAVE_KLP_BUILD=y
CONFIG_X86_BUS_LOCK_DETECT=y
# end of Processor type and features

CONFIG_CC_HAS_SLS=y
CONFIG_CC_HAS_RETURN_THUNK=y
CONFIG_CC_HAS_ENTRY_PADDING=y
CONFIG_CC_HAS_KCFI_ARITY=y
CONFIG_FUNCTION_PADDING_CFI=11
CONFIG_FUNCTION_PADDING_BYTES=16
CONFIG_CALL_PADDING=y
CONFIG_HAVE_CALL_THUNKS=y
CONFIG_CALL_THUNKS=y
CONFIG_CPU_MITIGATIONS=y
CONFIG_MITIGATION_PAGE_TABLE_ISOLATION=y
CONFIG_MITIGATION_RETPOLINE=y
CONFIG_MITIGATION_RETHUNK=y
CONFIG_MITIGATION_UNRET_ENTRY=y
CONFIG_MITIGATION_CALL_DEPTH_TRACKING=y
# CONFIG_CALL_THUNKS_DEBUG is not set
CONFIG_MITIGATION_IBPB_ENTRY=y
CONFIG_MITIGATION_IBRS_ENTRY=y
CONFIG_MITIGATION_SRSO=y
# CONFIG_MITIGATION_SLS is not set
CONFIG_MITIGATION_GDS=y
CONFIG_MITIGATION_RFDS=y
CONFIG_MITIGATION_SPECTRE_BHI=y
CONFIG_MITIGATION_MDS=y
CONFIG_MITIGATION_TAA=y
CONFIG_MITIGATION_MMIO_STALE_DATA=y
CONFIG_MITIGATION_L1TF=y
CONFIG_MITIGATION_RETBLEED=y
CONFIG_MITIGATION_SPECTRE_V1=y
CONFIG_MITIGATION_SPECTRE_V2=y
CONFIG_MITIGATION_SRBDS=y
CONFIG_MITIGATION_SSB=y
CONFIG_MITIGATION_ITS=y
CONFIG_MITIGATION_TSA=y
# CONFIG_MITIGATION_VMSCAPE is not set
CONFIG_ARCH_HAS_ADD_PAGES=y

#
# Power management and ACPI options
#
CONFIG_ARCH_HIBERNATION_HEADER=y
CONFIG_SUSPEND=y
CONFIG_SUSPEND_FREEZER=y
# CONFIG_SUSPEND_SKIP_SYNC is not set
CONFIG_HIBERNATE_CALLBACKS=y
CONFIG_HIBERNATION=y
CONFIG_HIBERNATION_SNAPSHOT_DEV=y
CONFIG_HIBERNATION_COMP_LZO=y
# CONFIG_HIBERNATION_COMP_LZ4 is not set
CONFIG_HIBERNATION_DEF_COMP="lzo"
CONFIG_PM_STD_PARTITION=""
CONFIG_PM_SLEEP=y
CONFIG_PM_SLEEP_SMP=y
# CONFIG_PM_AUTOSLEEP is not set
# CONFIG_PM_USERSPACE_AUTOSLEEP is not set
# CONFIG_PM_WAKELOCKS is not set
# CONFIG_PM_QOS_CPU_SYSTEM_WAKEUP is not set
CONFIG_PM=y
CONFIG_PM_DEBUG=y
# CONFIG_PM_ADVANCED_DEBUG is not set
# CONFIG_PM_TEST_SUSPEND is not set
CONFIG_PM_SLEEP_DEBUG=y
# CONFIG_DPM_WATCHDOG is not set
CONFIG_PM_TRACE=y
CONFIG_PM_TRACE_RTC=y
CONFIG_PM_CLK=y
# CONFIG_WQ_POWER_EFFICIENT_DEFAULT is not set
# CONFIG_ENERGY_MODEL is not set
CONFIG_ARCH_SUPPORTS_ACPI=y
CONFIG_ACPI=y
CONFIG_ACPI_LEGACY_TABLES_LOOKUP=y
CONFIG_ARCH_MIGHT_HAVE_ACPI_PDC=y
CONFIG_ACPI_SYSTEM_POWER_STATES_SUPPORT=y
CONFIG_ACPI_THERMAL_LIB=y
# CONFIG_ACPI_DEBUGGER is not set
CONFIG_ACPI_SPCR_TABLE=y
# CONFIG_ACPI_FPDT is not set
CONFIG_ACPI_LPIT=y
CONFIG_ACPI_SLEEP=y
CONFIG_ACPI_REV_OVERRIDE_POSSIBLE=y
CONFIG_ACPI_EC=y
# CONFIG_ACPI_EC_DEBUGFS is not set
CONFIG_ACPI_AC=y
CONFIG_ACPI_BATTERY=y
CONFIG_ACPI_BUTTON=y
CONFIG_ACPI_VIDEO=y
CONFIG_ACPI_FAN=y
# CONFIG_ACPI_TAD is not set
CONFIG_ACPI_DOCK=y
CONFIG_ACPI_CPU_FREQ_PSS=y
CONFIG_ACPI_PROCESSOR_CSTATE=y
CONFIG_ACPI_PROCESSOR_IDLE=y
CONFIG_ACPI_CPPC_LIB=y
CONFIG_ACPI_PROCESSOR=y
CONFIG_ACPI_HOTPLUG_CPU=y
# CONFIG_ACPI_PROCESSOR_AGGREGATOR is not set
CONFIG_ACPI_THERMAL=y
CONFIG_ACPI_PLATFORM_PROFILE=y
CONFIG_ARCH_HAS_ACPI_TABLE_UPGRADE=y
CONFIG_ACPI_TABLE_UPGRADE=y
CONFIG_ACPI_DEBUG=y
# CONFIG_ACPI_PCI_SLOT is not set
CONFIG_ACPI_CONTAINER=y
# CONFIG_ACPI_HOTPLUG_MEMORY is not set
CONFIG_ACPI_HOTPLUG_IOAPIC=y
# CONFIG_ACPI_SBS is not set
# CONFIG_ACPI_HED is not set
# CONFIG_ACPI_REDUCED_HARDWARE_ONLY is not set
CONFIG_ACPI_NHLT=y
CONFIG_ACPI_NFIT=y
# CONFIG_NFIT_SECURITY_DEBUG is not set
CONFIG_ACPI_NUMA=y
# CONFIG_ACPI_HMAT is not set
CONFIG_HAVE_ACPI_APEI=y
CONFIG_HAVE_ACPI_APEI_NMI=y
# CONFIG_ACPI_APEI is not set
# CONFIG_ACPI_DPTF is not set
# CONFIG_ACPI_EXTLOG is not set
# CONFIG_ACPI_CONFIGFS is not set
# CONFIG_ACPI_PFRUT is not set
CONFIG_ACPI_PCC=y
# CONFIG_ACPI_FFH is not set
CONFIG_ACPI_MRRM=y
CONFIG_PMIC_OPREGION=y
CONFIG_BXT_WC_PMIC_OPREGION=y
# CONFIG_CHT_WC_PMIC_OPREGION is not set
CONFIG_X86_PM_TIMER=y

#
# CPU Frequency scaling
#
CONFIG_CPU_FREQ=y
CONFIG_CPU_FREQ_GOV_ATTR_SET=y
CONFIG_CPU_FREQ_GOV_COMMON=y
# CONFIG_CPU_FREQ_STAT is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set
CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y
# CONFIG_CPU_FREQ_DEFAULT_GOV_SCHEDUTIL is not set
CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
# CONFIG_CPU_FREQ_GOV_POWERSAVE is not set
CONFIG_CPU_FREQ_GOV_USERSPACE=y
CONFIG_CPU_FREQ_GOV_ONDEMAND=y
# CONFIG_CPU_FREQ_GOV_CONSERVATIVE is not set
CONFIG_CPU_FREQ_GOV_SCHEDUTIL=y

#
# CPU frequency scaling drivers
#
# CONFIG_CPUFREQ_DT is not set
# CONFIG_CPUFREQ_DT_PLATDEV is not set
CONFIG_X86_INTEL_PSTATE=y
# CONFIG_X86_PCC_CPUFREQ is not set
CONFIG_X86_AMD_PSTATE=y
CONFIG_X86_AMD_PSTATE_DEFAULT_MODE=3
# CONFIG_X86_AMD_PSTATE_UT is not set
CONFIG_X86_ACPI_CPUFREQ=y
CONFIG_X86_ACPI_CPUFREQ_CPB=y
# CONFIG_X86_POWERNOW_K8 is not set
# CONFIG_X86_AMD_FREQ_SENSITIVITY is not set
# CONFIG_X86_SPEEDSTEP_CENTRINO is not set
# CONFIG_X86_P4_CLOCKMOD is not set

#
# shared options
#
CONFIG_CPUFREQ_ARCH_CUR_FREQ=y
# end of CPU Frequency scaling

#
# CPU Idle
#
CONFIG_CPU_IDLE=y
# CONFIG_CPU_IDLE_GOV_LADDER is not set
CONFIG_CPU_IDLE_GOV_MENU=y
# CONFIG_CPU_IDLE_GOV_TEO is not set
CONFIG_CPU_IDLE_GOV_HALTPOLL=y
CONFIG_HALTPOLL_CPUIDLE=y
# end of CPU Idle

CONFIG_INTEL_IDLE=y
# end of Power management and ACPI options

#
# Bus options (PCI etc.)
#
CONFIG_PCI_DIRECT=y
CONFIG_PCI_MMCONFIG=y
CONFIG_MMCONF_FAM10H=y
CONFIG_ISA_BUS=y
CONFIG_ISA_DMA_API=y
CONFIG_AMD_NB=y
CONFIG_AMD_NODE=y
# end of Bus options (PCI etc.)

#
# Binary Emulations
#
CONFIG_IA32_EMULATION=y
# CONFIG_IA32_EMULATION_DEFAULT_DISABLED is not set
CONFIG_COMPAT_32=y
CONFIG_COMPAT=y
CONFIG_COMPAT_FOR_U64_ALIGNMENT=y
# end of Binary Emulations

CONFIG_KVM_COMMON=y
CONFIG_HAVE_KVM_PFNCACHE=y
CONFIG_HAVE_KVM_IRQCHIP=y
CONFIG_HAVE_KVM_IRQ_ROUTING=y
CONFIG_HAVE_KVM_DIRTY_RING=y
CONFIG_HAVE_KVM_DIRTY_RING_TSO=y
CONFIG_HAVE_KVM_DIRTY_RING_ACQ_REL=y
CONFIG_KVM_MMIO=y
CONFIG_KVM_ASYNC_PF=y
CONFIG_HAVE_KVM_MSI=y
CONFIG_HAVE_KVM_READONLY_MEM=y
CONFIG_HAVE_KVM_CPU_RELAX_INTERCEPT=y
CONFIG_KVM_VFIO=y
CONFIG_KVM_GENERIC_DIRTYLOG_READ_PROTECT=y
CONFIG_KVM_GENERIC_PRE_FAULT_MEMORY=y
CONFIG_KVM_COMPAT=y
CONFIG_HAVE_KVM_IRQ_BYPASS=y
CONFIG_HAVE_KVM_NO_POLL=y
CONFIG_VIRT_XFER_TO_GUEST_WORK=y
CONFIG_HAVE_KVM_PM_NOTIFIER=y
CONFIG_KVM_GENERIC_HARDWARE_ENABLING=y
CONFIG_KVM_ELIDE_TLB_FLUSH_IF_YOUNG=y
CONFIG_KVM_MMU_LOCKLESS_AGING=y
CONFIG_KVM_GENERIC_MEMORY_ATTRIBUTES=y
CONFIG_KVM_GUEST_MEMFD=y
CONFIG_VIRTUALIZATION=y
CONFIG_KVM_X86=y
CONFIG_KVM=y
CONFIG_KVM_SW_PROTECTED_VM=y
CONFIG_KVM_INTEL=y
# CONFIG_KVM_INTEL_PROVE_VE is not set
CONFIG_X86_SGX_KVM=y
CONFIG_KVM_AMD=y
CONFIG_KVM_IOAPIC=y
CONFIG_KVM_SMM=y
CONFIG_KVM_HYPERV=y
CONFIG_KVM_XEN=y
CONFIG_KVM_PROVE_MMU=y
CONFIG_KVM_MAX_NR_VCPUS=1024
CONFIG_X86_REQUIRED_FEATURE_ALWAYS=y
CONFIG_X86_REQUIRED_FEATURE_NOPL=y
CONFIG_X86_REQUIRED_FEATURE_CX8=y
CONFIG_X86_REQUIRED_FEATURE_CMOV=y
CONFIG_X86_REQUIRED_FEATURE_CPUID=y
CONFIG_X86_REQUIRED_FEATURE_FPU=y
CONFIG_X86_REQUIRED_FEATURE_PAE=y
CONFIG_X86_REQUIRED_FEATURE_PSE=y
CONFIG_X86_REQUIRED_FEATURE_PGE=y
CONFIG_X86_REQUIRED_FEATURE_MSR=y
CONFIG_X86_REQUIRED_FEATURE_FXSR=y
CONFIG_X86_REQUIRED_FEATURE_XMM=y
CONFIG_X86_REQUIRED_FEATURE_XMM2=y
CONFIG_X86_REQUIRED_FEATURE_LM=y
CONFIG_X86_DISABLED_FEATURE_VME=y
CONFIG_X86_DISABLED_FEATURE_K6_MTRR=y
CONFIG_X86_DISABLED_FEATURE_CYRIX_ARR=y
CONFIG_X86_DISABLED_FEATURE_CENTAUR_MCR=y
CONFIG_X86_DISABLED_FEATURE_LAM=y
CONFIG_X86_DISABLED_FEATURE_XENPV=y
CONFIG_X86_DISABLED_FEATURE_TDX_GUEST=y
CONFIG_X86_DISABLED_FEATURE_SEV_SNP=y
CONFIG_AS_WRUSS=y
CONFIG_ARCH_CONFIGURES_CPU_MITIGATIONS=y

#
# General architecture-dependent options
#
CONFIG_HOTPLUG_SMT=y
CONFIG_ARCH_SUPPORTS_SCHED_SMT=y
CONFIG_ARCH_SUPPORTS_SCHED_CLUSTER=y
CONFIG_ARCH_SUPPORTS_SCHED_MC=y
CONFIG_SCHED_SMT=y
CONFIG_SCHED_CLUSTER=y
CONFIG_SCHED_MC=y
CONFIG_HOTPLUG_CORE_SYNC=y
CONFIG_HOTPLUG_CORE_SYNC_DEAD=y
CONFIG_HOTPLUG_CORE_SYNC_FULL=y
CONFIG_HOTPLUG_SPLIT_STARTUP=y
CONFIG_HOTPLUG_PARALLEL=y
CONFIG_GENERIC_IRQ_ENTRY=y
CONFIG_GENERIC_SYSCALL=y
CONFIG_GENERIC_ENTRY=y
# CONFIG_KPROBES is not set
CONFIG_JUMP_LABEL=y
# CONFIG_STATIC_KEYS_SELFTEST is not set
# CONFIG_STATIC_CALL_SELFTEST is not set
CONFIG_UPROBES=y
CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS=y
CONFIG_ARCH_USE_BUILTIN_BSWAP=y
CONFIG_USER_RETURN_NOTIFIER=y
CONFIG_HAVE_IOREMAP_PROT=y
CONFIG_HAVE_KPROBES=y
CONFIG_HAVE_KRETPROBES=y
CONFIG_HAVE_OPTPROBES=y
CONFIG_HAVE_KPROBES_ON_FTRACE=y
CONFIG_ARCH_CORRECT_STACKTRACE_ON_KRETPROBE=y
CONFIG_HAVE_FUNCTION_ERROR_INJECTION=y
CONFIG_HAVE_NMI=y
CONFIG_TRACE_IRQFLAGS_SUPPORT=y
CONFIG_TRACE_IRQFLAGS_NMI_SUPPORT=y
CONFIG_HAVE_ARCH_TRACEHOOK=y
CONFIG_HAVE_DMA_CONTIGUOUS=y
CONFIG_GENERIC_SMP_IDLE_THREAD=y
CONFIG_ARCH_HAS_FORTIFY_SOURCE=y
CONFIG_ARCH_HAS_SET_MEMORY=y
CONFIG_ARCH_HAS_SET_DIRECT_MAP=y
CONFIG_ARCH_HAS_CPU_FINALIZE_INIT=y
CONFIG_ARCH_HAS_CPU_PASID=y
CONFIG_HAVE_ARCH_THREAD_STRUCT_WHITELIST=y
CONFIG_ARCH_WANTS_DYNAMIC_TASK_STRUCT=y
CONFIG_ARCH_WANTS_NO_INSTR=y
CONFIG_ARCH_MEMORY_ORDER_TSO=y
CONFIG_HAVE_ASM_MODVERSIONS=y
CONFIG_HAVE_REGS_AND_STACK_ACCESS_API=y
CONFIG_HAVE_RSEQ=y
CONFIG_HAVE_RUST=y
CONFIG_HAVE_FUNCTION_ARG_ACCESS_API=y
CONFIG_HAVE_HW_BREAKPOINT=y
CONFIG_HAVE_MIXED_BREAKPOINTS_REGS=y
CONFIG_HAVE_USER_RETURN_NOTIFIER=y
CONFIG_HAVE_PERF_EVENTS_NMI=y
CONFIG_HAVE_HARDLOCKUP_DETECTOR_PERF=y
CONFIG_UNWIND_USER=y
CONFIG_HAVE_UNWIND_USER_FP=y
CONFIG_HAVE_PERF_REGS=y
CONFIG_HAVE_PERF_USER_STACK_DUMP=y
CONFIG_HAVE_ARCH_JUMP_LABEL=y
CONFIG_HAVE_ARCH_JUMP_LABEL_RELATIVE=y
CONFIG_MMU_GATHER_TABLE_FREE=y
CONFIG_MMU_GATHER_RCU_TABLE_FREE=y
CONFIG_MMU_GATHER_MERGE_VMAS=y
CONFIG_ARCH_WANT_IRQS_OFF_ACTIVATE_MM=y
CONFIG_MMU_LAZY_TLB_REFCOUNT=y
CONFIG_ARCH_HAVE_NMI_SAFE_CMPXCHG=y
CONFIG_ARCH_HAVE_EXTRA_ELF_NOTES=y
CONFIG_ARCH_HAS_NMI_SAFE_THIS_CPU_OPS=y
CONFIG_HAVE_ALIGNED_STRUCT_PAGE=y
CONFIG_HAVE_CMPXCHG_LOCAL=y
CONFIG_HAVE_CMPXCHG_DOUBLE=y
CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
CONFIG_ARCH_WANT_OLD_COMPAT_IPC=y
CONFIG_HAVE_ARCH_SECCOMP=y
CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
CONFIG_SECCOMP=y
CONFIG_SECCOMP_FILTER=y
# CONFIG_SECCOMP_CACHE_DEBUG is not set
CONFIG_HAVE_ARCH_KSTACK_ERASE=y
CONFIG_HAVE_STACKPROTECTOR=y
CONFIG_STACKPROTECTOR=y
CONFIG_STACKPROTECTOR_STRONG=y
CONFIG_ARCH_SUPPORTS_LTO_CLANG=y
CONFIG_ARCH_SUPPORTS_LTO_CLANG_THIN=y
CONFIG_HAS_LTO_CLANG=y
CONFIG_LTO_NONE=y
# CONFIG_LTO_CLANG_FULL is not set
# CONFIG_LTO_CLANG_THIN is not set
# CONFIG_LTO_CLANG_THIN_DIST is not set
CONFIG_AUTOFDO_CLANG=y
CONFIG_PROPELLER_CLANG=y
CONFIG_ARCH_SUPPORTS_CFI=y
# CONFIG_CFI is not set
CONFIG_HAVE_CFI_ICALL_NORMALIZE_INTEGERS=y
CONFIG_HAVE_CFI_ICALL_NORMALIZE_INTEGERS_RUSTC=y
CONFIG_HAVE_ARCH_WITHIN_STACK_FRAMES=y
CONFIG_HAVE_CONTEXT_TRACKING_USER=y
CONFIG_HAVE_CONTEXT_TRACKING_USER_OFFSTACK=y
CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
CONFIG_HAVE_PV_STEAL_CLOCK_GEN=y
CONFIG_HAVE_MOVE_PUD=y
CONFIG_HAVE_MOVE_PMD=y
CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE_PUD=y
CONFIG_HAVE_ARCH_HUGE_VMAP=y
CONFIG_HAVE_ARCH_HUGE_VMALLOC=y
CONFIG_ARCH_WANT_HUGE_PMD_SHARE=y
CONFIG_ARCH_WANT_PMD_MKWRITE=y
CONFIG_HAVE_ARCH_SOFT_DIRTY=y
CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
CONFIG_MODULES_USE_ELF_RELA=y
CONFIG_ARCH_HAS_EXECMEM_ROX=y
CONFIG_HAVE_IRQ_EXIT_ON_IRQ_STACK=y
CONFIG_HAVE_SOFTIRQ_ON_OWN_STACK=y
CONFIG_SOFTIRQ_ON_OWN_STACK=y
CONFIG_ARCH_HAS_ELF_RANDOMIZE=y
CONFIG_HAVE_ARCH_MMAP_RND_BITS=y
CONFIG_HAVE_EXIT_THREAD=y
CONFIG_ARCH_MMAP_RND_BITS=28
CONFIG_HAVE_ARCH_MMAP_RND_COMPAT_BITS=y
CONFIG_ARCH_MMAP_RND_COMPAT_BITS=8
CONFIG_HAVE_ARCH_COMPAT_MMAP_BASES=y
CONFIG_HAVE_PAGE_SIZE_4KB=y
CONFIG_PAGE_SIZE_4KB=y
CONFIG_PAGE_SIZE_LESS_THAN_64KB=y
CONFIG_PAGE_SIZE_LESS_THAN_256KB=y
CONFIG_PAGE_SHIFT=12
CONFIG_HAVE_OBJTOOL=y
CONFIG_HAVE_JUMP_LABEL_HACK=y
CONFIG_HAVE_NOINSTR_HACK=y
CONFIG_HAVE_NOINSTR_VALIDATION=y
CONFIG_HAVE_UACCESS_VALIDATION=y
CONFIG_HAVE_STACK_VALIDATION=y
CONFIG_HAVE_RELIABLE_STACKTRACE=y
CONFIG_OLD_SIGSUSPEND3=y
CONFIG_COMPAT_OLD_SIGACTION=y
CONFIG_COMPAT_32BIT_TIME=y
CONFIG_ARCH_SUPPORTS_RT=y
CONFIG_HAVE_ARCH_VMAP_STACK=y
CONFIG_VMAP_STACK=y
CONFIG_HAVE_ARCH_RANDOMIZE_KSTACK_OFFSET=y
CONFIG_RANDOMIZE_KSTACK_OFFSET=y
# CONFIG_RANDOMIZE_KSTACK_OFFSET_DEFAULT is not set
CONFIG_ARCH_HAS_STRICT_KERNEL_RWX=y
CONFIG_STRICT_KERNEL_RWX=y
CONFIG_ARCH_HAS_STRICT_MODULE_RWX=y
CONFIG_STRICT_MODULE_RWX=y
CONFIG_HAVE_ARCH_PREL32_RELOCATIONS=y
# CONFIG_LOCK_EVENT_COUNTS is not set
CONFIG_ARCH_HAS_MEM_ENCRYPT=y
CONFIG_HAVE_STATIC_CALL=y
CONFIG_HAVE_STATIC_CALL_INLINE=y
CONFIG_HAVE_PREEMPT_DYNAMIC=y
CONFIG_HAVE_PREEMPT_DYNAMIC_CALL=y
CONFIG_ARCH_WANT_LD_ORPHAN_WARN=y
CONFIG_ARCH_SUPPORTS_DEBUG_PAGEALLOC=y
CONFIG_ARCH_SUPPORTS_PAGE_TABLE_CHECK=y
CONFIG_ARCH_HAS_ELFCORE_COMPAT=y
CONFIG_ARCH_HAS_PARANOID_L1D_FLUSH=y
CONFIG_DYNAMIC_SIGFRAME=y
CONFIG_HAVE_ARCH_NODE_DEV_GROUP=y
CONFIG_ARCH_HAS_HW_PTE_YOUNG=y
CONFIG_ARCH_HAS_NONLEAF_PMD_YOUNG=y
CONFIG_ARCH_HAS_KERNEL_FPU_SUPPORT=y
CONFIG_HAVE_GENERIC_TIF_BITS=y

#
# GCOV-based kernel profiling
#
# CONFIG_GCOV_KERNEL is not set
CONFIG_ARCH_HAS_GCOV_PROFILE_ALL=y
# end of GCOV-based kernel profiling

CONFIG_HAVE_GCC_PLUGINS=y
CONFIG_FUNCTION_ALIGNMENT_4B=y
CONFIG_FUNCTION_ALIGNMENT_16B=y
CONFIG_FUNCTION_ALIGNMENT=16
CONFIG_CC_HAS_SANE_FUNCTION_ALIGNMENT=y
CONFIG_ARCH_HAS_CPU_ATTACK_VECTORS=y
# end of General architecture-dependent options

CONFIG_RT_MUTEXES=y
CONFIG_MODULE_SIG_FORMAT=y
CONFIG_MODULES=y
# CONFIG_MODULE_DEBUG is not set
# CONFIG_MODULE_FORCE_LOAD is not set
CONFIG_MODULE_UNLOAD=y
CONFIG_MODULE_FORCE_UNLOAD=y
# CONFIG_MODULE_UNLOAD_TAINT_TRACKING is not set
CONFIG_MODVERSIONS=y
# CONFIG_GENKSYMS is not set
CONFIG_GENDWARFKSYMS=y
CONFIG_ASM_MODVERSIONS=y
# CONFIG_EXTENDED_MODVERSIONS is not set
# CONFIG_BASIC_MODVERSIONS is not set
CONFIG_MODULE_SRCVERSION_ALL=y
CONFIG_MODULE_SIG=y
# CONFIG_MODULE_SIG_FORCE is not set
# CONFIG_MODULE_SIG_ALL is not set
CONFIG_MODULE_SIG_SHA256=y
# CONFIG_MODULE_SIG_SHA384 is not set
# CONFIG_MODULE_SIG_SHA512 is not set
# CONFIG_MODULE_SIG_SHA3_256 is not set
# CONFIG_MODULE_SIG_SHA3_384 is not set
# CONFIG_MODULE_SIG_SHA3_512 is not set
CONFIG_MODULE_SIG_HASH="sha256"
# CONFIG_MODULE_COMPRESS is not set
# CONFIG_MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS is not set
CONFIG_MODPROBE_PATH="/sbin/modprobe"
# CONFIG_TRIM_UNUSED_KSYMS is not set
CONFIG_MODULES_TREE_LOOKUP=y
CONFIG_BLOCK=y
CONFIG_BLOCK_LEGACY_AUTOLOAD=y
CONFIG_BLK_RQ_ALLOC_TIME=y
CONFIG_BLK_CGROUP_RWSTAT=y
CONFIG_BLK_CGROUP_PUNT_BIO=y
CONFIG_BLK_DEV_BSG_COMMON=y
CONFIG_BLK_ICQ=y
CONFIG_BLK_DEV_BSGLIB=y
CONFIG_BLK_DEV_INTEGRITY=y
# CONFIG_BLK_DEV_WRITE_MOUNTED is not set
CONFIG_BLK_DEV_ZONED=y
CONFIG_BLK_DEV_THROTTLING=y
CONFIG_BLK_WBT=y
CONFIG_BLK_WBT_MQ=y
CONFIG_BLK_CGROUP_IOLATENCY=y
# CONFIG_BLK_CGROUP_FC_APPID is not set
CONFIG_BLK_CGROUP_IOCOST=y
CONFIG_BLK_CGROUP_IOPRIO=y
CONFIG_BLK_DEBUG_FS=y
# CONFIG_BLK_SED_OPAL is not set
CONFIG_BLK_INLINE_ENCRYPTION=y
CONFIG_BLK_INLINE_ENCRYPTION_FALLBACK=y

#
# Partition Types
#
CONFIG_PARTITION_ADVANCED=y
CONFIG_ACORN_PARTITION=y
CONFIG_ACORN_PARTITION_CUMANA=y
CONFIG_ACORN_PARTITION_EESOX=y
CONFIG_ACORN_PARTITION_ICS=y
CONFIG_ACORN_PARTITION_ADFS=y
CONFIG_ACORN_PARTITION_POWERTEC=y
CONFIG_ACORN_PARTITION_RISCIX=y
CONFIG_AIX_PARTITION=y
CONFIG_OSF_PARTITION=y
CONFIG_AMIGA_PARTITION=y
CONFIG_ATARI_PARTITION=y
CONFIG_MAC_PARTITION=y
CONFIG_MSDOS_PARTITION=y
CONFIG_BSD_DISKLABEL=y
CONFIG_MINIX_SUBPARTITION=y
CONFIG_SOLARIS_X86_PARTITION=y
CONFIG_UNIXWARE_DISKLABEL=y
CONFIG_LDM_PARTITION=y
# CONFIG_LDM_DEBUG is not set
CONFIG_SGI_PARTITION=y
CONFIG_ULTRIX_PARTITION=y
CONFIG_SUN_PARTITION=y
CONFIG_KARMA_PARTITION=y
CONFIG_EFI_PARTITION=y
CONFIG_SYSV68_PARTITION=y
CONFIG_CMDLINE_PARTITION=y
# CONFIG_OF_PARTITION is not set
# end of Partition Types

CONFIG_BLK_PM=y
CONFIG_BLOCK_HOLDER_DEPRECATED=y
CONFIG_BLK_MQ_STACKING=y
# CONFIG_BLK_ERROR_INJECTION is not set

#
# IO Schedulers
#
CONFIG_MQ_IOSCHED_DEADLINE=y
CONFIG_MQ_IOSCHED_KYBER=y
CONFIG_IOSCHED_BFQ=y
CONFIG_BFQ_GROUP_IOSCHED=y
CONFIG_BFQ_CGROUP_DEBUG=y
# end of IO Schedulers

CONFIG_PREEMPT_NOTIFIERS=y
CONFIG_PADATA=y
CONFIG_ASN1=y
CONFIG_UNINLINE_SPIN_UNLOCK=y
CONFIG_ARCH_SUPPORTS_ATOMIC_RMW=y
CONFIG_MUTEX_SPIN_ON_OWNER=y
CONFIG_RWSEM_SPIN_ON_OWNER=y
CONFIG_LOCK_SPIN_ON_OWNER=y
CONFIG_ARCH_USE_QUEUED_SPINLOCKS=y
CONFIG_QUEUED_SPINLOCKS=y
CONFIG_ARCH_USE_QUEUED_RWLOCKS=y
CONFIG_QUEUED_RWLOCKS=y
CONFIG_ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE=y
CONFIG_ARCH_HAS_SYNC_CORE_BEFORE_USERMODE=y
CONFIG_ARCH_HAS_SYSCALL_WRAPPER=y
CONFIG_FREEZER=y

#
# Executable file formats
#
CONFIG_BINFMT_ELF=y
CONFIG_COMPAT_BINFMT_ELF=y
CONFIG_ELFCORE=y
CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS=y
CONFIG_BINFMT_SCRIPT=y
CONFIG_BINFMT_MISC=y
CONFIG_COREDUMP=y
# end of Executable file formats

#
# Memory Management options
#
CONFIG_SWAP=y
CONFIG_ZSWAP=y
CONFIG_ZSWAP_DEFAULT_ON=y
CONFIG_ZSWAP_SHRINKER_DEFAULT_ON=y
# CONFIG_ZSWAP_COMPRESSOR_DEFAULT_DEFLATE is not set
# CONFIG_ZSWAP_COMPRESSOR_DEFAULT_LZO is not set
CONFIG_ZSWAP_COMPRESSOR_DEFAULT_842=y
# CONFIG_ZSWAP_COMPRESSOR_DEFAULT_LZ4 is not set
# CONFIG_ZSWAP_COMPRESSOR_DEFAULT_LZ4HC is not set
# CONFIG_ZSWAP_COMPRESSOR_DEFAULT_ZSTD is not set
CONFIG_ZSWAP_COMPRESSOR_DEFAULT="842"
CONFIG_ZSMALLOC=y

#
# Zsmalloc allocator options
#

#
# Zsmalloc is a common backend allocator for zswap & zram
#
# CONFIG_ZSMALLOC_STAT is not set
CONFIG_ZSMALLOC_CHAIN_SIZE=8
# end of Zsmalloc allocator options

#
# Slab allocator options
#
CONFIG_SLUB=y
CONFIG_KVFREE_RCU_BATCHED=y
# CONFIG_SLUB_TINY is not set
CONFIG_SLAB_MERGE_DEFAULT=y
# CONFIG_SLAB_FREELIST_RANDOM is not set
# CONFIG_SLAB_FREELIST_HARDENED is not set
# CONFIG_SLAB_BUCKETS is not set
# CONFIG_SLUB_STATS is not set
# CONFIG_KMALLOC_PARTITION_CACHES is not set
# end of Slab allocator options

# CONFIG_SHUFFLE_PAGE_ALLOCATOR is not set
# CONFIG_COMPAT_BRK is not set
CONFIG_SPARSEMEM=y
CONFIG_SPARSEMEM_EXTREME=y
CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y
CONFIG_SPARSEMEM_VMEMMAP=y
CONFIG_SPARSEMEM_VMEMMAP_PREINIT=y
CONFIG_ARCH_WANT_OPTIMIZE_DAX_VMEMMAP=y
CONFIG_ARCH_WANT_OPTIMIZE_HUGETLB_VMEMMAP=y
CONFIG_ARCH_WANT_HUGETLB_VMEMMAP_PREINIT=y
CONFIG_HAVE_GUP_FAST=y
CONFIG_NUMA_KEEP_MEMINFO=y
CONFIG_MEMORY_ISOLATION=y
CONFIG_EXCLUSIVE_SYSTEM_RAM=y
CONFIG_HAVE_BOOTMEM_INFO_NODE=y
CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y
CONFIG_MEMORY_HOTPLUG=y
# CONFIG_MHP_DEFAULT_ONLINE_TYPE_OFFLINE is not set
CONFIG_MHP_DEFAULT_ONLINE_TYPE_ONLINE_AUTO=y
# CONFIG_MHP_DEFAULT_ONLINE_TYPE_ONLINE_KERNEL is not set
# CONFIG_MHP_DEFAULT_ONLINE_TYPE_ONLINE_MOVABLE is not set
CONFIG_MEMORY_HOTREMOVE=y
CONFIG_MHP_MEMMAP_ON_MEMORY=y
CONFIG_ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE=y
CONFIG_SPLIT_PTE_PTLOCKS=y
CONFIG_ARCH_ENABLE_SPLIT_PMD_PTLOCK=y
CONFIG_SPLIT_PMD_PTLOCKS=y
CONFIG_BALLOON=y
# CONFIG_BALLOON_MIGRATION is not set
CONFIG_COMPACTION=y
CONFIG_COMPACT_UNEVICTABLE_DEFAULT=1
CONFIG_PAGE_REPORTING=y
CONFIG_NUMA_MIGRATION=y
CONFIG_MIGRATION=y
CONFIG_DEVICE_MIGRATION=y
CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION=y
CONFIG_ARCH_ENABLE_THP_MIGRATION=y
CONFIG_CONTIG_ALLOC=y
CONFIG_PCP_BATCH_SCALE_MAX=5
CONFIG_PHYS_ADDR_T_64BIT=y
CONFIG_MMU_NOTIFIER=y
CONFIG_KSM=y
CONFIG_DEFAULT_MMAP_MIN_ADDR=4096
CONFIG_ARCH_SUPPORTS_MEMORY_FAILURE=y
# CONFIG_MEMORY_FAILURE is not set
CONFIG_ARCH_WANT_GENERAL_HUGETLB=y
CONFIG_ARCH_WANTS_THP_SWAP=y
# CONFIG_PERSISTENT_HUGE_ZERO_FOLIO is not set
CONFIG_MM_ID=y
CONFIG_TRANSPARENT_HUGEPAGE=y
# CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS is not set
CONFIG_TRANSPARENT_HUGEPAGE_MADVISE=y
# CONFIG_TRANSPARENT_HUGEPAGE_NEVER is not set
# CONFIG_TRANSPARENT_HUGEPAGE_SHMEM_HUGE_NEVER is not set
# CONFIG_TRANSPARENT_HUGEPAGE_SHMEM_HUGE_ALWAYS is not set
# CONFIG_TRANSPARENT_HUGEPAGE_SHMEM_HUGE_WITHIN_SIZE is not set
CONFIG_TRANSPARENT_HUGEPAGE_SHMEM_HUGE_ADVISE=y
# CONFIG_TRANSPARENT_HUGEPAGE_TMPFS_HUGE_NEVER is not set
# CONFIG_TRANSPARENT_HUGEPAGE_TMPFS_HUGE_ALWAYS is not set
# CONFIG_TRANSPARENT_HUGEPAGE_TMPFS_HUGE_WITHIN_SIZE is not set
CONFIG_TRANSPARENT_HUGEPAGE_TMPFS_HUGE_ADVISE=y
CONFIG_THP_SWAP=y
# CONFIG_NO_PAGE_MAPCOUNT is not set
CONFIG_PAGE_MAPCOUNT=y
CONFIG_PGTABLE_HAS_HUGE_LEAVES=y
CONFIG_HAVE_GIGANTIC_FOLIOS=y
CONFIG_ASYNC_KERNEL_PGTABLE_FREE=y
CONFIG_ARCH_SUPPORTS_HUGE_PFNMAP=y
CONFIG_ARCH_SUPPORTS_PMD_PFNMAP=y
CONFIG_ARCH_SUPPORTS_PUD_PFNMAP=y
CONFIG_NEED_PER_CPU_EMBED_FIRST_CHUNK=y
CONFIG_NEED_PER_CPU_PAGE_FIRST_CHUNK=y
CONFIG_USE_PERCPU_NUMA_NODE_ID=y
CONFIG_HAVE_SETUP_PER_CPU_AREA=y
CONFIG_CMA=y
# CONFIG_CMA_DEBUGFS is not set
# CONFIG_CMA_SYSFS is not set
CONFIG_CMA_AREAS=20
CONFIG_PAGE_BLOCK_MAX_ORDER=10
CONFIG_MEM_SOFT_DIRTY=y
CONFIG_GENERIC_EARLY_IOREMAP=y
# CONFIG_DEFERRED_STRUCT_PAGE_INIT is not set
CONFIG_PAGE_IDLE_FLAG=y
# CONFIG_IDLE_PAGE_TRACKING is not set
CONFIG_ARCH_HAS_CACHE_LINE_SIZE=y
CONFIG_ARCH_HAS_CURRENT_STACK_POINTER=y
CONFIG_ARCH_HAS_ZONE_DMA_SET=y
CONFIG_ZONE_DMA=y
CONFIG_ZONE_DMA32=y
CONFIG_ZONE_DEVICE=y
CONFIG_HMM_MIRROR=y
CONFIG_GET_FREE_REGION=y
CONFIG_DEVICE_PRIVATE=y
CONFIG_VMAP_PFN=y
CONFIG_ARCH_USES_HIGH_VMA_FLAGS=y
CONFIG_ARCH_HAS_PKEYS=y
CONFIG_ARCH_USES_PG_ARCH_2=y
CONFIG_VM_EVENT_COUNTERS=y
CONFIG_PERCPU_STATS=y
# CONFIG_GUP_TEST is not set
# CONFIG_DMAPOOL_TEST is not set
CONFIG_ARCH_HAS_PTE_SPECIAL=y
CONFIG_MAPPING_DIRTY_HELPERS=y
CONFIG_KMAP_LOCAL=y
CONFIG_MEMFD_CREATE=y
CONFIG_SECRETMEM=y
CONFIG_ANON_VMA_NAME=y
CONFIG_HAVE_ARCH_USERFAULTFD_WP=y
CONFIG_HAVE_ARCH_USERFAULTFD_MINOR=y
CONFIG_USERFAULTFD=y
# CONFIG_PTE_MARKER_UFFD_WP is not set
CONFIG_LRU_GEN=y
CONFIG_LRU_GEN_ENABLED=y
# CONFIG_LRU_GEN_STATS is not set
CONFIG_LRU_GEN_WALKS_MMU=y
CONFIG_ARCH_SUPPORTS_PER_VMA_LOCK=y
CONFIG_PER_VMA_LOCK=y
CONFIG_LOCK_MM_AND_FIND_VMA=y
CONFIG_IOMMU_MM_DATA=y
CONFIG_EXECMEM=y
CONFIG_NUMA_MEMBLKS=y
CONFIG_NUMA_EMU=y
CONFIG_ARCH_HAS_USER_SHADOW_STACK=y
CONFIG_PT_RECLAIM=y

#
# Data Access Monitoring
#
CONFIG_DAMON=y
# CONFIG_DAMON_DEBUG_SANITY is not set
CONFIG_DAMON_VADDR=y
CONFIG_DAMON_PADDR=y
# CONFIG_DAMON_SYSFS is not set
CONFIG_DAMON_RECLAIM=y
# CONFIG_DAMON_LRU_SORT is not set
# CONFIG_DAMON_STAT is not set
# end of Data Access Monitoring
# end of Memory Management options

CONFIG_NET=y
CONFIG_WANT_COMPAT_NETLINK_MESSAGES=y
CONFIG_COMPAT_NETLINK_MESSAGES=y
CONFIG_NET_INGRESS=y
CONFIG_NET_EGRESS=y
CONFIG_NET_XGRESS=y
CONFIG_NET_REDIRECT=y
CONFIG_SKB_DECRYPTED=y
CONFIG_SKB_EXTENSIONS=y
CONFIG_NET_DEVMEM=y
CONFIG_NET_SHAPER=y
CONFIG_NET_CRC32C=y

#
# Networking options
#
CONFIG_PACKET=y
CONFIG_PACKET_DIAG=y
CONFIG_INET_PSP=y
CONFIG_UNIX=y
CONFIG_AF_UNIX_OOB=y
CONFIG_UNIX_DIAG=y
CONFIG_TLS=y
CONFIG_TLS_DEVICE=y
CONFIG_XFRM=y
CONFIG_XFRM_OFFLOAD=y
CONFIG_XFRM_ALGO=y
CONFIG_XFRM_USER=y
CONFIG_XFRM_USER_COMPAT=y
CONFIG_XFRM_INTERFACE=y
CONFIG_XFRM_SUB_POLICY=y
CONFIG_XFRM_MIGRATE=y
CONFIG_XFRM_STATISTICS=y
CONFIG_XFRM_AH=y
CONFIG_XFRM_ESP=y
CONFIG_XFRM_IPCOMP=y
CONFIG_NET_KEY=y
CONFIG_NET_KEY_MIGRATE=y
# CONFIG_XFRM_IPTFS is not set
CONFIG_XFRM_ESPINTCP=y
CONFIG_SMC=y
CONFIG_SMC_DIAG=y
# CONFIG_SMC_HS_CTRL_BPF is not set
CONFIG_DIBS=y
CONFIG_DIBS_LO=y
CONFIG_XDP_SOCKETS=y
CONFIG_XDP_SOCKETS_DIAG=y
CONFIG_NET_HANDSHAKE=y
CONFIG_INET=y
CONFIG_IP_MULTICAST=y
CONFIG_IP_ADVANCED_ROUTER=y
CONFIG_IP_FIB_TRIE_STATS=y
CONFIG_IP_MULTIPLE_TABLES=y
CONFIG_IP_ROUTE_MULTIPATH=y
CONFIG_IP_ROUTE_VERBOSE=y
CONFIG_IP_ROUTE_CLASSID=y
CONFIG_IP_PNP=y
CONFIG_IP_PNP_DHCP=y
CONFIG_IP_PNP_BOOTP=y
CONFIG_IP_PNP_RARP=y
CONFIG_NET_IPIP=y
CONFIG_NET_IPGRE_DEMUX=y
CONFIG_NET_IP_TUNNEL=y
CONFIG_NET_IPGRE=y
CONFIG_NET_IPGRE_BROADCAST=y
CONFIG_IP_MROUTE_COMMON=y
CONFIG_IP_MROUTE=y
CONFIG_IP_MROUTE_MULTIPLE_TABLES=y
CONFIG_IP_PIMSM_V1=y
CONFIG_IP_PIMSM_V2=y
CONFIG_SYN_COOKIES=y
CONFIG_NET_IPVTI=y
CONFIG_NET_UDP_TUNNEL=y
CONFIG_NET_FOU=y
CONFIG_NET_FOU_IP_TUNNELS=y
CONFIG_INET_AH=y
CONFIG_INET_ESP=y
CONFIG_INET_ESP_OFFLOAD=y
CONFIG_INET_ESPINTCP=y
CONFIG_INET_IPCOMP=y
CONFIG_INET_TABLE_PERTURB_ORDER=16
CONFIG_INET_XFRM_TUNNEL=y
CONFIG_INET_TUNNEL=y
CONFIG_INET_DIAG=y
CONFIG_INET_TCP_DIAG=y
CONFIG_INET_UDP_DIAG=y
CONFIG_INET_RAW_DIAG=y
CONFIG_INET_DIAG_DESTROY=y
CONFIG_TCP_CONG_ADVANCED=y
CONFIG_TCP_CONG_BIC=y
CONFIG_TCP_CONG_CUBIC=y
CONFIG_TCP_CONG_WESTWOOD=y
CONFIG_TCP_CONG_HTCP=y
CONFIG_TCP_CONG_HSTCP=y
CONFIG_TCP_CONG_HYBLA=y
CONFIG_TCP_CONG_VEGAS=y
CONFIG_TCP_CONG_NV=y
CONFIG_TCP_CONG_SCALABLE=y
CONFIG_TCP_CONG_LP=y
CONFIG_TCP_CONG_VENO=y
CONFIG_TCP_CONG_YEAH=y
CONFIG_TCP_CONG_ILLINOIS=y
CONFIG_TCP_CONG_DCTCP=y
CONFIG_TCP_CONG_CDG=y
CONFIG_TCP_CONG_BBR=y
# CONFIG_DEFAULT_BIC is not set
CONFIG_DEFAULT_CUBIC=y
# CONFIG_DEFAULT_HTCP is not set
# CONFIG_DEFAULT_HYBLA is not set
# CONFIG_DEFAULT_VEGAS is not set
# CONFIG_DEFAULT_VENO is not set
# CONFIG_DEFAULT_WESTWOOD is not set
# CONFIG_DEFAULT_DCTCP is not set
# CONFIG_DEFAULT_CDG is not set
# CONFIG_DEFAULT_BBR is not set
# CONFIG_DEFAULT_RENO is not set
CONFIG_DEFAULT_TCP_CONG="cubic"
# CONFIG_TCP_AO is not set
CONFIG_TCP_MD5SIG=y
CONFIG_IPV6=y
CONFIG_IPV6_ROUTER_PREF=y
CONFIG_IPV6_ROUTE_INFO=y
CONFIG_IPV6_OPTIMISTIC_DAD=y
CONFIG_INET6_AH=y
CONFIG_INET6_ESP=y
CONFIG_INET6_ESP_OFFLOAD=y
CONFIG_INET6_ESPINTCP=y
CONFIG_INET6_IPCOMP=y
CONFIG_IPV6_MIP6=y
CONFIG_IPV6_ILA=y
CONFIG_INET6_XFRM_TUNNEL=y
CONFIG_INET6_TUNNEL=y
CONFIG_IPV6_VTI=y
CONFIG_IPV6_SIT=y
CONFIG_IPV6_SIT_6RD=y
CONFIG_IPV6_NDISC_NODETYPE=y
CONFIG_IPV6_TUNNEL=y
CONFIG_IPV6_GRE=y
CONFIG_IPV6_FOU=y
CONFIG_IPV6_FOU_TUNNEL=y
CONFIG_IPV6_MULTIPLE_TABLES=y
CONFIG_IPV6_SUBTREES=y
CONFIG_IPV6_MROUTE=y
CONFIG_IPV6_MROUTE_MULTIPLE_TABLES=y
CONFIG_IPV6_PIMSM_V2=y
CONFIG_IPV6_SEG6_LWTUNNEL=y
CONFIG_IPV6_SEG6_HMAC=y
CONFIG_IPV6_SEG6_BPF=y
CONFIG_IPV6_RPL_LWTUNNEL=y
# CONFIG_IPV6_IOAM6_LWTUNNEL is not set
CONFIG_NETLABEL=y
CONFIG_MPTCP=y
CONFIG_INET_MPTCP_DIAG=y
CONFIG_MPTCP_IPV6=y
CONFIG_NETWORK_SECMARK=y
CONFIG_NET_PTP_CLASSIFY=y
# CONFIG_NETWORK_PHY_TIMESTAMPING is not set
CONFIG_NETFILTER=y
CONFIG_NETFILTER_ADVANCED=y
CONFIG_BRIDGE_NETFILTER=y

#
# Core Netfilter Configuration
#
CONFIG_NETFILTER_INGRESS=y
CONFIG_NETFILTER_EGRESS=y
CONFIG_NETFILTER_SKIP_EGRESS=y
CONFIG_NETFILTER_NETLINK=y
CONFIG_NETFILTER_FAMILY_BRIDGE=y
CONFIG_NETFILTER_FAMILY_ARP=y
CONFIG_NETFILTER_BPF_LINK=y
# CONFIG_NETFILTER_NETLINK_HOOK is not set
CONFIG_NETFILTER_NETLINK_ACCT=y
CONFIG_NETFILTER_NETLINK_QUEUE=y
CONFIG_NETFILTER_NETLINK_LOG=y
CONFIG_NETFILTER_NETLINK_OSF=y
CONFIG_NF_CONNTRACK=y
CONFIG_NF_LOG_SYSLOG=y
CONFIG_NETFILTER_CONNCOUNT=y
CONFIG_NF_CONNTRACK_MARK=y
CONFIG_NF_CONNTRACK_SECMARK=y
CONFIG_NF_CONNTRACK_ZONES=y
# CONFIG_NF_CONNTRACK_PROCFS is not set
CONFIG_NF_CONNTRACK_EVENTS=y
CONFIG_NF_CONNTRACK_TIMEOUT=y
CONFIG_NF_CONNTRACK_TIMESTAMP=y
CONFIG_NF_CONNTRACK_LABELS=y
CONFIG_NF_CONNTRACK_OVS=y
CONFIG_NF_CT_PROTO_GRE=y
CONFIG_NF_CT_PROTO_SCTP=y
CONFIG_NF_CONNTRACK_AMANDA=y
CONFIG_NF_CONNTRACK_FTP=y
CONFIG_NF_CONNTRACK_H323=y
CONFIG_NF_CONNTRACK_IRC=y
CONFIG_NF_CONNTRACK_BROADCAST=y
CONFIG_NF_CONNTRACK_NETBIOS_NS=y
CONFIG_NF_CONNTRACK_SNMP=y
CONFIG_NF_CONNTRACK_PPTP=y
CONFIG_NF_CONNTRACK_SANE=y
CONFIG_NF_CONNTRACK_SIP=y
CONFIG_NF_CONNTRACK_TFTP=y
CONFIG_NF_CT_NETLINK=y
CONFIG_NF_CT_NETLINK_TIMEOUT=y
CONFIG_NF_CT_NETLINK_HELPER=y
CONFIG_NETFILTER_NETLINK_GLUE_CT=y
CONFIG_NF_NAT=y
CONFIG_NF_NAT_AMANDA=y
CONFIG_NF_NAT_FTP=y
CONFIG_NF_NAT_IRC=y
CONFIG_NF_NAT_SIP=y
CONFIG_NF_NAT_TFTP=y
CONFIG_NF_NAT_REDIRECT=y
CONFIG_NF_NAT_MASQUERADE=y
CONFIG_NF_NAT_OVS=y
CONFIG_NETFILTER_SYNPROXY=y
CONFIG_NF_TABLES=y
CONFIG_NF_TABLES_INET=y
CONFIG_NF_TABLES_NETDEV=y
CONFIG_NFT_NUMGEN=y
CONFIG_NFT_CT=y
CONFIG_NFT_EXTHDR_DCCP=y
CONFIG_NFT_FLOW_OFFLOAD=y
CONFIG_NFT_CONNLIMIT=y
CONFIG_NFT_LOG=y
CONFIG_NFT_LIMIT=y
CONFIG_NFT_MASQ=y
CONFIG_NFT_REDIR=y
CONFIG_NFT_NAT=y
CONFIG_NFT_TUNNEL=y
CONFIG_NFT_QUEUE=y
CONFIG_NFT_QUOTA=y
CONFIG_NFT_REJECT=y
CONFIG_NFT_REJECT_INET=y
CONFIG_NFT_COMPAT=y
CONFIG_NFT_HASH=y
CONFIG_NFT_FIB=y
CONFIG_NFT_FIB_INET=y
CONFIG_NFT_XFRM=y
CONFIG_NFT_SOCKET=y
CONFIG_NFT_OSF=y
CONFIG_NFT_TPROXY=y
CONFIG_NFT_SYNPROXY=y
CONFIG_NF_DUP_NETDEV=y
CONFIG_NFT_DUP_NETDEV=y
CONFIG_NFT_FWD_NETDEV=y
CONFIG_NFT_FIB_NETDEV=y
CONFIG_NFT_REJECT_NETDEV=y
CONFIG_NF_FLOW_TABLE_INET=y
CONFIG_NF_FLOW_TABLE=y
# CONFIG_NF_FLOW_TABLE_PROCFS is not set
CONFIG_NETFILTER_XTABLES=y
CONFIG_NETFILTER_XTABLES_COMPAT=y
CONFIG_NETFILTER_XTABLES_LEGACY=y

#
# Xtables combined modules
#
CONFIG_NETFILTER_XT_MARK=y
CONFIG_NETFILTER_XT_CONNMARK=y
CONFIG_NETFILTER_XT_SET=y

#
# Xtables targets
#
CONFIG_NETFILTER_XT_TARGET_AUDIT=y
CONFIG_NETFILTER_XT_TARGET_CHECKSUM=y
CONFIG_NETFILTER_XT_TARGET_CLASSIFY=y
CONFIG_NETFILTER_XT_TARGET_CONNMARK=y
CONFIG_NETFILTER_XT_TARGET_CONNSECMARK=y
CONFIG_NETFILTER_XT_TARGET_CT=y
CONFIG_NETFILTER_XT_TARGET_DSCP=y
CONFIG_NETFILTER_XT_TARGET_HL=y
CONFIG_NETFILTER_XT_TARGET_HMARK=y
CONFIG_NETFILTER_XT_TARGET_IDLETIMER=y
CONFIG_NETFILTER_XT_TARGET_LED=y
CONFIG_NETFILTER_XT_TARGET_LOG=y
CONFIG_NETFILTER_XT_TARGET_MARK=y
CONFIG_NETFILTER_XT_NAT=y
CONFIG_NETFILTER_XT_TARGET_NETMAP=y
CONFIG_NETFILTER_XT_TARGET_NFLOG=y
CONFIG_NETFILTER_XT_TARGET_NFQUEUE=y
CONFIG_NETFILTER_XT_TARGET_NOTRACK=y
CONFIG_NETFILTER_XT_TARGET_RATEEST=y
CONFIG_NETFILTER_XT_TARGET_REDIRECT=y
CONFIG_NETFILTER_XT_TARGET_MASQUERADE=y
CONFIG_NETFILTER_XT_TARGET_TEE=y
CONFIG_NETFILTER_XT_TARGET_TPROXY=y
CONFIG_NETFILTER_XT_TARGET_TRACE=y
CONFIG_NETFILTER_XT_TARGET_SECMARK=y
CONFIG_NETFILTER_XT_TARGET_TCPMSS=y
CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP=y

#
# Xtables matches
#
CONFIG_NETFILTER_XT_MATCH_ADDRTYPE=y
CONFIG_NETFILTER_XT_MATCH_BPF=y
CONFIG_NETFILTER_XT_MATCH_CGROUP=y
CONFIG_NETFILTER_XT_MATCH_CLUSTER=y
CONFIG_NETFILTER_XT_MATCH_COMMENT=y
CONFIG_NETFILTER_XT_MATCH_CONNBYTES=y
CONFIG_NETFILTER_XT_MATCH_CONNLABEL=y
CONFIG_NETFILTER_XT_MATCH_CONNLIMIT=y
CONFIG_NETFILTER_XT_MATCH_CONNMARK=y
CONFIG_NETFILTER_XT_MATCH_CONNTRACK=y
CONFIG_NETFILTER_XT_MATCH_CPU=y
CONFIG_NETFILTER_XT_MATCH_DCCP=y
CONFIG_NETFILTER_XT_MATCH_DEVGROUP=y
CONFIG_NETFILTER_XT_MATCH_DSCP=y
CONFIG_NETFILTER_XT_MATCH_ECN=y
CONFIG_NETFILTER_XT_MATCH_ESP=y
CONFIG_NETFILTER_XT_MATCH_HASHLIMIT=y
CONFIG_NETFILTER_XT_MATCH_HELPER=y
CONFIG_NETFILTER_XT_MATCH_HL=y
CONFIG_NETFILTER_XT_MATCH_IPCOMP=y
CONFIG_NETFILTER_XT_MATCH_IPRANGE=y
CONFIG_NETFILTER_XT_MATCH_IPVS=y
CONFIG_NETFILTER_XT_MATCH_L2TP=y
CONFIG_NETFILTER_XT_MATCH_LENGTH=y
CONFIG_NETFILTER_XT_MATCH_LIMIT=y
CONFIG_NETFILTER_XT_MATCH_MAC=y
CONFIG_NETFILTER_XT_MATCH_MARK=y
CONFIG_NETFILTER_XT_MATCH_MULTIPORT=y
CONFIG_NETFILTER_XT_MATCH_NFACCT=y
CONFIG_NETFILTER_XT_MATCH_OSF=y
CONFIG_NETFILTER_XT_MATCH_OWNER=y
CONFIG_NETFILTER_XT_MATCH_POLICY=y
CONFIG_NETFILTER_XT_MATCH_PHYSDEV=y
CONFIG_NETFILTER_XT_MATCH_PKTTYPE=y
CONFIG_NETFILTER_XT_MATCH_QUOTA=y
CONFIG_NETFILTER_XT_MATCH_RATEEST=y
CONFIG_NETFILTER_XT_MATCH_REALM=y
CONFIG_NETFILTER_XT_MATCH_RECENT=y
CONFIG_NETFILTER_XT_MATCH_SCTP=y
CONFIG_NETFILTER_XT_MATCH_SOCKET=y
CONFIG_NETFILTER_XT_MATCH_STATE=y
CONFIG_NETFILTER_XT_MATCH_STATISTIC=y
CONFIG_NETFILTER_XT_MATCH_STRING=y
CONFIG_NETFILTER_XT_MATCH_TCPMSS=y
CONFIG_NETFILTER_XT_MATCH_TIME=y
CONFIG_NETFILTER_XT_MATCH_U32=y
# end of Core Netfilter Configuration

CONFIG_IP_SET=y
CONFIG_IP_SET_MAX=256
CONFIG_IP_SET_BITMAP_IP=y
CONFIG_IP_SET_BITMAP_IPMAC=y
CONFIG_IP_SET_BITMAP_PORT=y
CONFIG_IP_SET_HASH_IP=y
CONFIG_IP_SET_HASH_IPMARK=y
CONFIG_IP_SET_HASH_IPPORT=y
CONFIG_IP_SET_HASH_IPPORTIP=y
CONFIG_IP_SET_HASH_IPPORTNET=y
CONFIG_IP_SET_HASH_IPMAC=y
CONFIG_IP_SET_HASH_MAC=y
CONFIG_IP_SET_HASH_NETPORTNET=y
CONFIG_IP_SET_HASH_NET=y
CONFIG_IP_SET_HASH_NETNET=y
CONFIG_IP_SET_HASH_NETPORT=y
CONFIG_IP_SET_HASH_NETIFACE=y
CONFIG_IP_SET_LIST_SET=y
CONFIG_IP_VS=y
CONFIG_IP_VS_IPV6=y
# CONFIG_IP_VS_DEBUG is not set
CONFIG_IP_VS_TAB_BITS=12

#
# IPVS transport protocol load balancing support
#
CONFIG_IP_VS_PROTO_TCP=y
CONFIG_IP_VS_PROTO_UDP=y
CONFIG_IP_VS_PROTO_AH_ESP=y
CONFIG_IP_VS_PROTO_ESP=y
CONFIG_IP_VS_PROTO_AH=y
CONFIG_IP_VS_PROTO_SCTP=y

#
# IPVS scheduler
#
CONFIG_IP_VS_RR=y
CONFIG_IP_VS_WRR=y
CONFIG_IP_VS_LC=y
CONFIG_IP_VS_WLC=y
CONFIG_IP_VS_FO=y
CONFIG_IP_VS_OVF=y
CONFIG_IP_VS_LBLC=y
CONFIG_IP_VS_LBLCR=y
CONFIG_IP_VS_DH=y
CONFIG_IP_VS_SH=y
CONFIG_IP_VS_MH=y
CONFIG_IP_VS_SED=y
CONFIG_IP_VS_NQ=y
CONFIG_IP_VS_TWOS=y

#
# IPVS SH scheduler
#
CONFIG_IP_VS_SH_TAB_BITS=8

#
# IPVS MH scheduler
#
CONFIG_IP_VS_MH_TAB_INDEX=12

#
# IPVS application helper
#
CONFIG_IP_VS_FTP=y
CONFIG_IP_VS_NFCT=y
CONFIG_IP_VS_PE_SIP=y

#
# IP: Netfilter Configuration
#
CONFIG_NF_DEFRAG_IPV4=y
CONFIG_IP_NF_IPTABLES_LEGACY=y
CONFIG_NF_SOCKET_IPV4=y
CONFIG_NF_TPROXY_IPV4=y
CONFIG_NF_TABLES_IPV4=y
CONFIG_NFT_REJECT_IPV4=y
CONFIG_NFT_DUP_IPV4=y
CONFIG_NFT_FIB_IPV4=y
CONFIG_NF_TABLES_ARP=y
CONFIG_NF_DUP_IPV4=y
CONFIG_NF_LOG_ARP=y
CONFIG_NF_LOG_IPV4=y
CONFIG_NF_REJECT_IPV4=y
CONFIG_NF_NAT_SNMP_BASIC=y
CONFIG_NF_NAT_PPTP=y
CONFIG_NF_NAT_H323=y
CONFIG_IP_NF_IPTABLES=y
CONFIG_IP_NF_MATCH_AH=y
CONFIG_IP_NF_MATCH_ECN=y
CONFIG_IP_NF_MATCH_RPFILTER=y
CONFIG_IP_NF_MATCH_TTL=y
CONFIG_IP_NF_FILTER=y
CONFIG_IP_NF_TARGET_REJECT=y
CONFIG_IP_NF_TARGET_SYNPROXY=y
CONFIG_IP_NF_NAT=y
CONFIG_IP_NF_TARGET_MASQUERADE=y
CONFIG_IP_NF_TARGET_NETMAP=y
CONFIG_IP_NF_TARGET_REDIRECT=y
CONFIG_IP_NF_MANGLE=y
CONFIG_IP_NF_TARGET_ECN=y
CONFIG_IP_NF_TARGET_TTL=y
CONFIG_IP_NF_RAW=y
CONFIG_IP_NF_SECURITY=y
CONFIG_IP_NF_ARPTABLES=y
CONFIG_NFT_COMPAT_ARP=y
CONFIG_IP_NF_ARPFILTER=y
CONFIG_IP_NF_ARP_MANGLE=y
# end of IP: Netfilter Configuration

#
# IPv6: Netfilter Configuration
#
CONFIG_IP6_NF_IPTABLES_LEGACY=y
CONFIG_NF_SOCKET_IPV6=y
CONFIG_NF_TPROXY_IPV6=y
CONFIG_NF_TABLES_IPV6=y
CONFIG_NFT_REJECT_IPV6=y
CONFIG_NFT_DUP_IPV6=y
CONFIG_NFT_FIB_IPV6=y
CONFIG_NF_DUP_IPV6=y
CONFIG_NF_REJECT_IPV6=y
CONFIG_NF_LOG_IPV6=y
CONFIG_IP6_NF_IPTABLES=y
CONFIG_IP6_NF_MATCH_AH=y
CONFIG_IP6_NF_MATCH_EUI64=y
CONFIG_IP6_NF_MATCH_FRAG=y
CONFIG_IP6_NF_MATCH_OPTS=y
CONFIG_IP6_NF_MATCH_HL=y
CONFIG_IP6_NF_MATCH_IPV6HEADER=y
CONFIG_IP6_NF_MATCH_MH=y
CONFIG_IP6_NF_MATCH_RPFILTER=y
CONFIG_IP6_NF_MATCH_RT=y
CONFIG_IP6_NF_MATCH_SRH=y
CONFIG_IP6_NF_TARGET_HL=y
CONFIG_IP6_NF_FILTER=y
CONFIG_IP6_NF_TARGET_REJECT=y
CONFIG_IP6_NF_TARGET_SYNPROXY=y
CONFIG_IP6_NF_MANGLE=y
CONFIG_IP6_NF_RAW=y
CONFIG_IP6_NF_SECURITY=y
CONFIG_IP6_NF_NAT=y
CONFIG_IP6_NF_TARGET_MASQUERADE=y
CONFIG_IP6_NF_TARGET_NPT=y
# end of IPv6: Netfilter Configuration

CONFIG_NF_DEFRAG_IPV6=y
CONFIG_NF_TABLES_BRIDGE=y
CONFIG_NFT_BRIDGE_META=y
CONFIG_NFT_BRIDGE_REJECT=y
CONFIG_NF_CONNTRACK_BRIDGE=y
CONFIG_BRIDGE_NF_EBTABLES_LEGACY=y
CONFIG_BRIDGE_NF_EBTABLES=y
CONFIG_BRIDGE_EBT_BROUTE=y
CONFIG_BRIDGE_EBT_T_FILTER=y
CONFIG_BRIDGE_EBT_T_NAT=y
CONFIG_BRIDGE_EBT_802_3=y
CONFIG_BRIDGE_EBT_AMONG=y
CONFIG_BRIDGE_EBT_ARP=y
CONFIG_BRIDGE_EBT_IP=y
CONFIG_BRIDGE_EBT_IP6=y
CONFIG_BRIDGE_EBT_LIMIT=y
CONFIG_BRIDGE_EBT_MARK=y
CONFIG_BRIDGE_EBT_PKTTYPE=y
CONFIG_BRIDGE_EBT_STP=y
CONFIG_BRIDGE_EBT_VLAN=y
CONFIG_BRIDGE_EBT_ARPREPLY=y
CONFIG_BRIDGE_EBT_DNAT=y
CONFIG_BRIDGE_EBT_MARK_T=y
CONFIG_BRIDGE_EBT_REDIRECT=y
CONFIG_BRIDGE_EBT_SNAT=y
CONFIG_BRIDGE_EBT_LOG=y
CONFIG_BRIDGE_EBT_NFLOG=y
CONFIG_IP_SCTP=y
# CONFIG_SCTP_DBG_OBJCNT is not set
CONFIG_SCTP_DEFAULT_COOKIE_HMAC_SHA256=y
# CONFIG_SCTP_DEFAULT_COOKIE_HMAC_NONE is not set
CONFIG_INET_SCTP_DIAG=y
CONFIG_RDS=y
CONFIG_RDS_RDMA=y
CONFIG_RDS_TCP=y
# CONFIG_RDS_DEBUG is not set
CONFIG_TIPC=y
CONFIG_TIPC_MEDIA_IB=y
CONFIG_TIPC_MEDIA_UDP=y
CONFIG_TIPC_CRYPTO=y
CONFIG_TIPC_DIAG=y
CONFIG_ATM=y
CONFIG_ATM_BR2684=y
# CONFIG_ATM_BR2684_IPFILTER is not set
CONFIG_L2TP=y
# CONFIG_L2TP_DEBUGFS is not set
CONFIG_L2TP_V3=y
CONFIG_L2TP_IP=y
CONFIG_L2TP_ETH=y
CONFIG_STP=y
CONFIG_GARP=y
CONFIG_MRP=y
CONFIG_BRIDGE=y
CONFIG_BRIDGE_IGMP_SNOOPING=y
CONFIG_BRIDGE_VLAN_FILTERING=y
CONFIG_BRIDGE_MRP=y
CONFIG_BRIDGE_CFM=y
CONFIG_NET_DSA=y
# CONFIG_NET_DSA_TAG_NONE is not set
# CONFIG_NET_DSA_TAG_AR9331 is not set
CONFIG_NET_DSA_TAG_BRCM_COMMON=y
CONFIG_NET_DSA_TAG_BRCM=y
# CONFIG_NET_DSA_TAG_BRCM_LEGACY is not set
# CONFIG_NET_DSA_TAG_BRCM_LEGACY_FCS is not set
CONFIG_NET_DSA_TAG_BRCM_PREPEND=y
# CONFIG_NET_DSA_TAG_HELLCREEK is not set
# CONFIG_NET_DSA_TAG_GSWIP is not set
# CONFIG_NET_DSA_TAG_DSA is not set
# CONFIG_NET_DSA_TAG_EDSA is not set
CONFIG_NET_DSA_TAG_MTK=y
# CONFIG_NET_DSA_TAG_MXL_862XX is not set
# CONFIG_NET_DSA_TAG_MXL_GSW1XX is not set
# CONFIG_NET_DSA_TAG_KSZ is not set
# CONFIG_NET_DSA_TAG_NETC is not set
# CONFIG_NET_DSA_TAG_OCELOT is not set
# CONFIG_NET_DSA_TAG_OCELOT_8021Q is not set
CONFIG_NET_DSA_TAG_QCA=y
CONFIG_NET_DSA_TAG_RTL4_A=y
# CONFIG_NET_DSA_TAG_RTL8_4 is not set
# CONFIG_NET_DSA_TAG_RZN1_A5PSW is not set
# CONFIG_NET_DSA_TAG_LAN9303 is not set
# CONFIG_NET_DSA_TAG_SJA1105 is not set
# CONFIG_NET_DSA_TAG_TRAILER is not set
# CONFIG_NET_DSA_TAG_VSC73XX_8021Q is not set
# CONFIG_NET_DSA_TAG_XRS700X is not set
# CONFIG_NET_DSA_TAG_YT921X is not set
CONFIG_VLAN_8021Q=y
CONFIG_VLAN_8021Q_GVRP=y
CONFIG_VLAN_8021Q_MVRP=y
CONFIG_LLC=y
CONFIG_LLC2=y
CONFIG_X25=y
CONFIG_LAPB=y
CONFIG_PHONET=y
CONFIG_6LOWPAN=y
# CONFIG_6LOWPAN_DEBUGFS is not set
CONFIG_6LOWPAN_NHC=y
CONFIG_6LOWPAN_NHC_DEST=y
CONFIG_6LOWPAN_NHC_FRAGMENT=y
CONFIG_6LOWPAN_NHC_HOP=y
CONFIG_6LOWPAN_NHC_IPV6=y
CONFIG_6LOWPAN_NHC_MOBILITY=y
CONFIG_6LOWPAN_NHC_ROUTING=y
CONFIG_6LOWPAN_NHC_UDP=y
CONFIG_6LOWPAN_GHC_EXT_HDR_HOP=y
CONFIG_6LOWPAN_GHC_UDP=y
CONFIG_6LOWPAN_GHC_ICMPV6=y
CONFIG_6LOWPAN_GHC_EXT_HDR_DEST=y
CONFIG_6LOWPAN_GHC_EXT_HDR_FRAG=y
CONFIG_6LOWPAN_GHC_EXT_HDR_ROUTE=y
CONFIG_IEEE802154=y
CONFIG_IEEE802154_NL802154_EXPERIMENTAL=y
CONFIG_IEEE802154_SOCKET=y
CONFIG_IEEE802154_6LOWPAN=y
CONFIG_MAC802154=y
CONFIG_NET_SCHED=y

#
# Queueing/Scheduling
#
CONFIG_NET_SCH_HTB=y
CONFIG_NET_SCH_HFSC=y
CONFIG_NET_SCH_PRIO=y
CONFIG_NET_SCH_MULTIQ=y
CONFIG_NET_SCH_RED=y
CONFIG_NET_SCH_SFB=y
CONFIG_NET_SCH_SFQ=y
CONFIG_NET_SCH_TEQL=y
CONFIG_NET_SCH_TBF=y
CONFIG_NET_SCH_CBS=y
CONFIG_NET_SCH_ETF=y
CONFIG_NET_SCH_MQPRIO_LIB=y
CONFIG_NET_SCH_TAPRIO=y
CONFIG_NET_SCH_GRED=y
CONFIG_NET_SCH_NETEM=y
CONFIG_NET_SCH_DRR=y
CONFIG_NET_SCH_MQPRIO=y
CONFIG_NET_SCH_SKBPRIO=y
CONFIG_NET_SCH_CHOKE=y
CONFIG_NET_SCH_QFQ=y
CONFIG_NET_SCH_CODEL=y
CONFIG_NET_SCH_FQ_CODEL=y
CONFIG_NET_SCH_CAKE=y
CONFIG_NET_SCH_FQ=y
CONFIG_NET_SCH_HHF=y
CONFIG_NET_SCH_PIE=y
CONFIG_NET_SCH_FQ_PIE=y
CONFIG_NET_SCH_INGRESS=y
CONFIG_NET_SCH_PLUG=y
CONFIG_NET_SCH_ETS=y
# CONFIG_NET_SCH_DUALPI2 is not set
CONFIG_NET_SCH_DEFAULT=y
# CONFIG_DEFAULT_FQ is not set
CONFIG_DEFAULT_CODEL=y
# CONFIG_DEFAULT_FQ_CODEL is not set
# CONFIG_DEFAULT_FQ_PIE is not set
# CONFIG_DEFAULT_SFQ is not set
# CONFIG_DEFAULT_PFIFO_FAST is not set
CONFIG_DEFAULT_NET_SCH="pfifo_fast"

#
# Classification
#
CONFIG_NET_CLS=y
CONFIG_NET_CLS_BASIC=y
CONFIG_NET_CLS_ROUTE4=y
CONFIG_NET_CLS_FW=y
CONFIG_NET_CLS_U32=y
CONFIG_CLS_U32_PERF=y
CONFIG_CLS_U32_MARK=y
CONFIG_NET_CLS_FLOW=y
CONFIG_NET_CLS_CGROUP=y
CONFIG_NET_CLS_BPF=y
CONFIG_NET_CLS_FLOWER=y
CONFIG_NET_CLS_MATCHALL=y
CONFIG_NET_EMATCH=y
CONFIG_NET_EMATCH_STACK=32
CONFIG_NET_EMATCH_CMP=y
CONFIG_NET_EMATCH_NBYTE=y
CONFIG_NET_EMATCH_U32=y
CONFIG_NET_EMATCH_META=y
CONFIG_NET_EMATCH_TEXT=y
CONFIG_NET_EMATCH_CANID=y
CONFIG_NET_EMATCH_IPSET=y
CONFIG_NET_EMATCH_IPT=y
CONFIG_NET_CLS_ACT=y
CONFIG_NET_ACT_POLICE=y
CONFIG_NET_ACT_GACT=y
CONFIG_GACT_PROB=y
CONFIG_NET_ACT_MIRRED=y
CONFIG_NET_ACT_SAMPLE=y
CONFIG_NET_ACT_NAT=y
CONFIG_NET_ACT_PEDIT=y
CONFIG_NET_ACT_SIMP=y
CONFIG_NET_ACT_SKBEDIT=y
CONFIG_NET_ACT_CSUM=y
CONFIG_NET_ACT_MPLS=y
CONFIG_NET_ACT_VLAN=y
CONFIG_NET_ACT_BPF=y
CONFIG_NET_ACT_CONNMARK=y
CONFIG_NET_ACT_CTINFO=y
CONFIG_NET_ACT_SKBMOD=y
CONFIG_NET_ACT_IFE=y
CONFIG_NET_ACT_TUNNEL_KEY=y
CONFIG_NET_ACT_CT=y
CONFIG_NET_ACT_GATE=y
CONFIG_NET_IFE_SKBMARK=y
CONFIG_NET_IFE_SKBPRIO=y
CONFIG_NET_IFE_SKBTCINDEX=y
CONFIG_NET_TC_SKB_EXT=y
CONFIG_NET_SCH_FIFO=y
CONFIG_DCB=y
CONFIG_DNS_RESOLVER=y
CONFIG_BATMAN_ADV=y
CONFIG_BATMAN_ADV_BATMAN_V=y
CONFIG_BATMAN_ADV_BLA=y
CONFIG_BATMAN_ADV_DAT=y
CONFIG_BATMAN_ADV_MCAST=y
# CONFIG_BATMAN_ADV_DEBUG is not set
# CONFIG_BATMAN_ADV_TRACING is not set
CONFIG_OPENVSWITCH=y
CONFIG_OPENVSWITCH_GRE=y
CONFIG_OPENVSWITCH_VXLAN=y
CONFIG_OPENVSWITCH_GENEVE=y
CONFIG_VSOCKETS=y
CONFIG_VSOCKETS_DIAG=y
CONFIG_VSOCKETS_LOOPBACK=y
# CONFIG_VMWARE_VMCI_VSOCKETS is not set
CONFIG_VIRTIO_VSOCKETS=y
CONFIG_VIRTIO_VSOCKETS_COMMON=y
CONFIG_NETLINK_DIAG=y
CONFIG_MPLS=y
CONFIG_NET_MPLS_GSO=y
CONFIG_MPLS_ROUTING=y
CONFIG_MPLS_IPTUNNEL=y
CONFIG_NET_NSH=y
CONFIG_HSR=y
CONFIG_NET_SWITCHDEV=y
CONFIG_NET_L3_MASTER_DEV=y
CONFIG_QRTR=y
CONFIG_QRTR_TUN=y
# CONFIG_QRTR_MHI is not set
CONFIG_NET_NCSI=y
# CONFIG_NCSI_OEM_CMD_GET_MAC is not set
# CONFIG_NCSI_OEM_CMD_KEEP_PHY is not set
# CONFIG_PCPU_DEV_REFCNT is not set
CONFIG_MAX_SKB_FRAGS=17
CONFIG_RPS=y
CONFIG_RFS_ACCEL=y
CONFIG_SOCK_RX_QUEUE_MAPPING=y
CONFIG_XPS=y
CONFIG_CGROUP_NET_PRIO=y
CONFIG_CGROUP_NET_CLASSID=y
CONFIG_NET_RX_BUSY_POLL=y
CONFIG_BQL=y
CONFIG_BPF_STREAM_PARSER=y
CONFIG_NET_FLOW_LIMIT=y

#
# Network testing
#
# CONFIG_NET_PKTGEN is not set
CONFIG_NET_DROP_MONITOR=y
# end of Network testing
# end of Networking options

CONFIG_CAN=y
CONFIG_CAN_RAW=y
CONFIG_CAN_BCM=y
CONFIG_CAN_GW=y
CONFIG_CAN_J1939=y
CONFIG_CAN_ISOTP=y
CONFIG_BT=y
CONFIG_BT_BREDR=y
CONFIG_BT_RFCOMM=y
CONFIG_BT_RFCOMM_TTY=y
CONFIG_BT_BNEP=y
CONFIG_BT_BNEP_MC_FILTER=y
CONFIG_BT_BNEP_PROTO_FILTER=y
CONFIG_BT_HIDP=y
CONFIG_BT_LE=y
CONFIG_BT_LE_L2CAP_ECRED=y
CONFIG_BT_6LOWPAN=y
CONFIG_BT_LEDS=y
CONFIG_BT_MSFTEXT=y
# CONFIG_BT_AOSPEXT is not set
# CONFIG_BT_DEBUGFS is not set
# CONFIG_BT_SELFTEST is not set

#
# Bluetooth device drivers
#
CONFIG_BT_INTEL=y
CONFIG_BT_BCM=y
CONFIG_BT_RTL=y
CONFIG_BT_QCA=y
CONFIG_BT_MTK=y
CONFIG_BT_HCIBTUSB=y
CONFIG_BT_HCIBTUSB_AUTOSUSPEND=y
CONFIG_BT_HCIBTUSB_POLL_SYNC=y
CONFIG_BT_HCIBTUSB_BCM=y
CONFIG_BT_HCIBTUSB_MTK=y
CONFIG_BT_HCIBTUSB_RTL=y
# CONFIG_BT_HCIBTSDIO is not set
CONFIG_BT_HCIUART=y
CONFIG_BT_HCIUART_SERDEV=y
CONFIG_BT_HCIUART_H4=y
# CONFIG_BT_HCIUART_NOKIA is not set
CONFIG_BT_HCIUART_BCSP=y
# CONFIG_BT_HCIUART_ATH3K is not set
CONFIG_BT_HCIUART_LL=y
CONFIG_BT_HCIUART_3WIRE=y
# CONFIG_BT_HCIUART_INTEL is not set
# CONFIG_BT_HCIUART_BCM is not set
# CONFIG_BT_HCIUART_RTL is not set
CONFIG_BT_HCIUART_QCA=y
CONFIG_BT_HCIUART_AG6XX=y
CONFIG_BT_HCIUART_MRVL=y
# CONFIG_BT_HCIUART_AML is not set
CONFIG_BT_HCIBCM203X=y
# CONFIG_BT_HCIBCM4377 is not set
CONFIG_BT_HCIBPA10X=y
CONFIG_BT_HCIBFUSB=y
CONFIG_BT_HCIVHCI=y
CONFIG_BT_MRVL=y
CONFIG_BT_MRVL_SDIO=y
CONFIG_BT_ATH3K=y
CONFIG_BT_MTKSDIO=y
CONFIG_BT_MTKUART=y
# CONFIG_BT_VIRTIO is not set
# CONFIG_BT_NXPUART is not set
# CONFIG_BT_INTEL_PCIE is not set
# end of Bluetooth device drivers

CONFIG_AF_RXRPC=y
CONFIG_AF_RXRPC_IPV6=y
# CONFIG_AF_RXRPC_INJECT_LOSS is not set
# CONFIG_AF_RXRPC_INJECT_RX_DELAY is not set
# CONFIG_AF_RXRPC_DEBUG is not set
CONFIG_RXKAD=y
# CONFIG_RXGK is not set
# CONFIG_RXPERF is not set
CONFIG_AF_KCM=y
CONFIG_STREAM_PARSER=y
CONFIG_MCTP=y
CONFIG_FIB_RULES=y
CONFIG_WIRELESS=y
CONFIG_WEXT_CORE=y
CONFIG_WEXT_PROC=y
CONFIG_CFG80211=y
# CONFIG_NL80211_TESTMODE is not set
# CONFIG_CFG80211_DEVELOPER_WARNINGS is not set
# CONFIG_CFG80211_CERTIFICATION_ONUS is not set
CONFIG_CFG80211_REQUIRE_SIGNED_REGDB=y
CONFIG_CFG80211_USE_KERNEL_REGDB_KEYS=y
CONFIG_CFG80211_DEFAULT_PS=y
CONFIG_CFG80211_DEBUGFS=y
CONFIG_CFG80211_CRDA_SUPPORT=y
CONFIG_CFG80211_WEXT=y
CONFIG_MAC80211=y
CONFIG_MAC80211_HAS_RC=y
CONFIG_MAC80211_RC_MINSTREL=y
CONFIG_MAC80211_RC_DEFAULT_MINSTREL=y
CONFIG_MAC80211_RC_DEFAULT="minstrel_ht"
CONFIG_MAC80211_MESH=y
CONFIG_MAC80211_LEDS=y
CONFIG_MAC80211_DEBUGFS=y
# CONFIG_MAC80211_MESSAGE_TRACING is not set
# CONFIG_MAC80211_DEBUG_MENU is not set
CONFIG_MAC80211_STA_HASH_MAX_SIZE=0
CONFIG_RFKILL=y
CONFIG_RFKILL_LEDS=y
CONFIG_RFKILL_INPUT=y
# CONFIG_RFKILL_GPIO is not set
CONFIG_NET_9P=y
CONFIG_NET_9P_FD=y
CONFIG_NET_9P_VIRTIO=y
# CONFIG_NET_9P_USBG is not set
CONFIG_NET_9P_RDMA=y
# CONFIG_NET_9P_DEBUG is not set
CONFIG_CEPH_LIB=y
# CONFIG_CEPH_LIB_PRETTYDEBUG is not set
CONFIG_CEPH_LIB_USE_DNS_RESOLVER=y
CONFIG_NFC=y
CONFIG_NFC_DIGITAL=y
CONFIG_NFC_NCI=y
# CONFIG_NFC_NCI_SPI is not set
CONFIG_NFC_NCI_UART=y
CONFIG_NFC_HCI=y
CONFIG_NFC_SHDLC=y

#
# Near Field Communication (NFC) devices
#
# CONFIG_NFC_TRF7970A is not set
# CONFIG_NFC_MEI_PHY is not set
CONFIG_NFC_SIM=y
CONFIG_NFC_PORT100=y
CONFIG_NFC_VIRTUAL_NCI=y
CONFIG_NFC_FDP=y
# CONFIG_NFC_FDP_I2C is not set
# CONFIG_NFC_PN544_I2C is not set
CONFIG_NFC_PN533=y
CONFIG_NFC_PN533_USB=y
# CONFIG_NFC_PN533_I2C is not set
# CONFIG_NFC_PN532_UART is not set
# CONFIG_NFC_MICROREAD_I2C is not set
CONFIG_NFC_MRVL=y
CONFIG_NFC_MRVL_USB=y
# CONFIG_NFC_MRVL_UART is not set
# CONFIG_NFC_MRVL_I2C is not set
# CONFIG_NFC_ST21NFCA_I2C is not set
# CONFIG_NFC_ST_NCI_I2C is not set
# CONFIG_NFC_ST_NCI_SPI is not set
# CONFIG_NFC_NXP_NCI is not set
# CONFIG_NFC_S3FWRN5_I2C is not set
# CONFIG_NFC_S3FWRN82_UART is not set
# CONFIG_NFC_ST95HF is not set
# end of Near Field Communication (NFC) devices

CONFIG_PSAMPLE=y
CONFIG_NET_IFE=y
CONFIG_LWTUNNEL=y
CONFIG_LWTUNNEL_BPF=y
CONFIG_DST_CACHE=y
CONFIG_GRO_CELLS=y
CONFIG_SOCK_VALIDATE_XMIT=y
CONFIG_NET_SELFTESTS=y
CONFIG_NET_SOCK_MSG=y
CONFIG_NET_DEVLINK=y
CONFIG_PAGE_POOL=y
# CONFIG_PAGE_POOL_STATS is not set
CONFIG_FAILOVER=y
CONFIG_ETHTOOL_NETLINK=y

#
# Device Drivers
#
CONFIG_HAVE_PCI=y
CONFIG_GENERIC_PCI_IOMAP=y
CONFIG_PCI=y
CONFIG_PCI_DOMAINS=y
CONFIG_PCIEPORTBUS=y
CONFIG_HOTPLUG_PCI_PCIE=y
CONFIG_PCIEAER=y
# CONFIG_PCIEAER_INJECT is not set
# CONFIG_PCIE_ECRC is not set
CONFIG_PCIEASPM=y
CONFIG_PCIEASPM_DEFAULT=y
# CONFIG_PCIEASPM_POWERSAVE is not set
# CONFIG_PCIEASPM_POWER_SUPERSAVE is not set
# CONFIG_PCIEASPM_PERFORMANCE is not set
CONFIG_PCIE_PME=y
# CONFIG_PCIE_DPC is not set
# CONFIG_PCIE_PTM is not set
CONFIG_PCI_MSI=y
CONFIG_PCI_QUIRKS=y
# CONFIG_PCI_DEBUG is not set
# CONFIG_PCI_REALLOC_ENABLE_AUTO is not set
# CONFIG_PCI_STUB is not set
# CONFIG_PCI_PF_STUB is not set
CONFIG_PCI_ATS=y
# CONFIG_PCI_TSM is not set
# CONFIG_PCI_DOE is not set
CONFIG_PCI_ECAM=y
CONFIG_PCI_LOCKLESS_CONFIG=y
CONFIG_PCI_IOV=y
# CONFIG_PCI_NPEM is not set
CONFIG_PCI_PRI=y
CONFIG_PCI_PASID=y
# CONFIG_PCIE_TPH is not set
# CONFIG_PCI_P2PDMA is not set
CONFIG_PCI_LABEL=y
# CONFIG_PCI_DYNAMIC_OF_NODES is not set
CONFIG_VGA_ARB=y
CONFIG_VGA_ARB_MAX_GPUS=16
CONFIG_HOTPLUG_PCI=y
# CONFIG_HOTPLUG_PCI_ACPI is not set
# CONFIG_HOTPLUG_PCI_CPCI is not set
# CONFIG_HOTPLUG_PCI_OCTEONEP is not set
# CONFIG_HOTPLUG_PCI_SHPC is not set

#
# PCI controller drivers
#
CONFIG_PCI_HOST_COMMON=y
# CONFIG_PCI_FTPCI100 is not set
CONFIG_PCI_HOST_GENERIC=y
# CONFIG_VMD is not set
# CONFIG_PCIE_XILINX is not set

#
# Cadence-based PCIe controllers
#
# CONFIG_PCIE_CADENCE_PLAT_HOST is not set
# CONFIG_PCIE_CADENCE_PLAT_EP is not set
# end of Cadence-based PCIe controllers

#
# DesignWare-based PCIe controllers
#
# CONFIG_PCI_MESON is not set
# CONFIG_PCIE_INTEL_GW is not set
# CONFIG_PCIE_DW_PLAT_HOST is not set
# CONFIG_PCIE_DW_PLAT_EP is not set
# end of DesignWare-based PCIe controllers

#
# Mobiveil-based PCIe controllers
#
# end of Mobiveil-based PCIe controllers

#
# PLDA-based PCIe controllers
#
# CONFIG_PCIE_MICROCHIP_HOST is not set
# end of PLDA-based PCIe controllers
# end of PCI controller drivers

#
# PCI Endpoint
#
CONFIG_PCI_ENDPOINT=y
# CONFIG_PCI_ENDPOINT_CONFIGFS is not set
# CONFIG_PCI_ENDPOINT_MSI_DOORBELL is not set
# CONFIG_PCI_EPF_TEST is not set
# CONFIG_PCI_EPF_NTB is not set
# end of PCI Endpoint

#
# PCI switch controller drivers
#
# CONFIG_PCI_SW_SWITCHTEC is not set
# end of PCI switch controller drivers

# CONFIG_PCI_PWRCTRL_GENERIC is not set
# CONFIG_PCI_PWRCTRL_TC9563 is not set
# CONFIG_CXL_BUS is not set
CONFIG_PCCARD=y
CONFIG_PCMCIA=y
CONFIG_PCMCIA_LOAD_CIS=y
CONFIG_CARDBUS=y

#
# PC-card bridges
#
CONFIG_YENTA=y
CONFIG_YENTA_O2=y
CONFIG_YENTA_RICOH=y
CONFIG_YENTA_TI=y
CONFIG_YENTA_ENE_TUNE=y
CONFIG_YENTA_TOSHIBA=y
# CONFIG_PD6729 is not set
CONFIG_PCCARD_NONSTATIC=y
# CONFIG_RAPIDIO is not set
# CONFIG_PC104 is not set

#
# Generic Driver Options
#
CONFIG_AUXILIARY_BUS=y
CONFIG_UEVENT_HELPER=y
CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y
# CONFIG_DEVTMPFS_SAFE is not set
CONFIG_DRIVER_DEFERRED_PROBE_TIMEOUT=10
CONFIG_STANDALONE=y
CONFIG_PREVENT_FIRMWARE_BUILD=y

#
# Firmware loader
#
CONFIG_FW_LOADER=y
# CONFIG_FW_LOADER_DEBUG is not set
CONFIG_FW_LOADER_PAGED_BUF=y
CONFIG_FW_LOADER_SYSFS=y
CONFIG_EXTRA_FIRMWARE=""
CONFIG_FW_LOADER_USER_HELPER=y
CONFIG_FW_LOADER_USER_HELPER_FALLBACK=y
CONFIG_FW_LOADER_COMPRESS=y
# CONFIG_FW_LOADER_COMPRESS_XZ is not set
# CONFIG_FW_LOADER_COMPRESS_ZSTD is not set
CONFIG_FW_CACHE=y
# CONFIG_FW_UPLOAD is not set
# end of Firmware loader

CONFIG_WANT_DEV_COREDUMP=y
CONFIG_ALLOW_DEV_COREDUMP=y
CONFIG_DEV_COREDUMP=y
# CONFIG_DEBUG_DRIVER is not set
CONFIG_DEBUG_DEVRES=y
# CONFIG_DEBUG_TEST_DRIVER_REMOVE is not set
# CONFIG_TEST_ASYNC_DRIVER_PROBE is not set
CONFIG_GENERIC_CPU_DEVICES=y
CONFIG_GENERIC_CPU_AUTOPROBE=y
CONFIG_GENERIC_CPU_VULNERABILITIES=y
CONFIG_REGMAP=y
CONFIG_REGMAP_I2C=y
CONFIG_REGMAP_SPI=y
CONFIG_REGMAP_MMIO=y
CONFIG_REGMAP_IRQ=y
CONFIG_DMA_SHARED_BUFFER=y
# CONFIG_DMA_FENCE_TRACE is not set
# CONFIG_FW_DEVLINK_SYNC_STATE_TIMEOUT is not set
# end of Generic Driver Options

#
# Bus devices
#
# CONFIG_MOXTET is not set
CONFIG_MHI_BUS=y
# CONFIG_MHI_BUS_DEBUG is not set
# CONFIG_MHI_BUS_PCI_GENERIC is not set
# CONFIG_MHI_BUS_EP is not set
# end of Bus devices

CONFIG_CONNECTOR=y
CONFIG_PROC_EVENTS=y

#
# Firmware Drivers
#

#
# ARM System Control and Management Interface Protocol
#
# end of ARM System Control and Management Interface Protocol

# CONFIG_EDD is not set
CONFIG_FIRMWARE_MEMMAP=y
CONFIG_DMIID=y
# CONFIG_DMI_SYSFS is not set
CONFIG_DMI_SCAN_MACHINE_NON_EFI_FALLBACK=y
# CONFIG_ISCSI_IBFT is not set
# CONFIG_FW_CFG_SYSFS is not set
CONFIG_SYSFB=y
# CONFIG_SYSFB_SIMPLEFB is not set
CONFIG_GOOGLE_FIRMWARE=y
# CONFIG_GOOGLE_SMI is not set
# CONFIG_GOOGLE_CBMEM is not set
CONFIG_GOOGLE_COREBOOT_TABLE=y
CONFIG_GOOGLE_MEMCONSOLE=y
# CONFIG_GOOGLE_MEMCONSOLE_X86_LEGACY is not set
# CONFIG_GOOGLE_FRAMEBUFFER_COREBOOT is not set
CONFIG_GOOGLE_MEMCONSOLE_COREBOOT=y
CONFIG_GOOGLE_VPD=y

#
# Qualcomm firmware drivers
#
# end of Qualcomm firmware drivers

#
# Tegra firmware driver
#
# end of Tegra firmware driver
# end of Firmware Drivers

# CONFIG_FWCTL is not set
CONFIG_GNSS=y
# CONFIG_GNSS_MTK_SERIAL is not set
# CONFIG_GNSS_SIRF_SERIAL is not set
# CONFIG_GNSS_UBX_SERIAL is not set
CONFIG_GNSS_USB=y
CONFIG_MTD=y
# CONFIG_MTD_TESTS is not set

#
# Partition parsers
#
# CONFIG_MTD_CMDLINE_PARTS is not set
# CONFIG_MTD_OF_PARTS is not set
# CONFIG_MTD_REDBOOT_PARTS is not set
# end of Partition parsers

#
# User Modules And Translation Layers
#
CONFIG_MTD_BLKDEVS=y
CONFIG_MTD_BLOCK=y

#
# Note that in some cases UBI block is preferred. See MTD_UBI_BLOCK.
#
CONFIG_FTL=y
# CONFIG_NFTL is not set
# CONFIG_INFTL is not set
# CONFIG_RFD_FTL is not set
# CONFIG_SSFDC is not set
# CONFIG_SM_FTL is not set
# CONFIG_MTD_OOPS is not set
# CONFIG_MTD_SWAP is not set
# CONFIG_MTD_PARTITIONED_MASTER is not set

#
# RAM/ROM/Flash chip drivers
#
# CONFIG_MTD_CFI is not set
# CONFIG_MTD_JEDECPROBE is not set
CONFIG_MTD_MAP_BANK_WIDTH_1=y
CONFIG_MTD_MAP_BANK_WIDTH_2=y
CONFIG_MTD_MAP_BANK_WIDTH_4=y
CONFIG_MTD_CFI_I1=y
CONFIG_MTD_CFI_I2=y
# CONFIG_MTD_RAM is not set
# CONFIG_MTD_ROM is not set
# CONFIG_MTD_ABSENT is not set
# end of RAM/ROM/Flash chip drivers

#
# Mapping drivers for chip access
#
# CONFIG_MTD_COMPLEX_MAPPINGS is not set
# CONFIG_MTD_PLATRAM is not set
# end of Mapping drivers for chip access

#
# Self-contained MTD device drivers
#
# CONFIG_MTD_PMC551 is not set
# CONFIG_MTD_DATAFLASH is not set
# CONFIG_MTD_MCHP23K256 is not set
# CONFIG_MTD_MCHP48L640 is not set
# CONFIG_MTD_SST25L is not set
CONFIG_MTD_SLRAM=y
CONFIG_MTD_PHRAM=y
CONFIG_MTD_MTDRAM=y
CONFIG_MTDRAM_TOTAL_SIZE=128
CONFIG_MTDRAM_ERASE_SIZE=4
CONFIG_MTD_BLOCK2MTD=y
# CONFIG_MTD_INTEL_DG is not set

#
# Disk-On-Chip Device Drivers
#
# CONFIG_MTD_DOCG3 is not set
# end of Self-contained MTD device drivers

#
# NAND
#
# CONFIG_MTD_ONENAND is not set
# CONFIG_MTD_RAW_NAND is not set
# CONFIG_MTD_SPI_NAND is not set

#
# ECC engine support
#
# CONFIG_MTD_NAND_ECC_SW_HAMMING is not set
# CONFIG_MTD_NAND_ECC_SW_BCH is not set
# CONFIG_MTD_NAND_ECC_MXIC is not set
# end of ECC engine support
# end of NAND

#
# LPDDR & LPDDR2 PCM memory drivers
#
# CONFIG_MTD_LPDDR is not set
# end of LPDDR & LPDDR2 PCM memory drivers

# CONFIG_MTD_SPI_NOR is not set
CONFIG_MTD_UBI=y
CONFIG_MTD_UBI_WL_THRESHOLD=4096
CONFIG_MTD_UBI_BEB_LIMIT=20
# CONFIG_MTD_UBI_FASTMAP is not set
# CONFIG_MTD_UBI_GLUEBI is not set
# CONFIG_MTD_UBI_BLOCK is not set
# CONFIG_MTD_UBI_FAULT_INJECTION is not set
# CONFIG_MTD_UBI_NVMEM is not set
# CONFIG_MTD_HYPERBUS is not set
CONFIG_DTC=y
CONFIG_OF=y
# CONFIG_OF_UNITTEST is not set
CONFIG_OF_FLATTREE=y
CONFIG_OF_EARLY_FLATTREE=y
CONFIG_OF_KOBJ=y
CONFIG_OF_ADDRESS=y
CONFIG_OF_IRQ=y
CONFIG_OF_RESERVED_MEM=y
# CONFIG_OF_OVERLAY is not set
CONFIG_OF_NUMA=y
CONFIG_ARCH_MIGHT_HAVE_PC_PARPORT=y
CONFIG_PARPORT=y
# CONFIG_PARPORT_PC is not set
# CONFIG_PARPORT_1284 is not set
CONFIG_PARPORT_NOT_PC=y
CONFIG_PNP=y
CONFIG_PNP_DEBUG_MESSAGES=y

#
# Protocols
#
CONFIG_PNPACPI=y
CONFIG_BLK_DEV=y
CONFIG_BLK_DEV_NULL_BLK=y
CONFIG_BLK_DEV_NULL_BLK_FAULT_INJECTION=y
# CONFIG_BLK_DEV_FD is not set
CONFIG_CDROM=y
# CONFIG_BLK_DEV_PCIESSD_MTIP32XX is not set
CONFIG_ZRAM=y
# CONFIG_ZRAM_BACKEND_LZ4 is not set
# CONFIG_ZRAM_BACKEND_LZ4HC is not set
# CONFIG_ZRAM_BACKEND_ZSTD is not set
# CONFIG_ZRAM_BACKEND_DEFLATE is not set
# CONFIG_ZRAM_BACKEND_842 is not set
CONFIG_ZRAM_BACKEND_FORCE_LZO=y
CONFIG_ZRAM_BACKEND_LZO=y
# CONFIG_ZRAM_DEF_COMP_LZORLE is not set
CONFIG_ZRAM_DEF_COMP_LZO=y
CONFIG_ZRAM_DEF_COMP="lzo"
# CONFIG_ZRAM_WRITEBACK is not set
# CONFIG_ZRAM_TRACK_ENTRY_ACTIME is not set
# CONFIG_ZRAM_MEMORY_TRACKING is not set
# CONFIG_ZRAM_MULTI_COMP is not set
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_LOOP_MIN_COUNT=16
# CONFIG_BLK_DEV_DRBD is not set
CONFIG_BLK_DEV_NBD=y
CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_COUNT=16
CONFIG_BLK_DEV_RAM_SIZE=4096
CONFIG_ATA_OVER_ETH=y
CONFIG_VIRTIO_BLK=y
# CONFIG_BLK_DEV_RBD is not set
CONFIG_BLK_DEV_UBLK=y
CONFIG_BLKDEV_UBLK_LEGACY_OPCODES=y
CONFIG_BLK_DEV_RNBD=y
CONFIG_BLK_DEV_RNBD_CLIENT=y
# CONFIG_BLK_DEV_ZONED_LOOP is not set

#
# NVME Support
#
CONFIG_NVME_CORE=y
CONFIG_BLK_DEV_NVME=y
CONFIG_NVME_MULTIPATH=y
# CONFIG_NVME_VERBOSE_ERRORS is not set
# CONFIG_NVME_HWMON is not set
CONFIG_NVME_FABRICS=y
CONFIG_NVME_RDMA=y
CONFIG_NVME_FC=y
CONFIG_NVME_TCP=y
# CONFIG_NVME_TCP_TLS is not set
# CONFIG_NVME_HOST_AUTH is not set
CONFIG_NVME_TARGET=y
# CONFIG_NVME_TARGET_DEBUGFS is not set
# CONFIG_NVME_TARGET_PASSTHRU is not set
CONFIG_NVME_TARGET_LOOP=y
CONFIG_NVME_TARGET_RDMA=y
CONFIG_NVME_TARGET_FC=y
CONFIG_NVME_TARGET_FCLOOP=y
CONFIG_NVME_TARGET_TCP=y
# CONFIG_NVME_TARGET_TCP_TLS is not set
# CONFIG_NVME_TARGET_AUTH is not set
# CONFIG_NVME_TARGET_PCI_EPF is not set
# end of NVME Support

#
# Misc devices
#
# CONFIG_AD525X_DPOT is not set
# CONFIG_DUMMY_IRQ is not set
# CONFIG_IBM_ASM is not set
# CONFIG_PHANTOM is not set
# CONFIG_RPMB is not set
# CONFIG_TI_FPC202 is not set
# CONFIG_TIFM_CORE is not set
# CONFIG_ICS932S401 is not set
# CONFIG_ENCLOSURE_SERVICES is not set
# CONFIG_HP_ILO is not set
# CONFIG_APDS9802ALS is not set
# CONFIG_ISL29003 is not set
# CONFIG_ISL29020 is not set
# CONFIG_SENSORS_TSL2550 is not set
# CONFIG_SENSORS_BH1770 is not set
# CONFIG_HMC6352 is not set
# CONFIG_DS1682 is not set
# CONFIG_VMWARE_BALLOON is not set
# CONFIG_LATTICE_ECP3_CONFIG is not set
# CONFIG_SRAM is not set
# CONFIG_DW_XDATA_PCIE is not set
# CONFIG_PCI_ENDPOINT_TEST is not set
# CONFIG_XILINX_SDFEC is not set
CONFIG_MISC_RTSX=y
# CONFIG_HISI_HIKEY_USB is not set
# CONFIG_OPEN_DICE is not set
# CONFIG_NTSYNC is not set
# CONFIG_VCPU_STALL_DETECTOR is not set
# CONFIG_NSM is not set
# CONFIG_C2PORT is not set

#
# EEPROM support
#
# CONFIG_EEPROM_AT24 is not set
# CONFIG_EEPROM_AT25 is not set
# CONFIG_EEPROM_MAX6875 is not set
CONFIG_EEPROM_93CX6=y
# CONFIG_EEPROM_93XX46 is not set
# CONFIG_EEPROM_IDT_89HPESX is not set
# CONFIG_EEPROM_EE1004 is not set
# CONFIG_EEPROM_M24LR is not set
# end of EEPROM support

# CONFIG_CB710_CORE is not set
# CONFIG_SENSORS_LIS3_I2C is not set
# CONFIG_ALTERA_STAPL is not set
CONFIG_INTEL_MEI=y
CONFIG_INTEL_MEI_ME=y
# CONFIG_INTEL_MEI_TXE is not set
# CONFIG_INTEL_MEI_GSC is not set
# CONFIG_INTEL_MEI_CSC is not set
# CONFIG_INTEL_MEI_VSC_HW is not set
# CONFIG_INTEL_MEI_HDCP is not set
# CONFIG_INTEL_MEI_PXP is not set
# CONFIG_INTEL_MEI_GSC_PROXY is not set
CONFIG_VMWARE_VMCI=y
# CONFIG_GENWQE is not set
# CONFIG_BCM_VK is not set
# CONFIG_MISC_ALCOR_PCI is not set
# CONFIG_MISC_RTSX_PCI is not set
CONFIG_MISC_RTSX_USB=y
# CONFIG_UACCE is not set
# CONFIG_PVPANIC is not set
# CONFIG_GP_PCI1XXXX is not set
# CONFIG_KEBA_CP500 is not set
# CONFIG_MISC_RP1 is not set
# end of Misc devices

#
# SCSI device support
#
CONFIG_SCSI_MOD=y
CONFIG_RAID_ATTRS=y
CONFIG_SCSI_COMMON=y
CONFIG_SCSI=y
CONFIG_SCSI_DMA=y
CONFIG_SCSI_NETLINK=y
CONFIG_SCSI_PROC_FS=y

#
# SCSI support type (disk, tape, CD-ROM)
#
CONFIG_BLK_DEV_SD=y
CONFIG_CHR_DEV_ST=y
CONFIG_BLK_DEV_SR=y
CONFIG_CHR_DEV_SG=y
CONFIG_BLK_DEV_BSG=y
# CONFIG_CHR_DEV_SCH is not set
CONFIG_SCSI_CONSTANTS=y
CONFIG_SCSI_LOGGING=y
CONFIG_SCSI_SCAN_ASYNC=y

#
# SCSI Transports
#
CONFIG_SCSI_SPI_ATTRS=y
CONFIG_SCSI_FC_ATTRS=y
CONFIG_SCSI_ISCSI_ATTRS=y
CONFIG_SCSI_SAS_ATTRS=y
CONFIG_SCSI_SAS_LIBSAS=y
CONFIG_SCSI_SAS_ATA=y
# CONFIG_SCSI_SAS_HOST_SMP is not set
CONFIG_SCSI_SRP_ATTRS=y
# end of SCSI Transports

CONFIG_SCSI_LOWLEVEL=y
# CONFIG_ISCSI_TCP is not set
# CONFIG_ISCSI_BOOT_SYSFS is not set
# CONFIG_SCSI_CXGB3_ISCSI is not set
# CONFIG_SCSI_CXGB4_ISCSI is not set
# CONFIG_SCSI_BNX2_ISCSI is not set
# CONFIG_BE2ISCSI is not set
# CONFIG_BLK_DEV_3W_XXXX_RAID is not set
CONFIG_SCSI_HPSA=y
# CONFIG_SCSI_3W_9XXX is not set
# CONFIG_SCSI_3W_SAS is not set
# CONFIG_SCSI_ACARD is not set
# CONFIG_SCSI_AACRAID is not set
# CONFIG_SCSI_AIC7XXX is not set
# CONFIG_SCSI_AIC79XX is not set
# CONFIG_SCSI_AIC94XX is not set
# CONFIG_SCSI_MVSAS is not set
# CONFIG_SCSI_MVUMI is not set
# CONFIG_SCSI_ADVANSYS is not set
# CONFIG_SCSI_ARCMSR is not set
# CONFIG_SCSI_ESAS2R is not set
# CONFIG_MEGARAID_NEWGEN is not set
# CONFIG_MEGARAID_LEGACY is not set
# CONFIG_MEGARAID_SAS is not set
# CONFIG_SCSI_MPT3SAS is not set
# CONFIG_SCSI_MPT2SAS is not set
# CONFIG_SCSI_MPI3MR is not set
# CONFIG_SCSI_SMARTPQI is not set
# CONFIG_SCSI_HPTIOP is not set
# CONFIG_SCSI_BUSLOGIC is not set
# CONFIG_SCSI_MYRB is not set
# CONFIG_SCSI_MYRS is not set
# CONFIG_VMWARE_PVSCSI is not set
# CONFIG_LIBFC is not set
# CONFIG_SCSI_SNIC is not set
# CONFIG_SCSI_DMX3191D is not set
# CONFIG_SCSI_FDOMAIN_PCI is not set
# CONFIG_SCSI_ISCI is not set
# CONFIG_SCSI_IPS is not set
# CONFIG_SCSI_INITIO is not set
# CONFIG_SCSI_INIA100 is not set
# CONFIG_SCSI_STEX is not set
# CONFIG_SCSI_SYM53C8XX_2 is not set
# CONFIG_SCSI_IPR is not set
# CONFIG_SCSI_QLOGIC_1280 is not set
# CONFIG_SCSI_QLA_FC is not set
# CONFIG_SCSI_QLA_ISCSI is not set
# CONFIG_SCSI_LPFC is not set
# CONFIG_SCSI_EFCT is not set
# CONFIG_SCSI_DC395x is not set
# CONFIG_SCSI_AM53C974 is not set
# CONFIG_SCSI_WD719X is not set
# CONFIG_SCSI_DEBUG is not set
# CONFIG_SCSI_PMCRAID is not set
# CONFIG_SCSI_PM8001 is not set
# CONFIG_SCSI_BFA_FC is not set
CONFIG_SCSI_VIRTIO=y
# CONFIG_SCSI_CHELSIO_FCOE is not set
# CONFIG_SCSI_LOWLEVEL_PCMCIA is not set
# CONFIG_SCSI_DH is not set
# end of SCSI device support

CONFIG_ATA=y
CONFIG_SATA_HOST=y
CONFIG_PATA_TIMINGS=y
CONFIG_ATA_VERBOSE_ERROR=y
CONFIG_ATA_FORCE=y
CONFIG_ATA_ACPI=y
# CONFIG_SATA_ZPODD is not set
CONFIG_SATA_PMP=y

#
# Controllers with non-SFF native interface
#
CONFIG_SATA_AHCI=y
CONFIG_SATA_MOBILE_LPM_POLICY=3
# CONFIG_SATA_AHCI_PLATFORM is not set
# CONFIG_AHCI_DWC is not set
# CONFIG_AHCI_CEVA is not set
# CONFIG_SATA_INIC162X is not set
# CONFIG_SATA_ACARD_AHCI is not set
# CONFIG_SATA_SIL24 is not set
CONFIG_ATA_SFF=y

#
# SFF controllers with custom DMA interface
#
# CONFIG_PDC_ADMA is not set
# CONFIG_SATA_QSTOR is not set
# CONFIG_SATA_SX4 is not set
CONFIG_ATA_BMDMA=y

#
# SATA SFF controllers with BMDMA
#
CONFIG_ATA_PIIX=y
# CONFIG_SATA_DWC is not set
# CONFIG_SATA_MV is not set
# CONFIG_SATA_NV is not set
# CONFIG_SATA_PROMISE is not set
# CONFIG_SATA_SIL is not set
# CONFIG_SATA_SIS is not set
# CONFIG_SATA_SVW is not set
# CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set
# CONFIG_SATA_VITESSE is not set

#
# PATA SFF controllers with BMDMA
#
# CONFIG_PATA_ALI is not set
CONFIG_PATA_AMD=y
# CONFIG_PATA_ARTOP is not set
# CONFIG_PATA_ATIIXP is not set
# CONFIG_PATA_ATP867X is not set
# CONFIG_PATA_CMD64X is not set
# CONFIG_PATA_CYPRESS is not set
# CONFIG_PATA_EFAR is not set
# CONFIG_PATA_HPT366 is not set
# CONFIG_PATA_HPT37X is not set
# CONFIG_PATA_HPT3X2N is not set
# CONFIG_PATA_HPT3X3 is not set
# CONFIG_PATA_IT8213 is not set
# CONFIG_PATA_IT821X is not set
# CONFIG_PATA_JMICRON is not set
# CONFIG_PATA_MARVELL is not set
# CONFIG_PATA_NETCELL is not set
# CONFIG_PATA_NINJA32 is not set
# CONFIG_PATA_NS87415 is not set
CONFIG_PATA_OLDPIIX=y
# CONFIG_PATA_OPTIDMA is not set
# CONFIG_PATA_PDC2027X is not set
# CONFIG_PATA_PDC_OLD is not set
# CONFIG_PATA_RADISYS is not set
# CONFIG_PATA_RDC is not set
CONFIG_PATA_SCH=y
# CONFIG_PATA_SERVERWORKS is not set
# CONFIG_PATA_SIL680 is not set
# CONFIG_PATA_SIS is not set
# CONFIG_PATA_TOSHIBA is not set
# CONFIG_PATA_TRIFLEX is not set
# CONFIG_PATA_VIA is not set
# CONFIG_PATA_WINBOND is not set

#
# PIO-only SFF controllers
#
# CONFIG_PATA_CMD640_PCI is not set
# CONFIG_PATA_MPIIX is not set
# CONFIG_PATA_NS87410 is not set
# CONFIG_PATA_OPTI is not set
# CONFIG_PATA_PCMCIA is not set
# CONFIG_PATA_OF_PLATFORM is not set
# CONFIG_PATA_RZ1000 is not set

#
# Generic fallback / legacy drivers
#
# CONFIG_PATA_ACPI is not set
CONFIG_ATA_GENERIC=y
# CONFIG_PATA_LEGACY is not set
CONFIG_MD=y
CONFIG_BLK_DEV_MD=y
CONFIG_MD_BITMAP=y
# CONFIG_MD_LLBITMAP is not set
CONFIG_MD_AUTODETECT=y
CONFIG_MD_BITMAP_FILE=y
# CONFIG_MD_LINEAR is not set
CONFIG_MD_RAID0=y
CONFIG_MD_RAID1=y
CONFIG_MD_RAID10=y
CONFIG_MD_RAID456=y
# CONFIG_MD_CLUSTER is not set
CONFIG_BCACHE=y
# CONFIG_BCACHE_DEBUG is not set
# CONFIG_BCACHE_ASYNC_REGISTRATION is not set
CONFIG_BLK_DEV_DM_BUILTIN=y
CONFIG_BLK_DEV_DM=y
# CONFIG_DM_DEBUG is not set
CONFIG_DM_BUFIO=y
# CONFIG_DM_DEBUG_BLOCK_MANAGER_LOCKING is not set
CONFIG_DM_BIO_PRISON=y
CONFIG_DM_PERSISTENT_DATA=y
# CONFIG_DM_UNSTRIPED is not set
CONFIG_DM_CRYPT=y
# CONFIG_DM_INLINECRYPT is not set
CONFIG_DM_SNAPSHOT=y
CONFIG_DM_THIN_PROVISIONING=y
CONFIG_DM_CACHE=y
CONFIG_DM_CACHE_SMQ=y
CONFIG_DM_WRITECACHE=y
# CONFIG_DM_EBS is not set
# CONFIG_DM_ERA is not set
CONFIG_DM_CLONE=y
CONFIG_DM_MIRROR=y
# CONFIG_DM_LOG_USERSPACE is not set
CONFIG_DM_RAID=y
CONFIG_DM_ZERO=y
CONFIG_DM_MULTIPATH=y
CONFIG_DM_MULTIPATH_QL=y
CONFIG_DM_MULTIPATH_ST=y
# CONFIG_DM_MULTIPATH_HST is not set
# CONFIG_DM_MULTIPATH_IOA is not set
# CONFIG_DM_DELAY is not set
# CONFIG_DM_DUST is not set
# CONFIG_DM_INIT is not set
CONFIG_DM_UEVENT=y
CONFIG_DM_FLAKEY=y
CONFIG_DM_VERITY=y
# CONFIG_DM_VERITY_VERIFY_ROOTHASH_SIG is not set
CONFIG_DM_VERITY_FEC=y
# CONFIG_DM_SWITCH is not set
# CONFIG_DM_LOG_WRITES is not set
CONFIG_DM_INTEGRITY=y
CONFIG_DM_ZONED=y
CONFIG_DM_AUDIT=y
# CONFIG_DM_VDO is not set
# CONFIG_DM_PCACHE is not set
CONFIG_TARGET_CORE=y
# CONFIG_TCM_IBLOCK is not set
# CONFIG_TCM_FILEIO is not set
# CONFIG_TCM_PSCSI is not set
# CONFIG_LOOPBACK_TARGET is not set
# CONFIG_ISCSI_TARGET is not set
# CONFIG_SBP_TARGET is not set
# CONFIG_REMOTE_TARGET is not set
# CONFIG_FUSION is not set

#
# IEEE 1394 (FireWire) support
#
CONFIG_FIREWIRE=y
CONFIG_FIREWIRE_OHCI=y
CONFIG_FIREWIRE_SBP2=y
CONFIG_FIREWIRE_NET=y
# CONFIG_FIREWIRE_NOSY is not set
# end of IEEE 1394 (FireWire) support

# CONFIG_MACINTOSH_DRIVERS is not set
CONFIG_NETDEVICES=y
CONFIG_MII=y
CONFIG_NET_CORE=y
CONFIG_BONDING=y
CONFIG_DUMMY=y
CONFIG_WIREGUARD=y
# CONFIG_WIREGUARD_DEBUG is not set
# CONFIG_OVPN is not set
CONFIG_EQUALIZER=y
CONFIG_NET_FC=y
CONFIG_IFB=y
CONFIG_NET_TEAM=y
CONFIG_NET_TEAM_MODE_BROADCAST=y
CONFIG_NET_TEAM_MODE_ROUNDROBIN=y
CONFIG_NET_TEAM_MODE_RANDOM=y
CONFIG_NET_TEAM_MODE_ACTIVEBACKUP=y
CONFIG_NET_TEAM_MODE_LOADBALANCE=y
CONFIG_MACVLAN=y
CONFIG_MACVTAP=y
CONFIG_IPVLAN_L3S=y
CONFIG_IPVLAN=y
CONFIG_IPVTAP=y
CONFIG_VXLAN=y
CONFIG_GENEVE=y
CONFIG_BAREUDP=y
CONFIG_GTP=y
# CONFIG_PFCP is not set
# CONFIG_AMT is not set
CONFIG_MACSEC=y
CONFIG_NETCONSOLE=y
# CONFIG_NETCONSOLE_DYNAMIC is not set
# CONFIG_NETCONSOLE_EXTENDED_LOG is not set
CONFIG_NETPOLL=y
CONFIG_NET_POLL_CONTROLLER=y
CONFIG_TUN=y
CONFIG_TAP=y
CONFIG_TUN_VNET_CROSS_LE=y
CONFIG_VETH=y
CONFIG_VIRTIO_NET=y
CONFIG_NLMON=y
# CONFIG_NETKIT is not set
CONFIG_NET_VRF=y
CONFIG_VSOCKMON=y
# CONFIG_MHI_NET is not set
# CONFIG_ARCNET is not set
CONFIG_ATM_DRIVERS=y
# CONFIG_ATM_SOLOS is not set

#
# Distributed Switch Architecture drivers
#
# CONFIG_B53 is not set
# CONFIG_NET_DSA_BCM_SF2 is not set
# CONFIG_NET_DSA_LOOP is not set
# CONFIG_NET_DSA_HIRSCHMANN_HELLCREEK is not set
# CONFIG_NET_DSA_LANTIQ_GSWIP is not set
# CONFIG_NET_DSA_MXL_GSW1XX is not set
# CONFIG_NET_DSA_MT7530 is not set
# CONFIG_NET_DSA_MV88E6060 is not set
# CONFIG_NET_DSA_MICROCHIP_KSZ_COMMON is not set
# CONFIG_NET_DSA_MV88E6XXX is not set
# CONFIG_NET_DSA_MXL862 is not set
# CONFIG_NET_DSA_AR9331 is not set
# CONFIG_NET_DSA_QCA8K is not set
# CONFIG_NET_DSA_SJA1105 is not set
# CONFIG_NET_DSA_XRS700X_I2C is not set
# CONFIG_NET_DSA_XRS700X_MDIO is not set
# CONFIG_NET_DSA_REALTEK is not set
# CONFIG_NET_DSA_KS8995 is not set
# CONFIG_NET_DSA_SMSC_LAN9303_I2C is not set
# CONFIG_NET_DSA_SMSC_LAN9303_MDIO is not set
# CONFIG_NET_DSA_VITESSE_VSC73XX_SPI is not set
# CONFIG_NET_DSA_VITESSE_VSC73XX_PLATFORM is not set
# CONFIG_NET_DSA_YT921X is not set
# end of Distributed Switch Architecture drivers

CONFIG_ETHERNET=y
# CONFIG_NET_VENDOR_3COM is not set
# CONFIG_NET_VENDOR_ADAPTEC is not set
# CONFIG_NET_VENDOR_AGERE is not set
# CONFIG_NET_VENDOR_ALACRITECH is not set
CONFIG_NET_VENDOR_ALIBABA=y
# CONFIG_ALIBABA_EEA is not set
# CONFIG_ALTERA_TSE is not set
CONFIG_NET_VENDOR_AMAZON=y
# CONFIG_ENA_ETHERNET is not set
# CONFIG_NET_VENDOR_AMD is not set
# CONFIG_NET_VENDOR_AQUANTIA is not set
# CONFIG_NET_VENDOR_ARC is not set
CONFIG_NET_VENDOR_ASIX=y
# CONFIG_SPI_AX88796C is not set
# CONFIG_NET_VENDOR_ATHEROS is not set
# CONFIG_CX_ECAT is not set
# CONFIG_NET_VENDOR_BROADCOM is not set
# CONFIG_NET_VENDOR_CADENCE is not set
# CONFIG_NET_VENDOR_CAVIUM is not set
# CONFIG_NET_VENDOR_CHELSIO is not set
CONFIG_NET_VENDOR_CISCO=y
# CONFIG_ENIC is not set
# CONFIG_NET_VENDOR_CORTINA is not set
CONFIG_NET_VENDOR_DAVICOM=y
# CONFIG_DM9051 is not set
# CONFIG_NET_VENDOR_DEC is not set
# CONFIG_NET_VENDOR_DLINK is not set
# CONFIG_NET_VENDOR_EMULEX is not set
CONFIG_NET_VENDOR_ENGLEDER=y
# CONFIG_TSNEP is not set
# CONFIG_NET_VENDOR_EZCHIP is not set
CONFIG_NET_VENDOR_FUNGIBLE=y
# CONFIG_FUN_ETH is not set
CONFIG_NET_VENDOR_GOOGLE=y
CONFIG_GVE=y
CONFIG_NET_VENDOR_HISILICON=y
# CONFIG_HIBMCGE is not set
# CONFIG_NET_VENDOR_HUAWEI is not set
CONFIG_NET_VENDOR_I825XX=y
CONFIG_NET_VENDOR_INTEL=y
CONFIG_E100=y
CONFIG_E1000=y
CONFIG_E1000E=y
CONFIG_E1000E_HWTS=y
# CONFIG_IGB is not set
# CONFIG_IGBVF is not set
# CONFIG_IXGBE is not set
# CONFIG_IXGBEVF is not set
# CONFIG_I40E is not set
# CONFIG_I40EVF is not set
# CONFIG_ICE is not set
# CONFIG_FM10K is not set
# CONFIG_IGC is not set
# CONFIG_IDPF is not set
# CONFIG_JME is not set
# CONFIG_NET_VENDOR_ADI is not set
CONFIG_NET_VENDOR_LITEX=y
# CONFIG_LITEX_LITEETH is not set
# CONFIG_NET_VENDOR_MARVELL is not set
CONFIG_NET_VENDOR_MELLANOX=y
# CONFIG_MLX4_EN is not set
CONFIG_MLX4_CORE=y
# CONFIG_MLX4_DEBUG is not set
# CONFIG_MLX4_CORE_GEN2 is not set
# CONFIG_MLX5_CORE is not set
# CONFIG_MLXSW_CORE is not set
# CONFIG_MLXFW is not set
CONFIG_NET_VENDOR_META=y
# CONFIG_FBNIC is not set
# CONFIG_NET_VENDOR_MICREL is not set
# CONFIG_NET_VENDOR_MICROCHIP is not set
# CONFIG_NET_VENDOR_MICROSEMI is not set
CONFIG_NET_VENDOR_MICROSOFT=y
CONFIG_NET_VENDOR_MUCSE=y
# CONFIG_MGBE is not set
# CONFIG_NET_VENDOR_MYRI is not set
# CONFIG_FEALNX is not set
# CONFIG_NET_VENDOR_NI is not set
# CONFIG_NET_VENDOR_NATSEMI is not set
# CONFIG_NET_VENDOR_NETRONOME is not set
# CONFIG_NET_VENDOR_NVIDIA is not set
# CONFIG_NET_VENDOR_OKI is not set
# CONFIG_ETHOC is not set
# CONFIG_NET_VENDOR_PENSANDO is not set
# CONFIG_NET_VENDOR_QLOGIC is not set
# CONFIG_NET_VENDOR_BROCADE is not set
# CONFIG_NET_VENDOR_QUALCOMM is not set
# CONFIG_NET_VENDOR_RDC is not set
# CONFIG_NET_VENDOR_REALTEK is not set
# CONFIG_NET_VENDOR_RENESAS is not set
# CONFIG_NET_VENDOR_ROCKER is not set
# CONFIG_NET_VENDOR_SAMSUNG is not set
# CONFIG_NET_VENDOR_SEEQ is not set
# CONFIG_NET_VENDOR_SILAN is not set
# CONFIG_NET_VENDOR_SIS is not set
# CONFIG_NET_VENDOR_SOLARFLARE is not set
# CONFIG_NET_VENDOR_SMSC is not set
# CONFIG_NET_VENDOR_SOCIONEXT is not set
# CONFIG_NET_VENDOR_STMICRO is not set
# CONFIG_NET_VENDOR_SUN is not set
# CONFIG_NET_VENDOR_SYNOPSYS is not set
# CONFIG_NET_VENDOR_TEHUTI is not set
# CONFIG_NET_VENDOR_TI is not set
CONFIG_NET_VENDOR_VERTEXCOM=y
# CONFIG_MSE102X is not set
# CONFIG_NET_VENDOR_VIA is not set
CONFIG_NET_VENDOR_WANGXUN=y
# CONFIG_NGBE is not set
# CONFIG_TXGBE is not set
# CONFIG_TXGBEVF is not set
# CONFIG_NGBEVF is not set
# CONFIG_NET_VENDOR_WIZNET is not set
# CONFIG_NET_VENDOR_XILINX is not set
# CONFIG_NET_VENDOR_XIRCOM is not set
CONFIG_FDDI=y
# CONFIG_DEFXX is not set
# CONFIG_SKFP is not set
CONFIG_PHYLINK=y
CONFIG_PHYLIB=y
CONFIG_SWPHY=y
CONFIG_PHY_PACKAGE=y
# CONFIG_LED_TRIGGER_PHY is not set
CONFIG_PHYLIB_LEDS=y
CONFIG_FIXED_PHY=y
# CONFIG_SFP is not set

#
# MII PHY device drivers
#
# CONFIG_AS21XXX_PHY is not set
# CONFIG_AIR_AN8801_PHY is not set
# CONFIG_AIR_EN8811H_PHY is not set
# CONFIG_AMD_PHY is not set
# CONFIG_ADIN_PHY is not set
# CONFIG_ADIN1100_PHY is not set
# CONFIG_AQUANTIA_PHY is not set
CONFIG_AX88796B_PHY=y
# CONFIG_BROADCOM_PHY is not set
# CONFIG_BCM54140_PHY is not set
# CONFIG_BCM7XXX_PHY is not set
# CONFIG_BCM84881_PHY is not set
# CONFIG_BCM87XX_PHY is not set
# CONFIG_CICADA_PHY is not set
# CONFIG_CORTINA_PHY is not set
# CONFIG_DAVICOM_PHY is not set
# CONFIG_ICPLUS_PHY is not set
# CONFIG_LXT_PHY is not set
# CONFIG_INTEL_XWAY_PHY is not set
# CONFIG_LSI_ET1011C_PHY is not set
# CONFIG_MARVELL_PHY is not set
# CONFIG_MARVELL_10G_PHY is not set
# CONFIG_MARVELL_88Q2XXX_PHY is not set
# CONFIG_MARVELL_88X2222_PHY is not set
# CONFIG_MAXLINEAR_GPHY is not set
# CONFIG_MAXLINEAR_86110_PHY is not set
# CONFIG_MEDIATEK_GE_PHY is not set
# CONFIG_MICREL_PHY is not set
# CONFIG_MICROCHIP_T1S_PHY is not set
CONFIG_MICROCHIP_PHY=y
# CONFIG_MICROCHIP_T1_PHY is not set
# CONFIG_MICROSEMI_PHY is not set
# CONFIG_MOTORCOMM_PHY is not set
# CONFIG_NATIONAL_PHY is not set
# CONFIG_NXP_CBTX_PHY is not set
# CONFIG_NXP_C45_TJA11XX_PHY is not set
# CONFIG_NXP_TJA11XX_PHY is not set
# CONFIG_NCN26000_PHY is not set
# CONFIG_AT803X_PHY is not set
# CONFIG_QCA83XX_PHY is not set
# CONFIG_QCA808X_PHY is not set
# CONFIG_QCA807X_PHY is not set
# CONFIG_QSEMI_PHY is not set
CONFIG_REALTEK_PHY=y
# CONFIG_REALTEK_PHY_HWMON is not set
# CONFIG_RENESAS_PHY is not set
# CONFIG_ROCKCHIP_PHY is not set
CONFIG_SMSC_PHY=y
# CONFIG_STE10XP is not set
# CONFIG_TERANETICS_PHY is not set
# CONFIG_DP83822_PHY is not set
# CONFIG_DP83TC811_PHY is not set
# CONFIG_DP83848_PHY is not set
# CONFIG_DP83867_PHY is not set
# CONFIG_DP83869_PHY is not set
# CONFIG_DP83TD510_PHY is not set
# CONFIG_DP83TG720_PHY is not set
# CONFIG_VITESSE_PHY is not set
# CONFIG_XILINX_GMII2RGMII is not set
# CONFIG_PSE_CONTROLLER is not set
CONFIG_CAN_DEV=y
CONFIG_CAN_VCAN=y
CONFIG_CAN_VXCAN=y
CONFIG_CAN_NETLINK=y
CONFIG_CAN_CALC_BITTIMING=y
CONFIG_CAN_RX_OFFLOAD=y
# CONFIG_CAN_CAN327 is not set
# CONFIG_CAN_DUMMY is not set
# CONFIG_CAN_FLEXCAN is not set
# CONFIG_CAN_GRCAN is not set
# CONFIG_CAN_KVASER_PCIEFD is not set
CONFIG_CAN_SLCAN=y
# CONFIG_CAN_VIRTIO_CAN is not set
# CONFIG_CAN_C_CAN is not set
# CONFIG_CAN_CC770 is not set
# CONFIG_CAN_CTUCANFD_PCI is not set
# CONFIG_CAN_CTUCANFD_PLATFORM is not set
# CONFIG_CAN_ESD_402_PCI is not set
CONFIG_CAN_IFI_CANFD=y
# CONFIG_CAN_M_CAN is not set
# CONFIG_CAN_PEAK_PCIEFD is not set
# CONFIG_CAN_SJA1000 is not set
# CONFIG_CAN_SOFTING is not set

#
# CAN SPI interfaces
#
# CONFIG_CAN_HI311X is not set
# CONFIG_CAN_MCP251X is not set
# CONFIG_CAN_MCP251XFD is not set
# end of CAN SPI interfaces

#
# CAN USB interfaces
#
CONFIG_CAN_8DEV_USB=y
CONFIG_CAN_EMS_USB=y
CONFIG_CAN_ESD_USB=y
CONFIG_CAN_ETAS_ES58X=y
CONFIG_CAN_F81604=y
CONFIG_CAN_GS_USB=y
CONFIG_CAN_KVASER_USB=y
CONFIG_CAN_MCBA_USB=y
CONFIG_CAN_PEAK_USB=y
CONFIG_CAN_UCAN=y
# end of CAN USB interfaces

# CONFIG_CAN_DEBUG_DEVICES is not set

#
# MCTP Device Drivers
#
# CONFIG_MCTP_SERIAL is not set
# CONFIG_MCTP_TRANSPORT_I2C is not set
# CONFIG_MCTP_TRANSPORT_USB is not set
# end of MCTP Device Drivers

CONFIG_FWNODE_MDIO=y
CONFIG_OF_MDIO=y
CONFIG_ACPI_MDIO=y
# CONFIG_MDIO_BITBANG is not set
# CONFIG_MDIO_BCM_UNIMAC is not set
# CONFIG_MDIO_HISI_FEMAC is not set
CONFIG_MDIO_MVUSB=y
# CONFIG_MDIO_MSCC_MIIM is not set
# CONFIG_MDIO_OCTEON is not set
# CONFIG_MDIO_IPQ4019 is not set
# CONFIG_MDIO_IPQ8064 is not set
# CONFIG_MDIO_THUNDER is not set

#
# MDIO Multiplexers
#
# CONFIG_MDIO_BUS_MUX_GPIO is not set
# CONFIG_MDIO_BUS_MUX_MULTIPLEXER is not set
# CONFIG_MDIO_BUS_MUX_MMIOREG is not set

#
# PCS device drivers
#
# CONFIG_PCS_XPCS is not set
# end of PCS device drivers

# CONFIG_PLIP is not set
CONFIG_PPP=y
CONFIG_PPP_BSDCOMP=y
CONFIG_PPP_DEFLATE=y
CONFIG_PPP_FILTER=y
CONFIG_PPP_MPPE=y
CONFIG_PPP_MULTILINK=y
CONFIG_PPPOATM=y
CONFIG_PPPOX=y
CONFIG_PPPOE=y
CONFIG_PPPOE_HASH_BITS_1=y
# CONFIG_PPPOE_HASH_BITS_2 is not set
# CONFIG_PPPOE_HASH_BITS_4 is not set
# CONFIG_PPPOE_HASH_BITS_8 is not set
CONFIG_PPPOE_HASH_BITS=1
CONFIG_PPTP=y
CONFIG_PPPOL2TP=y
CONFIG_PPP_ASYNC=y
CONFIG_PPP_SYNC_TTY=y
CONFIG_SLIP=y
CONFIG_SLHC=y
CONFIG_SLIP_COMPRESSED=y
CONFIG_SLIP_SMART=y
CONFIG_SLIP_MODE_SLIP6=y
CONFIG_USB_NET_DRIVERS=y
CONFIG_USB_CATC=y
CONFIG_USB_KAWETH=y
CONFIG_USB_PEGASUS=y
CONFIG_USB_RTL8150=y
CONFIG_USB_RTL8152=y
CONFIG_USB_LAN78XX=y
CONFIG_USB_USBNET=y
CONFIG_USB_NET_AX8817X=y
CONFIG_USB_NET_AX88179_178A=y
CONFIG_USB_NET_CDCETHER=y
CONFIG_USB_NET_CDC_EEM=y
CONFIG_USB_NET_CDC_NCM=y
CONFIG_USB_NET_HUAWEI_CDC_NCM=y
CONFIG_USB_NET_CDC_MBIM=y
CONFIG_USB_NET_DM9601=y
CONFIG_USB_NET_SR9700=y
CONFIG_USB_NET_SR9800=y
CONFIG_USB_NET_SMSC75XX=y
CONFIG_USB_NET_SMSC95XX=y
CONFIG_USB_NET_GL620A=y
CONFIG_USB_NET_NET1080=y
CONFIG_USB_NET_PLUSB=y
CONFIG_USB_NET_MCS7830=y
CONFIG_USB_NET_RNDIS_HOST=y
CONFIG_USB_NET_CDC_SUBSET_ENABLE=y
CONFIG_USB_NET_CDC_SUBSET=y
CONFIG_USB_ALI_M5632=y
CONFIG_USB_AN2720=y
CONFIG_USB_BELKIN=y
CONFIG_USB_ARMLINUX=y
CONFIG_USB_EPSON2888=y
CONFIG_USB_KC2190=y
CONFIG_USB_NET_ZAURUS=y
CONFIG_USB_NET_CX82310_ETH=y
CONFIG_USB_NET_KALMIA=y
CONFIG_USB_NET_QMI_WWAN=y
CONFIG_USB_HSO=y
CONFIG_USB_NET_INT51X1=y
CONFIG_USB_CDC_PHONET=y
CONFIG_USB_IPHETH=y
CONFIG_USB_SIERRA_NET=y
CONFIG_USB_VL600=y
CONFIG_USB_NET_CH9200=y
CONFIG_USB_NET_AQC111=y
CONFIG_USB_RTL8153_ECM=y
CONFIG_WLAN=y
CONFIG_WLAN_VENDOR_ADMTEK=y
# CONFIG_ADM8211 is not set
CONFIG_ATH_COMMON=y
CONFIG_WLAN_VENDOR_ATH=y
# CONFIG_ATH_DEBUG is not set
# CONFIG_ATH5K is not set
# CONFIG_ATH5K_PCI is not set
CONFIG_ATH9K_HW=y
CONFIG_ATH9K_COMMON=y
CONFIG_ATH9K_COMMON_DEBUG=y
CONFIG_ATH9K_BTCOEX_SUPPORT=y
CONFIG_ATH9K=y
CONFIG_ATH9K_PCI=y
CONFIG_ATH9K_AHB=y
CONFIG_ATH9K_DEBUGFS=y
# CONFIG_ATH9K_STATION_STATISTICS is not set
CONFIG_ATH9K_DYNACK=y
# CONFIG_ATH9K_WOW is not set
CONFIG_ATH9K_RFKILL=y
CONFIG_ATH9K_CHANNEL_CONTEXT=y
CONFIG_ATH9K_PCOEM=y
# CONFIG_ATH9K_PCI_NO_EEPROM is not set
CONFIG_ATH9K_HTC=y
CONFIG_ATH9K_HTC_DEBUGFS=y
# CONFIG_ATH9K_HWRNG is not set
CONFIG_ATH9K_COMMON_SPECTRAL=y
CONFIG_CARL9170=y
CONFIG_CARL9170_LEDS=y
# CONFIG_CARL9170_DEBUGFS is not set
CONFIG_CARL9170_WPC=y
CONFIG_CARL9170_HWRNG=y
CONFIG_ATH6KL=y
# CONFIG_ATH6KL_SDIO is not set
CONFIG_ATH6KL_USB=y
# CONFIG_ATH6KL_DEBUG is not set
# CONFIG_ATH6KL_TRACING is not set
CONFIG_AR5523=y
# CONFIG_WIL6210 is not set
CONFIG_ATH10K=y
CONFIG_ATH10K_CE=y
CONFIG_ATH10K_PCI=y
# CONFIG_ATH10K_AHB is not set
# CONFIG_ATH10K_SDIO is not set
CONFIG_ATH10K_USB=y
# CONFIG_ATH10K_DEBUG is not set
# CONFIG_ATH10K_DEBUGFS is not set
CONFIG_ATH10K_LEDS=y
# CONFIG_ATH10K_TRACING is not set
# CONFIG_WCN36XX is not set
CONFIG_ATH11K=y
# CONFIG_ATH11K_PCI is not set
# CONFIG_ATH11K_DEBUG is not set
# CONFIG_ATH11K_DEBUGFS is not set
# CONFIG_ATH11K_TRACING is not set
# CONFIG_ATH12K is not set
# CONFIG_WLAN_VENDOR_ATMEL is not set
# CONFIG_WLAN_VENDOR_BROADCOM is not set
# CONFIG_WLAN_VENDOR_INTEL is not set
# CONFIG_WLAN_VENDOR_INTERSIL is not set
# CONFIG_WLAN_VENDOR_MARVELL is not set
# CONFIG_WLAN_VENDOR_MEDIATEK is not set
# CONFIG_WLAN_VENDOR_MICROCHIP is not set
CONFIG_WLAN_VENDOR_PURELIFI=y
CONFIG_PLFXLC=y
# CONFIG_WLAN_VENDOR_RALINK is not set
# CONFIG_WLAN_VENDOR_REALTEK is not set
# CONFIG_WLAN_VENDOR_RSI is not set
CONFIG_WLAN_VENDOR_SILABS=y
# CONFIG_WFX is not set
# CONFIG_WLAN_VENDOR_ST is not set
# CONFIG_WLAN_VENDOR_TI is not set
# CONFIG_WLAN_VENDOR_ZYDAS is not set
# CONFIG_WLAN_VENDOR_QUANTENNA is not set
CONFIG_MAC80211_HWSIM=y
CONFIG_VIRT_WIFI=y
CONFIG_WAN=y
CONFIG_HDLC=y
CONFIG_HDLC_RAW=y
CONFIG_HDLC_RAW_ETH=y
CONFIG_HDLC_CISCO=y
CONFIG_HDLC_FR=y
CONFIG_HDLC_PPP=y
CONFIG_HDLC_X25=y
# CONFIG_FRAMER is not set
# CONFIG_PCI200SYN is not set
# CONFIG_WANXL is not set
# CONFIG_PC300TOO is not set
# CONFIG_FARSYNC is not set
CONFIG_LAPBETHER=y
CONFIG_IEEE802154_DRIVERS=y
# CONFIG_IEEE802154_FAKELB is not set
# CONFIG_IEEE802154_AT86RF230 is not set
# CONFIG_IEEE802154_MRF24J40 is not set
# CONFIG_IEEE802154_CC2520 is not set
CONFIG_IEEE802154_ATUSB=y
# CONFIG_IEEE802154_ADF7242 is not set
# CONFIG_IEEE802154_CA8210 is not set
# CONFIG_IEEE802154_MCR20A is not set
CONFIG_IEEE802154_HWSIM=y

#
# Wireless WAN
#
CONFIG_WWAN=y
# CONFIG_WWAN_DEBUGFS is not set
# CONFIG_WWAN_HWSIM is not set
CONFIG_MHI_WWAN_CTRL=y
# CONFIG_MHI_WWAN_MBIM is not set
# CONFIG_IOSM is not set
# CONFIG_MTK_T7XX is not set
# end of Wireless WAN

CONFIG_VMXNET3=y
# CONFIG_FUJITSU_ES is not set
CONFIG_USB4_NET=y
CONFIG_NETDEVSIM=y
CONFIG_NET_FAILOVER=y

#
# Input device support
#
CONFIG_INPUT=y
CONFIG_INPUT_LEDS=y
CONFIG_INPUT_FF_MEMLESS=y
CONFIG_INPUT_SPARSEKMAP=y
# CONFIG_INPUT_MATRIXKMAP is not set
CONFIG_INPUT_VIVALDIFMAP=y

#
# Userland interfaces
#
CONFIG_INPUT_MOUSEDEV=y
CONFIG_INPUT_MOUSEDEV_PSAUX=y
CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024
CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768
CONFIG_INPUT_JOYDEV=y
CONFIG_INPUT_EVDEV=y

#
# Input Device Drivers
#
CONFIG_INPUT_KEYBOARD=y
# CONFIG_KEYBOARD_ADC is not set
# CONFIG_KEYBOARD_ADP5588 is not set
CONFIG_KEYBOARD_ATKBD=y
# CONFIG_KEYBOARD_QT1050 is not set
# CONFIG_KEYBOARD_QT1070 is not set
# CONFIG_KEYBOARD_QT2160 is not set
# CONFIG_KEYBOARD_DLINK_DIR685 is not set
# CONFIG_KEYBOARD_LKKBD is not set
# CONFIG_KEYBOARD_GPIO is not set
# CONFIG_KEYBOARD_GPIO_POLLED is not set
# CONFIG_KEYBOARD_TCA8418 is not set
# CONFIG_KEYBOARD_MATRIX is not set
# CONFIG_KEYBOARD_CHARLIEPLEX is not set
# CONFIG_KEYBOARD_LM8323 is not set
# CONFIG_KEYBOARD_LM8333 is not set
# CONFIG_KEYBOARD_MAX7359 is not set
# CONFIG_KEYBOARD_MPR121 is not set
# CONFIG_KEYBOARD_NEWTON is not set
# CONFIG_KEYBOARD_OPENCORES is not set
# CONFIG_KEYBOARD_PINEPHONE is not set
# CONFIG_KEYBOARD_SAMSUNG is not set
# CONFIG_KEYBOARD_STOWAWAY is not set
# CONFIG_KEYBOARD_SUNKBD is not set
# CONFIG_KEYBOARD_OMAP4 is not set
# CONFIG_KEYBOARD_TM2_TOUCHKEY is not set
# CONFIG_KEYBOARD_TWL4030 is not set
# CONFIG_KEYBOARD_XTKBD is not set
# CONFIG_KEYBOARD_CAP11XX is not set
# CONFIG_KEYBOARD_BCM is not set
# CONFIG_KEYBOARD_CYPRESS_SF is not set
CONFIG_INPUT_MOUSE=y
CONFIG_MOUSE_PS2=y
CONFIG_MOUSE_PS2_ALPS=y
CONFIG_MOUSE_PS2_BYD=y
CONFIG_MOUSE_PS2_LOGIPS2PP=y
CONFIG_MOUSE_PS2_SYNAPTICS=y
CONFIG_MOUSE_PS2_SYNAPTICS_SMBUS=y
CONFIG_MOUSE_PS2_CYPRESS=y
CONFIG_MOUSE_PS2_LIFEBOOK=y
CONFIG_MOUSE_PS2_TRACKPOINT=y
# CONFIG_MOUSE_PS2_ELANTECH is not set
# CONFIG_MOUSE_PS2_SENTELIC is not set
# CONFIG_MOUSE_PS2_TOUCHKIT is not set
CONFIG_MOUSE_PS2_FOCALTECH=y
# CONFIG_MOUSE_PS2_VMMOUSE is not set
CONFIG_MOUSE_PS2_SMBUS=y
# CONFIG_MOUSE_SERIAL is not set
CONFIG_MOUSE_APPLETOUCH=y
CONFIG_MOUSE_BCM5974=y
# CONFIG_MOUSE_CYAPA is not set
# CONFIG_MOUSE_ELAN_I2C is not set
# CONFIG_MOUSE_VSXXXAA is not set
# CONFIG_MOUSE_GPIO is not set
# CONFIG_MOUSE_SYNAPTICS_I2C is not set
CONFIG_MOUSE_SYNAPTICS_USB=y
CONFIG_INPUT_JOYSTICK=y
# CONFIG_JOYSTICK_ANALOG is not set
# CONFIG_JOYSTICK_A3D is not set
# CONFIG_JOYSTICK_ADC is not set
# CONFIG_JOYSTICK_ADI is not set
# CONFIG_JOYSTICK_COBRA is not set
# CONFIG_JOYSTICK_GF2K is not set
# CONFIG_JOYSTICK_GRIP is not set
# CONFIG_JOYSTICK_GRIP_MP is not set
# CONFIG_JOYSTICK_GUILLEMOT is not set
# CONFIG_JOYSTICK_INTERACT is not set
# CONFIG_JOYSTICK_SIDEWINDER is not set
# CONFIG_JOYSTICK_TMDC is not set
CONFIG_JOYSTICK_IFORCE=y
CONFIG_JOYSTICK_IFORCE_USB=y
# CONFIG_JOYSTICK_IFORCE_232 is not set
# CONFIG_JOYSTICK_WARRIOR is not set
# CONFIG_JOYSTICK_MAGELLAN is not set
# CONFIG_JOYSTICK_SPACEORB is not set
# CONFIG_JOYSTICK_SPACEBALL is not set
# CONFIG_JOYSTICK_STINGER is not set
# CONFIG_JOYSTICK_TWIDJOY is not set
# CONFIG_JOYSTICK_ZHENHUA is not set
# CONFIG_JOYSTICK_DB9 is not set
# CONFIG_JOYSTICK_GAMECON is not set
# CONFIG_JOYSTICK_TURBOGRAFX is not set
# CONFIG_JOYSTICK_AS5011 is not set
# CONFIG_JOYSTICK_JOYDUMP is not set
CONFIG_JOYSTICK_XPAD=y
CONFIG_JOYSTICK_XPAD_FF=y
CONFIG_JOYSTICK_XPAD_LEDS=y
# CONFIG_JOYSTICK_WALKERA0701 is not set
# CONFIG_JOYSTICK_PSXPAD_SPI is not set
CONFIG_JOYSTICK_PXRC=y
# CONFIG_JOYSTICK_QWIIC is not set
# CONFIG_JOYSTICK_FSIA6B is not set
# CONFIG_JOYSTICK_SENSEHAT is not set
# CONFIG_JOYSTICK_SEESAW is not set
CONFIG_INPUT_TABLET=y
CONFIG_TABLET_USB_ACECAD=y
CONFIG_TABLET_USB_AIPTEK=y
CONFIG_TABLET_USB_HANWANG=y
CONFIG_TABLET_USB_KBTAB=y
CONFIG_TABLET_USB_PEGASUS=y
# CONFIG_TABLET_SERIAL_WACOM4 is not set
CONFIG_INPUT_TOUCHSCREEN=y
# CONFIG_TOUCHSCREEN_ADS7846 is not set
# CONFIG_TOUCHSCREEN_AD7877 is not set
# CONFIG_TOUCHSCREEN_AD7879 is not set
# CONFIG_TOUCHSCREEN_ADC is not set
# CONFIG_TOUCHSCREEN_AR1021_I2C is not set
# CONFIG_TOUCHSCREEN_ATMEL_MXT is not set
# CONFIG_TOUCHSCREEN_AUO_PIXCIR is not set
# CONFIG_TOUCHSCREEN_BU21013 is not set
# CONFIG_TOUCHSCREEN_BU21029 is not set
# CONFIG_TOUCHSCREEN_CHIPONE_ICN8318 is not set
# CONFIG_TOUCHSCREEN_CHIPONE_ICN8505 is not set
# CONFIG_TOUCHSCREEN_CY8CTMA140 is not set
# CONFIG_TOUCHSCREEN_CY8CTMG110 is not set
# CONFIG_TOUCHSCREEN_CYTTSP_CORE is not set
# CONFIG_TOUCHSCREEN_CYTTSP5 is not set
# CONFIG_TOUCHSCREEN_DYNAPRO is not set
# CONFIG_TOUCHSCREEN_HAMPSHIRE is not set
# CONFIG_TOUCHSCREEN_EETI is not set
# CONFIG_TOUCHSCREEN_EGALAX is not set
# CONFIG_TOUCHSCREEN_EGALAX_SERIAL is not set
# CONFIG_TOUCHSCREEN_EXC3000 is not set
# CONFIG_TOUCHSCREEN_FUJITSU is not set
# CONFIG_TOUCHSCREEN_GOODIX is not set
# CONFIG_TOUCHSCREEN_GOODIX_BERLIN_I2C is not set
# CONFIG_TOUCHSCREEN_GOODIX_BERLIN_SPI is not set
# CONFIG_TOUCHSCREEN_HIDEEP is not set
# CONFIG_TOUCHSCREEN_HIMAX_HX852X is not set
# CONFIG_TOUCHSCREEN_HYCON_HY46XX is not set
# CONFIG_TOUCHSCREEN_HYNITRON_CSTXXX is not set
# CONFIG_TOUCHSCREEN_HYNITRON_CST816X is not set
# CONFIG_TOUCHSCREEN_ILI210X is not set
# CONFIG_TOUCHSCREEN_ILITEK is not set
# CONFIG_TOUCHSCREEN_S6SY761 is not set
# CONFIG_TOUCHSCREEN_GUNZE is not set
# CONFIG_TOUCHSCREEN_EKTF2127 is not set
# CONFIG_TOUCHSCREEN_ELAN is not set
# CONFIG_TOUCHSCREEN_ELO is not set
# CONFIG_TOUCHSCREEN_WACOM_W8001 is not set
# CONFIG_TOUCHSCREEN_WACOM_I2C is not set
# CONFIG_TOUCHSCREEN_WACOM_W9000 is not set
# CONFIG_TOUCHSCREEN_MAX11801 is not set
# CONFIG_TOUCHSCREEN_MMS114 is not set
# CONFIG_TOUCHSCREEN_MELFAS_MIP4 is not set
# CONFIG_TOUCHSCREEN_MSG2638 is not set
# CONFIG_TOUCHSCREEN_MTOUCH is not set
# CONFIG_TOUCHSCREEN_NOVATEK_NVT_TS is not set
# CONFIG_TOUCHSCREEN_IMAGIS is not set
# CONFIG_TOUCHSCREEN_IMX6UL_TSC is not set
# CONFIG_TOUCHSCREEN_INEXIO is not set
# CONFIG_TOUCHSCREEN_PENMOUNT is not set
# CONFIG_TOUCHSCREEN_EDT_FT5X06 is not set
# CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set
# CONFIG_TOUCHSCREEN_TOUCHWIN is not set
# CONFIG_TOUCHSCREEN_PIXCIR is not set
# CONFIG_TOUCHSCREEN_WDT87XX_I2C is not set
CONFIG_TOUCHSCREEN_USB_COMPOSITE=y
CONFIG_TOUCHSCREEN_USB_EGALAX=y
CONFIG_TOUCHSCREEN_USB_PANJIT=y
CONFIG_TOUCHSCREEN_USB_3M=y
CONFIG_TOUCHSCREEN_USB_ITM=y
CONFIG_TOUCHSCREEN_USB_ETURBO=y
CONFIG_TOUCHSCREEN_USB_GUNZE=y
CONFIG_TOUCHSCREEN_USB_DMC_TSC10=y
CONFIG_TOUCHSCREEN_USB_IRTOUCH=y
CONFIG_TOUCHSCREEN_USB_IDEALTEK=y
CONFIG_TOUCHSCREEN_USB_GENERAL_TOUCH=y
CONFIG_TOUCHSCREEN_USB_GOTOP=y
CONFIG_TOUCHSCREEN_USB_JASTEC=y
CONFIG_TOUCHSCREEN_USB_ELO=y
CONFIG_TOUCHSCREEN_USB_E2I=y
CONFIG_TOUCHSCREEN_USB_ZYTRONIC=y
CONFIG_TOUCHSCREEN_USB_ETT_TC45USB=y
CONFIG_TOUCHSCREEN_USB_NEXIO=y
CONFIG_TOUCHSCREEN_USB_EASYTOUCH=y
# CONFIG_TOUCHSCREEN_TOUCHIT213 is not set
# CONFIG_TOUCHSCREEN_TSC_SERIO is not set
# CONFIG_TOUCHSCREEN_TSC2004 is not set
# CONFIG_TOUCHSCREEN_TSC2005 is not set
# CONFIG_TOUCHSCREEN_TSC2007 is not set
# CONFIG_TOUCHSCREEN_RM_TS is not set
# CONFIG_TOUCHSCREEN_SILEAD is not set
# CONFIG_TOUCHSCREEN_SIS_I2C is not set
# CONFIG_TOUCHSCREEN_ST1232 is not set
# CONFIG_TOUCHSCREEN_STMFTS is not set
CONFIG_TOUCHSCREEN_SUR40=y
# CONFIG_TOUCHSCREEN_SURFACE3_SPI is not set
# CONFIG_TOUCHSCREEN_SX8654 is not set
# CONFIG_TOUCHSCREEN_TPS6507X is not set
# CONFIG_TOUCHSCREEN_ZET6223 is not set
# CONFIG_TOUCHSCREEN_ZFORCE is not set
# CONFIG_TOUCHSCREEN_COLIBRI_VF50 is not set
# CONFIG_TOUCHSCREEN_ROHM_BU21023 is not set
# CONFIG_TOUCHSCREEN_IQS5XX is not set
# CONFIG_TOUCHSCREEN_IQS7211 is not set
# CONFIG_TOUCHSCREEN_ZINITIX is not set
# CONFIG_TOUCHSCREEN_HIMAX_HX83112B is not set
CONFIG_INPUT_MISC=y
# CONFIG_INPUT_AD714X is not set
# CONFIG_INPUT_ATMEL_CAPTOUCH is not set
# CONFIG_INPUT_AW86927 is not set
# CONFIG_INPUT_BMA150 is not set
# CONFIG_INPUT_E3X0_BUTTON is not set
# CONFIG_INPUT_PCSPKR is not set
# CONFIG_INPUT_MMA8450 is not set
# CONFIG_INPUT_APANEL is not set
# CONFIG_INPUT_GPIO_BEEPER is not set
# CONFIG_INPUT_GPIO_DECODER is not set
# CONFIG_INPUT_GPIO_VIBRA is not set
# CONFIG_INPUT_ATLAS_BTNS is not set
CONFIG_INPUT_ATI_REMOTE2=y
CONFIG_INPUT_KEYSPAN_REMOTE=y
# CONFIG_INPUT_KXTJ9 is not set
CONFIG_INPUT_POWERMATE=y
CONFIG_INPUT_YEALINK=y
CONFIG_INPUT_CM109=y
# CONFIG_INPUT_REGULATOR_HAPTIC is not set
# CONFIG_INPUT_RETU_PWRBUTTON is not set
# CONFIG_INPUT_TWL4030_PWRBUTTON is not set
# CONFIG_INPUT_TWL4030_VIBRA is not set
CONFIG_INPUT_UINPUT=y
# CONFIG_INPUT_PCF8574 is not set
# CONFIG_INPUT_GPIO_ROTARY_ENCODER is not set
# CONFIG_INPUT_DA7280_HAPTICS is not set
# CONFIG_INPUT_ADXL34X is not set
# CONFIG_INPUT_IBM_PANEL is not set
CONFIG_INPUT_IMS_PCU=y
# CONFIG_INPUT_IQS269A is not set
# CONFIG_INPUT_IQS626A is not set
# CONFIG_INPUT_IQS7222 is not set
# CONFIG_INPUT_CMA3000 is not set
# CONFIG_INPUT_IDEAPAD_SLIDEBAR is not set
# CONFIG_INPUT_DRV260X_HAPTICS is not set
# CONFIG_INPUT_DRV2665_HAPTICS is not set
# CONFIG_INPUT_DRV2667_HAPTICS is not set
CONFIG_RMI4_CORE=y
# CONFIG_RMI4_I2C is not set
# CONFIG_RMI4_SPI is not set
# CONFIG_RMI4_SMB is not set
CONFIG_RMI4_F03=y
CONFIG_RMI4_F03_SERIO=y
CONFIG_RMI4_2D_SENSOR=y
CONFIG_RMI4_F11=y
CONFIG_RMI4_F12=y
# CONFIG_RMI4_F1A is not set
# CONFIG_RMI4_F21 is not set
CONFIG_RMI4_F30=y
# CONFIG_RMI4_F34 is not set
CONFIG_RMI4_F3A=y
# CONFIG_RMI4_F54 is not set
# CONFIG_RMI4_F55 is not set

#
# Hardware I/O ports
#
CONFIG_SERIO=y
CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=y
CONFIG_SERIO_I8042=y
CONFIG_SERIO_SERPORT=y
# CONFIG_SERIO_PARKBD is not set
# CONFIG_SERIO_PCIPS2 is not set
CONFIG_SERIO_LIBPS2=y
# CONFIG_SERIO_RAW is not set
# CONFIG_SERIO_ALTERA_PS2 is not set
# CONFIG_SERIO_PS2MULT is not set
# CONFIG_SERIO_ARC_PS2 is not set
# CONFIG_SERIO_APBPS2 is not set
# CONFIG_SERIO_GPIO_PS2 is not set
CONFIG_USERIO=y
# CONFIG_GAMEPORT is not set
# end of Hardware I/O ports
# end of Input device support

#
# Character devices
#
CONFIG_TTY=y
CONFIG_VT=y
CONFIG_CONSOLE_TRANSLATIONS=y
CONFIG_VT_CONSOLE=y
CONFIG_VT_CONSOLE_SLEEP=y
CONFIG_VT_HW_CONSOLE_BINDING=y
CONFIG_UNIX98_PTYS=y
CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=256
CONFIG_LEGACY_TIOCSTI=y
CONFIG_LDISC_AUTOLOAD=y

#
# Serial drivers
#
CONFIG_SERIAL_EARLYCON=y
CONFIG_SERIAL_8250=y
CONFIG_SERIAL_8250_PNP=y
# CONFIG_SERIAL_8250_16550A_VARIANTS is not set
# CONFIG_SERIAL_8250_FINTEK is not set
CONFIG_SERIAL_8250_CONSOLE=y
CONFIG_SERIAL_8250_DMA=y
CONFIG_SERIAL_8250_PCILIB=y
CONFIG_SERIAL_8250_PCI=y
# CONFIG_SERIAL_8250_EXAR is not set
# CONFIG_SERIAL_8250_CS is not set
CONFIG_SERIAL_8250_NR_UARTS=32
CONFIG_SERIAL_8250_RUNTIME_UARTS=4
CONFIG_SERIAL_8250_EXTENDED=y
CONFIG_SERIAL_8250_SHARE_IRQ=y
CONFIG_SERIAL_8250_DETECT_IRQ=y
CONFIG_SERIAL_8250_RSA=y
CONFIG_SERIAL_8250_MANY_PORTS=y
# CONFIG_SERIAL_8250_PCI1XXXX is not set
# CONFIG_SERIAL_8250_DW is not set
# CONFIG_SERIAL_8250_RT288X is not set
CONFIG_SERIAL_8250_LPSS=y
CONFIG_SERIAL_8250_MID=y
CONFIG_SERIAL_8250_PERICOM=y
# CONFIG_SERIAL_8250_NI is not set
# CONFIG_SERIAL_OF_PLATFORM is not set
CONFIG_SERIAL_8250_DWLIB=y

#
# Non-8250 serial port support
#
# CONFIG_SERIAL_MAX3100 is not set
# CONFIG_SERIAL_MAX310X is not set
# CONFIG_SERIAL_UARTLITE is not set
CONFIG_SERIAL_CORE=y
CONFIG_SERIAL_CORE_CONSOLE=y
# CONFIG_SERIAL_JSM is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_LANTIQ is not set
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SC16IS7XX is not set
# CONFIG_SERIAL_ALTERA_JTAGUART is not set
# CONFIG_SERIAL_ALTERA_UART is not set
# CONFIG_SERIAL_XILINX_PS_UART is not set
# CONFIG_SERIAL_ARC is not set
# CONFIG_SERIAL_RP2 is not set
# CONFIG_SERIAL_FSL_LPUART is not set
# CONFIG_SERIAL_FSL_LINFLEXUART is not set
# CONFIG_SERIAL_CONEXANT_DIGICOLOR is not set
# CONFIG_SERIAL_SPRD is not set
# end of Serial drivers

CONFIG_SERIAL_MCTRL_GPIO=y
CONFIG_SERIAL_NONSTANDARD=y
# CONFIG_MOXA_INTELLIO is not set
# CONFIG_MOXA_SMARTIO is not set
CONFIG_N_HDLC=y
# CONFIG_IPWIRELESS is not set
CONFIG_N_GSM=y
CONFIG_NOZOMI=y
CONFIG_NULL_TTY=y
CONFIG_HVC_DRIVER=y
CONFIG_SERIAL_DEV_BUS=y
CONFIG_SERIAL_DEV_CTRL_TTYPORT=y
CONFIG_TTY_PRINTK=y
CONFIG_TTY_PRINTK_LEVEL=6
# CONFIG_PRINTER is not set
# CONFIG_PPDEV is not set
CONFIG_VIRTIO_CONSOLE=y
# CONFIG_IPMI_HANDLER is not set
# CONFIG_SSIF_IPMI_BMC is not set
# CONFIG_IPMB_DEVICE_INTERFACE is not set
CONFIG_HW_RANDOM=y
# CONFIG_HW_RANDOM_TIMERIOMEM is not set
# CONFIG_HW_RANDOM_INTEL is not set
# CONFIG_HW_RANDOM_AMD is not set
# CONFIG_HW_RANDOM_BA431 is not set
# CONFIG_HW_RANDOM_VIA is not set
CONFIG_HW_RANDOM_VIRTIO=y
# CONFIG_HW_RANDOM_CCTRNG is not set
# CONFIG_HW_RANDOM_XIPHERA is not set
# CONFIG_DEVMEM is not set
CONFIG_NVRAM=y
# CONFIG_DEVPORT is not set
CONFIG_HPET=y
CONFIG_HPET_MMAP=y
CONFIG_HPET_MMAP_DEFAULT=y
# CONFIG_HANGCHECK_TIMER is not set
CONFIG_TCG_TPM=y
# CONFIG_TCG_TPM2_HMAC is not set
# CONFIG_HW_RANDOM_TPM is not set
CONFIG_TCG_TIS_CORE=y
CONFIG_TCG_TIS=y
# CONFIG_TCG_TIS_SPI is not set
# CONFIG_TCG_TIS_I2C is not set
# CONFIG_TCG_TIS_I2C_CR50 is not set
# CONFIG_TCG_TIS_I2C_ATMEL is not set
# CONFIG_TCG_TIS_I2C_INFINEON is not set
# CONFIG_TCG_TIS_I2C_NUVOTON is not set
# CONFIG_TCG_NSC is not set
# CONFIG_TCG_ATMEL is not set
# CONFIG_TCG_INFINEON is not set
CONFIG_TCG_CRB=y
# CONFIG_TCG_VTPM_PROXY is not set
# CONFIG_TCG_TIS_ST33ZP24_I2C is not set
# CONFIG_TCG_TIS_ST33ZP24_SPI is not set
# CONFIG_TELCLOCK is not set
CONFIG_XILLYBUS_CLASS=y
# CONFIG_XILLYBUS is not set
CONFIG_XILLYUSB=y
# end of Character devices

#
# I2C support
#
CONFIG_I2C=y
CONFIG_ACPI_I2C_OPREGION=y
CONFIG_I2C_BOARDINFO=y
CONFIG_I2C_CHARDEV=y
CONFIG_I2C_MUX=y

#
# Multiplexer I2C Chip support
#
# CONFIG_I2C_ARB_GPIO_CHALLENGE is not set
# CONFIG_I2C_MUX_GPIO is not set
# CONFIG_I2C_MUX_GPMUX is not set
# CONFIG_I2C_MUX_LTC4306 is not set
# CONFIG_I2C_MUX_PCA9541 is not set
# CONFIG_I2C_MUX_PCA954x is not set
CONFIG_I2C_MUX_REG=y
# CONFIG_I2C_MUX_MLXCPLD is not set
# end of Multiplexer I2C Chip support

CONFIG_I2C_HELPER_AUTO=y
CONFIG_I2C_SMBUS=y
CONFIG_I2C_ALGOBIT=y

#
# I2C Hardware Bus support
#

#
# PC SMBus host controller drivers
#
# CONFIG_I2C_ALI1535 is not set
# CONFIG_I2C_ALI1563 is not set
# CONFIG_I2C_ALI15X3 is not set
# CONFIG_I2C_AMD756 is not set
# CONFIG_I2C_AMD8111 is not set
# CONFIG_I2C_AMD_MP2 is not set
CONFIG_I2C_I801=y
# CONFIG_I2C_ISCH is not set
# CONFIG_I2C_ISMT is not set
# CONFIG_I2C_PIIX4 is not set
# CONFIG_I2C_CHT_WC is not set
# CONFIG_I2C_NFORCE2 is not set
# CONFIG_I2C_NVIDIA_GPU is not set
# CONFIG_I2C_SIS5595 is not set
# CONFIG_I2C_SIS630 is not set
# CONFIG_I2C_SIS96X is not set
# CONFIG_I2C_VIA is not set
# CONFIG_I2C_VIAPRO is not set
# CONFIG_I2C_ZHAOXIN is not set

#
# ACPI drivers
#
# CONFIG_I2C_SCMI is not set

#
# I2C system bus drivers (mostly embedded / system-on-chip)
#
# CONFIG_I2C_CBUS_GPIO is not set
CONFIG_I2C_DESIGNWARE_CORE=y
CONFIG_I2C_DESIGNWARE_PLATFORM=y
# CONFIG_I2C_DESIGNWARE_BAYTRAIL is not set
# CONFIG_I2C_DESIGNWARE_PCI is not set
# CONFIG_I2C_EMEV2 is not set
# CONFIG_I2C_GPIO is not set
# CONFIG_I2C_OCORES is not set
# CONFIG_I2C_PCA_PLATFORM is not set
# CONFIG_I2C_RK3X is not set
# CONFIG_I2C_SIMTEC is not set
# CONFIG_I2C_XILINX is not set

#
# External I2C/SMBus adapter drivers
#
CONFIG_I2C_DIOLAN_U2C=y
CONFIG_I2C_DLN2=y
CONFIG_I2C_LJCA=y
CONFIG_I2C_CP2615=y
# CONFIG_I2C_PARPORT is not set
# CONFIG_I2C_PCI1XXXX is not set
CONFIG_I2C_ROBOTFUZZ_OSIF=y
# CONFIG_I2C_TAOS_EVM is not set
CONFIG_I2C_TINY_USB=y
CONFIG_I2C_VIPERBOARD=y

#
# Other I2C/SMBus bus drivers
#
# CONFIG_I2C_MLXCPLD is not set
# CONFIG_I2C_VIRTIO is not set
# end of I2C Hardware Bus support

# CONFIG_I2C_STUB is not set
CONFIG_I2C_SLAVE=y
CONFIG_I2C_SLAVE_EEPROM=y
# CONFIG_I2C_SLAVE_TESTUNIT is not set
# CONFIG_I2C_DEBUG_CORE is not set
# CONFIG_I2C_DEBUG_ALGO is not set
# CONFIG_I2C_DEBUG_BUS is not set
# end of I2C support

# CONFIG_I3C is not set
CONFIG_I3C_OR_I2C=y
CONFIG_SPI=y
# CONFIG_SPI_DEBUG is not set
CONFIG_SPI_MASTER=y
# CONFIG_SPI_MEM is not set

#
# SPI Master Controller Drivers
#
# CONFIG_SPI_ALTERA is not set
# CONFIG_SPI_AXI_SPI_ENGINE is not set
# CONFIG_SPI_BITBANG is not set
# CONFIG_SPI_BUTTERFLY is not set
# CONFIG_SPI_CADENCE is not set
# CONFIG_SPI_CADENCE_QUADSPI is not set
# CONFIG_SPI_CH341 is not set
# CONFIG_SPI_DESIGNWARE is not set
CONFIG_SPI_DLN2=y
# CONFIG_SPI_GPIO is not set
# CONFIG_SPI_LM70_LLP is not set
# CONFIG_SPI_FSL_SPI is not set
CONFIG_SPI_LJCA=y
# CONFIG_SPI_MICROCHIP_CORE_QSPI is not set
# CONFIG_SPI_MICROCHIP_CORE_SPI is not set
# CONFIG_SPI_LANTIQ_SSC is not set
# CONFIG_SPI_OC_TINY is not set
# CONFIG_SPI_PCI1XXXX is not set
# CONFIG_SPI_PXA2XX is not set
# CONFIG_SPI_SC18IS602 is not set
# CONFIG_SPI_SIFIVE is not set
# CONFIG_SPI_MXIC is not set
# CONFIG_SPI_VIRTIO is not set
# CONFIG_SPI_XCOMM is not set
# CONFIG_SPI_XILINX is not set

#
# SPI Multiplexer support
#
# CONFIG_SPI_MUX is not set

#
# SPI Protocol Masters
#
# CONFIG_SPI_SPIDEV is not set
# CONFIG_SPI_LOOPBACK_TEST is not set
# CONFIG_SPI_TLE62X0 is not set
# CONFIG_SPI_SLAVE is not set
CONFIG_SPI_DYNAMIC=y
# CONFIG_SPMI is not set
# CONFIG_HSI is not set
CONFIG_PPS=y
# CONFIG_PPS_DEBUG is not set

#
# PPS clients support
#
# CONFIG_PPS_CLIENT_KTIMER is not set
# CONFIG_PPS_CLIENT_LDISC is not set
# CONFIG_PPS_CLIENT_PARPORT is not set
# CONFIG_PPS_CLIENT_GPIO is not set
# CONFIG_PPS_GENERATOR is not set

#
# PTP clock support
#
CONFIG_PTP_1588_CLOCK=y
CONFIG_PTP_1588_CLOCK_OPTIONAL=y

#
# Enable PHYLIB and NETWORK_PHY_TIMESTAMPING to see the additional clocks.
#
CONFIG_PTP_1588_CLOCK_KVM=y
CONFIG_PTP_1588_CLOCK_VMCLOCK=y
# CONFIG_PTP_1588_CLOCK_IDT82P33 is not set
# CONFIG_PTP_1588_CLOCK_IDTCM is not set
# CONFIG_PTP_1588_CLOCK_FC3W is not set
# CONFIG_PTP_1588_CLOCK_MOCK is not set
# CONFIG_PTP_1588_CLOCK_VMW is not set
# CONFIG_PTP_1588_CLOCK_OCP is not set
# CONFIG_PTP_NETC_V4_TIMER is not set
# end of PTP clock support

#
# DPLL device support
#
# CONFIG_ZL3073X_I2C is not set
# CONFIG_ZL3073X_SPI is not set
# end of DPLL device support

# CONFIG_PINCTRL is not set
CONFIG_GPIOLIB_LEGACY=y
CONFIG_GPIOLIB=y
CONFIG_GPIOLIB_FASTPATH_LIMIT=512
CONFIG_OF_GPIO=y
CONFIG_GPIO_ACPI=y
CONFIG_GPIOLIB_IRQCHIP=y
# CONFIG_DEBUG_GPIO is not set
# CONFIG_GPIO_SYSFS is not set
# CONFIG_GPIO_CDEV is not set

#
# Memory mapped GPIO drivers
#
# CONFIG_GPIO_74XX_MMIO is not set
# CONFIG_GPIO_ALTERA is not set
# CONFIG_GPIO_AMDPT is not set
# CONFIG_GPIO_BY_PINCTRL is not set
# CONFIG_GPIO_CADENCE is not set
# CONFIG_GPIO_DWAPB is not set
# CONFIG_GPIO_FTGPIO010 is not set
# CONFIG_GPIO_GENERIC_PLATFORM is not set
# CONFIG_GPIO_GRANITERAPIDS is not set
# CONFIG_GPIO_GRGPIO is not set
# CONFIG_GPIO_HLWD is not set
# CONFIG_GPIO_ICH is not set
# CONFIG_GPIO_LOGICVC is not set
# CONFIG_GPIO_MB86S7X is not set
# CONFIG_GPIO_POLARFIRE_SOC is not set
# CONFIG_GPIO_SIFIVE is not set
# CONFIG_GPIO_SYSCON is not set
# CONFIG_GPIO_WAVESHARE_DSI_TOUCH is not set
# CONFIG_GPIO_XILINX is not set
# CONFIG_GPIO_AMD_FCH is not set
# end of Memory mapped GPIO drivers

#
# Port-mapped I/O GPIO drivers
#
# CONFIG_GPIO_VX855 is not set
# CONFIG_GPIO_F7188X is not set
# CONFIG_GPIO_IT87 is not set
# CONFIG_GPIO_NOVALAKE is not set
# CONFIG_GPIO_SCH311X is not set
# CONFIG_GPIO_WINBOND is not set
# CONFIG_GPIO_WS16C48 is not set
# end of Port-mapped I/O GPIO drivers

#
# I2C GPIO expanders
#
# CONFIG_GPIO_ADNP is not set
# CONFIG_GPIO_FXL6408 is not set
# CONFIG_GPIO_DS4520 is not set
# CONFIG_GPIO_GW_PLD is not set
# CONFIG_GPIO_MAX7300 is not set
# CONFIG_GPIO_MAX732X is not set
# CONFIG_GPIO_PCA953X is not set
# CONFIG_GPIO_PCA9570 is not set
# CONFIG_GPIO_PCF857X is not set
# CONFIG_GPIO_TPIC2810 is not set
# end of I2C GPIO expanders

#
# MFD GPIO expanders
#
CONFIG_GPIO_DLN2=y
CONFIG_GPIO_LJCA=y
# CONFIG_GPIO_TWL4030 is not set
# CONFIG_GPIO_WHISKEY_COVE is not set
# end of MFD GPIO expanders

#
# Auxiliary Bus GPIO drivers
#
# end of Auxiliary Bus GPIO drivers

#
# PCI GPIO expanders
#
# CONFIG_GPIO_AMD8111 is not set
# CONFIG_GPIO_BT8XX is not set
# CONFIG_GPIO_ML_IOH is not set
# CONFIG_GPIO_PCI_IDIO_16 is not set
# CONFIG_GPIO_PCIE_IDIO_24 is not set
# CONFIG_GPIO_RDC321X is not set
# CONFIG_GPIO_SODAVILLE is not set
# end of PCI GPIO expanders

#
# SPI GPIO expanders
#
# CONFIG_GPIO_74X164 is not set
# CONFIG_GPIO_MAX3191X is not set
# CONFIG_GPIO_MAX7301 is not set
# CONFIG_GPIO_MC33880 is not set
# CONFIG_GPIO_PISOSR is not set
# CONFIG_GPIO_XRA1403 is not set
# end of SPI GPIO expanders

#
# USB GPIO expanders
#
CONFIG_GPIO_VIPERBOARD=y
# CONFIG_GPIO_MPSSE is not set
# end of USB GPIO expanders

#
# Virtual GPIO drivers
#
# CONFIG_GPIO_AGGREGATOR is not set
# CONFIG_GPIO_LATCH is not set
# CONFIG_GPIO_LINE_MUX is not set
# CONFIG_GPIO_MOCKUP is not set
# CONFIG_GPIO_VIRTIO is not set
# CONFIG_GPIO_SIM is not set
# end of Virtual GPIO drivers

#
# GPIO Debugging utilities
#
# CONFIG_GPIO_SLOPPY_LOGIC_ANALYZER is not set
# CONFIG_GPIO_VIRTUSER is not set
# end of GPIO Debugging utilities

# CONFIG_W1 is not set
# CONFIG_POWER_RESET is not set
# CONFIG_POWER_SEQUENCING is not set
CONFIG_POWER_SUPPLY=y
# CONFIG_POWER_SUPPLY_DEBUG is not set
CONFIG_POWER_SUPPLY_HWMON=y
# CONFIG_GENERIC_ADC_BATTERY is not set
# CONFIG_IP5XXX_POWER is not set
# CONFIG_TEST_POWER is not set
# CONFIG_CHARGER_ADP5061 is not set
# CONFIG_BATTERY_CHAGALL is not set
# CONFIG_BATTERY_CW2015 is not set
# CONFIG_BATTERY_DS2780 is not set
# CONFIG_BATTERY_DS2781 is not set
# CONFIG_BATTERY_DS2782 is not set
# CONFIG_BATTERY_SAMSUNG_SDI is not set
# CONFIG_BATTERY_S2MU005 is not set
# CONFIG_BATTERY_SBS is not set
# CONFIG_CHARGER_SBS is not set
# CONFIG_MANAGER_SBS is not set
# CONFIG_BATTERY_BQ27XXX is not set
# CONFIG_BATTERY_MAX17040 is not set
# CONFIG_BATTERY_MAX17042 is not set
# CONFIG_BATTERY_MAX1720X is not set
CONFIG_CHARGER_ISP1704=y
# CONFIG_CHARGER_MAX8903 is not set
# CONFIG_CHARGER_TWL4030 is not set
# CONFIG_CHARGER_TWL6030 is not set
# CONFIG_CHARGER_LP8727 is not set
# CONFIG_CHARGER_GPIO is not set
# CONFIG_CHARGER_MANAGER is not set
# CONFIG_CHARGER_LT3651 is not set
# CONFIG_CHARGER_LTC4162L is not set
# CONFIG_CHARGER_DETECTOR_MAX14656 is not set
# CONFIG_CHARGER_MAX77976 is not set
# CONFIG_CHARGER_MAX8971 is not set
# CONFIG_CHARGER_MT6360 is not set
# CONFIG_CHARGER_MT6370 is not set
# CONFIG_CHARGER_BQ2415X is not set
CONFIG_CHARGER_BQ24190=y
# CONFIG_CHARGER_BQ24257 is not set
# CONFIG_CHARGER_BQ24735 is not set
# CONFIG_CHARGER_BQ2515X is not set
# CONFIG_CHARGER_BQ25890 is not set
# CONFIG_CHARGER_BQ25980 is not set
# CONFIG_CHARGER_BQ256XX is not set
# CONFIG_CHARGER_SMB347 is not set
# CONFIG_BATTERY_GAUGE_LTC2941 is not set
# CONFIG_BATTERY_GOLDFISH is not set
# CONFIG_BATTERY_RT5033 is not set
# CONFIG_CHARGER_RT9455 is not set
# CONFIG_CHARGER_RT9467 is not set
# CONFIG_CHARGER_RT9471 is not set
# CONFIG_CHARGER_RT9756 is not set
# CONFIG_FUEL_GAUGE_STC3117 is not set
# CONFIG_CHARGER_UCS1002 is not set
# CONFIG_CHARGER_BD99954 is not set
# CONFIG_BATTERY_SURFACE is not set
# CONFIG_CHARGER_SURFACE is not set
# CONFIG_BATTERY_UG3105 is not set
# CONFIG_BATTERY_CHARGER_SURFACE_RT is not set
# CONFIG_FUEL_GAUGE_MM8013 is not set
CONFIG_HWMON=y
# CONFIG_HWMON_DEBUG_CHIP is not set

#
# Native drivers
#
# CONFIG_SENSORS_ABITUGURU is not set
# CONFIG_SENSORS_ABITUGURU3 is not set
# CONFIG_SENSORS_AD7314 is not set
# CONFIG_SENSORS_AD7414 is not set
# CONFIG_SENSORS_AD7418 is not set
# CONFIG_SENSORS_ADM1025 is not set
# CONFIG_SENSORS_ADM1026 is not set
# CONFIG_SENSORS_ADM1029 is not set
# CONFIG_SENSORS_ADM1031 is not set
# CONFIG_SENSORS_ADM1177 is not set
# CONFIG_SENSORS_ADM9240 is not set
# CONFIG_SENSORS_ADT7310 is not set
# CONFIG_SENSORS_ADT7410 is not set
# CONFIG_SENSORS_ADT7411 is not set
# CONFIG_SENSORS_ADT7462 is not set
# CONFIG_SENSORS_ADT7470 is not set
# CONFIG_SENSORS_ADT7475 is not set
# CONFIG_SENSORS_AHT10 is not set
CONFIG_SENSORS_AQUACOMPUTER_D5NEXT=y
# CONFIG_SENSORS_AS370 is not set
# CONFIG_SENSORS_ASC7621 is not set
# CONFIG_SENSORS_ASUS_ROG_RYUJIN is not set
# CONFIG_SENSORS_AXI_FAN_CONTROL is not set
# CONFIG_SENSORS_K8TEMP is not set
# CONFIG_SENSORS_K10TEMP is not set
# CONFIG_SENSORS_FAM15H_POWER is not set
# CONFIG_SENSORS_APPLESMC is not set
# CONFIG_SENSORS_ARCTIC_FAN_CONTROLLER is not set
# CONFIG_SENSORS_ASB100 is not set
# CONFIG_SENSORS_ATXP1 is not set
# CONFIG_SENSORS_CHIPCAP2 is not set
CONFIG_SENSORS_CORSAIR_CPRO=y
CONFIG_SENSORS_CORSAIR_PSU=y
# CONFIG_SENSORS_DRIVETEMP is not set
# CONFIG_SENSORS_DS620 is not set
# CONFIG_SENSORS_DS1621 is not set
# CONFIG_SENSORS_DELL_SMM is not set
# CONFIG_SENSORS_I5K_AMB is not set
# CONFIG_SENSORS_F71805F is not set
# CONFIG_SENSORS_F71882FG is not set
# CONFIG_SENSORS_F75375S is not set
# CONFIG_SENSORS_FSCHMD is not set
# CONFIG_SENSORS_FTSTEUTATES is not set
CONFIG_SENSORS_GIGABYTE_WATERFORCE=y
# CONFIG_SENSORS_GL518SM is not set
# CONFIG_SENSORS_GL520SM is not set
# CONFIG_SENSORS_GPD is not set
# CONFIG_SENSORS_G760A is not set
# CONFIG_SENSORS_G762 is not set
# CONFIG_SENSORS_GPIO_FAN is not set
# CONFIG_SENSORS_HIH6130 is not set
# CONFIG_SENSORS_HS3001 is not set
# CONFIG_SENSORS_HTU31 is not set
# CONFIG_SENSORS_IIO_HWMON is not set
# CONFIG_SENSORS_I5500 is not set
# CONFIG_SENSORS_CORETEMP is not set
# CONFIG_SENSORS_ISL28022 is not set
# CONFIG_SENSORS_IT87 is not set
# CONFIG_SENSORS_JC42 is not set
CONFIG_SENSORS_POWERZ=y
# CONFIG_SENSORS_POWR1220 is not set
# CONFIG_SENSORS_PROM21_XHCI is not set
# CONFIG_SENSORS_LATTEPANDA_SIGMA_EC is not set
# CONFIG_SENSORS_LENOVO_EC is not set
# CONFIG_SENSORS_LINEAGE is not set
# CONFIG_SENSORS_LTC2945 is not set
# CONFIG_SENSORS_LTC2947_I2C is not set
# CONFIG_SENSORS_LTC2947_SPI is not set
# CONFIG_SENSORS_LTC2990 is not set
# CONFIG_SENSORS_LTC2991 is not set
# CONFIG_SENSORS_LTC2992 is not set
# CONFIG_SENSORS_LTC4151 is not set
# CONFIG_SENSORS_LTC4215 is not set
# CONFIG_SENSORS_LTC4222 is not set
# CONFIG_SENSORS_LTC4245 is not set
# CONFIG_SENSORS_LTC4260 is not set
# CONFIG_SENSORS_LTC4261 is not set
# CONFIG_SENSORS_LTC4282 is not set
# CONFIG_SENSORS_LTC4283 is not set
# CONFIG_SENSORS_MAX1111 is not set
# CONFIG_SENSORS_MAX127 is not set
# CONFIG_SENSORS_MAX16065 is not set
# CONFIG_SENSORS_MAX1619 is not set
# CONFIG_SENSORS_MAX1668 is not set
# CONFIG_SENSORS_MAX197 is not set
# CONFIG_SENSORS_MAX31722 is not set
# CONFIG_SENSORS_MAX31730 is not set
# CONFIG_SENSORS_MAX31760 is not set
# CONFIG_MAX31827 is not set
# CONFIG_SENSORS_MAX6620 is not set
# CONFIG_SENSORS_MAX6621 is not set
# CONFIG_SENSORS_MAX6639 is not set
# CONFIG_SENSORS_MAX6650 is not set
# CONFIG_SENSORS_MAX6697 is not set
# CONFIG_SENSORS_MAX31790 is not set
# CONFIG_SENSORS_MC34VR500 is not set
# CONFIG_SENSORS_MCP3021 is not set
# CONFIG_SENSORS_MCP9982 is not set
# CONFIG_SENSORS_TC654 is not set
# CONFIG_SENSORS_TPS23861 is not set
# CONFIG_SENSORS_MR75203 is not set
# CONFIG_SENSORS_ADCXX is not set
# CONFIG_SENSORS_LM63 is not set
# CONFIG_SENSORS_LM70 is not set
# CONFIG_SENSORS_LM73 is not set
# CONFIG_SENSORS_LM75 is not set
# CONFIG_SENSORS_LM77 is not set
# CONFIG_SENSORS_LM78 is not set
# CONFIG_SENSORS_LM80 is not set
# CONFIG_SENSORS_LM83 is not set
# CONFIG_SENSORS_LM85 is not set
# CONFIG_SENSORS_LM87 is not set
# CONFIG_SENSORS_LM90 is not set
# CONFIG_SENSORS_LM92 is not set
# CONFIG_SENSORS_LM93 is not set
# CONFIG_SENSORS_LM95234 is not set
# CONFIG_SENSORS_LM95241 is not set
# CONFIG_SENSORS_LM95245 is not set
# CONFIG_SENSORS_PC87360 is not set
# CONFIG_SENSORS_PC87427 is not set
# CONFIG_SENSORS_NTC_THERMISTOR is not set
# CONFIG_SENSORS_NCT6683 is not set
# CONFIG_SENSORS_NCT6775 is not set
# CONFIG_SENSORS_NCT6775_I2C is not set
# CONFIG_SENSORS_NCT7363 is not set
# CONFIG_SENSORS_NCT7802 is not set
# CONFIG_SENSORS_NCT7904 is not set
# CONFIG_SENSORS_NPCM7XX is not set
CONFIG_SENSORS_NZXT_KRAKEN2=y
# CONFIG_SENSORS_NZXT_KRAKEN3 is not set
CONFIG_SENSORS_NZXT_SMART2=y
# CONFIG_SENSORS_OCC_P8_I2C is not set
# CONFIG_SENSORS_PCF8591 is not set
# CONFIG_PMBUS is not set
# CONFIG_SENSORS_PT5161L is not set
# CONFIG_SENSORS_SBTSI is not set
# CONFIG_SENSORS_SHT15 is not set
# CONFIG_SENSORS_SHT21 is not set
# CONFIG_SENSORS_SHT3x is not set
# CONFIG_SENSORS_SHT4x is not set
# CONFIG_SENSORS_SHTC1 is not set
# CONFIG_SENSORS_SIS5595 is not set
# CONFIG_SENSORS_DME1737 is not set
# CONFIG_SENSORS_EMC1403 is not set
# CONFIG_SENSORS_EMC1812 is not set
# CONFIG_SENSORS_EMC2103 is not set
# CONFIG_SENSORS_EMC2305 is not set
# CONFIG_SENSORS_EMC6W201 is not set
# CONFIG_SENSORS_SMSC47M1 is not set
# CONFIG_SENSORS_SMSC47M192 is not set
# CONFIG_SENSORS_SMSC47B397 is not set
# CONFIG_SENSORS_SCH5627 is not set
# CONFIG_SENSORS_SCH5636 is not set
# CONFIG_SENSORS_STTS751 is not set
# CONFIG_SENSORS_SURFACE_FAN is not set
# CONFIG_SENSORS_SURFACE_TEMP is not set
# CONFIG_SENSORS_ADC128D818 is not set
# CONFIG_SENSORS_ADS7828 is not set
# CONFIG_SENSORS_ADS7871 is not set
# CONFIG_SENSORS_AMC6821 is not set
# CONFIG_SENSORS_INA209 is not set
# CONFIG_SENSORS_INA2XX is not set
# CONFIG_SENSORS_INA238 is not set
# CONFIG_SENSORS_INA3221 is not set
# CONFIG_SENSORS_SPD5118 is not set
# CONFIG_SENSORS_TC74 is not set
# CONFIG_SENSORS_THMC50 is not set
# CONFIG_SENSORS_TMP102 is not set
# CONFIG_SENSORS_TMP103 is not set
# CONFIG_SENSORS_TMP108 is not set
# CONFIG_SENSORS_TMP401 is not set
# CONFIG_SENSORS_TMP421 is not set
# CONFIG_SENSORS_TMP464 is not set
# CONFIG_SENSORS_TMP513 is not set
# CONFIG_SENSORS_TSC1641 is not set
# CONFIG_SENSORS_VIA_CPUTEMP is not set
# CONFIG_SENSORS_VIA686A is not set
# CONFIG_SENSORS_VT1211 is not set
# CONFIG_SENSORS_VT8231 is not set
# CONFIG_SENSORS_W83773G is not set
# CONFIG_SENSORS_W83781D is not set
# CONFIG_SENSORS_W83791D is not set
# CONFIG_SENSORS_W83792D is not set
# CONFIG_SENSORS_W83793 is not set
# CONFIG_SENSORS_W83795 is not set
# CONFIG_SENSORS_W83L785TS is not set
# CONFIG_SENSORS_W83L786NG is not set
# CONFIG_SENSORS_W83627HF is not set
# CONFIG_SENSORS_W83627EHF is not set
# CONFIG_SENSORS_XGENE is not set
# CONFIG_SENSORS_YOGAFAN is not set

#
# ACPI drivers
#
# CONFIG_SENSORS_ACPI_POWER is not set
# CONFIG_SENSORS_ATK0110 is not set
# CONFIG_SENSORS_ASUS_WMI is not set
# CONFIG_SENSORS_ASUS_EC is not set
# CONFIG_SENSORS_HP_WMI is not set
CONFIG_THERMAL=y
CONFIG_THERMAL_NETLINK=y
# CONFIG_THERMAL_STATISTICS is not set
# CONFIG_THERMAL_DEBUGFS is not set
# CONFIG_THERMAL_CORE_TESTING is not set
CONFIG_THERMAL_EMERGENCY_POWEROFF_DELAY_MS=0
CONFIG_THERMAL_HWMON=y
# CONFIG_THERMAL_OF is not set
CONFIG_THERMAL_DEFAULT_GOV_STEP_WISE=y
# CONFIG_THERMAL_DEFAULT_GOV_FAIR_SHARE is not set
# CONFIG_THERMAL_DEFAULT_GOV_USER_SPACE is not set
# CONFIG_THERMAL_GOV_FAIR_SHARE is not set
CONFIG_THERMAL_GOV_STEP_WISE=y
# CONFIG_THERMAL_GOV_BANG_BANG is not set
# CONFIG_THERMAL_GOV_USER_SPACE is not set
# CONFIG_PCIE_THERMAL is not set
# CONFIG_THERMAL_EMULATION is not set
# CONFIG_THERMAL_MMIO is not set

#
# Intel thermal drivers
#
# CONFIG_INTEL_POWERCLAMP is not set
CONFIG_X86_THERMAL_VECTOR=y
# CONFIG_X86_PKG_TEMP_THERMAL is not set
# CONFIG_INTEL_SOC_DTS_THERMAL is not set

#
# ACPI INT340X thermal drivers
#
# CONFIG_INT340X_THERMAL is not set
# end of ACPI INT340X thermal drivers

# CONFIG_INTEL_BXT_PMIC_THERMAL is not set
# CONFIG_INTEL_PCH_THERMAL is not set
# CONFIG_INTEL_TCC_COOLING is not set
# CONFIG_INTEL_HFI_THERMAL is not set
# end of Intel thermal drivers

# CONFIG_GENERIC_ADC_THERMAL is not set
CONFIG_WATCHDOG=y
# CONFIG_WATCHDOG_CORE is not set
# CONFIG_WATCHDOG_NOWAYOUT is not set
CONFIG_WATCHDOG_HANDLE_BOOT_ENABLED=y
CONFIG_WATCHDOG_OPEN_TIMEOUT=0
# CONFIG_WATCHDOG_SYSFS is not set
# CONFIG_WATCHDOG_HRTIMER_PRETIMEOUT is not set

#
# Watchdog Pretimeout Governors
#

#
# Watchdog Device Drivers
#
# CONFIG_SOFT_WATCHDOG is not set
# CONFIG_GPIO_WATCHDOG is not set
# CONFIG_LENOVO_SE10_WDT is not set
# CONFIG_LENOVO_SE30_WDT is not set
# CONFIG_WDAT_WDT is not set
# CONFIG_XILINX_WATCHDOG is not set
# CONFIG_ZIIRAVE_WATCHDOG is not set
# CONFIG_CADENCE_WATCHDOG is not set
# CONFIG_DW_WATCHDOG is not set
# CONFIG_TWL4030_WATCHDOG is not set
# CONFIG_MAX63XX_WATCHDOG is not set
# CONFIG_RETU_WATCHDOG is not set
# CONFIG_ACQUIRE_WDT is not set
# CONFIG_ADVANTECH_WDT is not set
# CONFIG_ADVANTECH_EC_WDT is not set
# CONFIG_ALIM1535_WDT is not set
# CONFIG_ALIM7101_WDT is not set
# CONFIG_EBC_C384_WDT is not set
# CONFIG_EXAR_WDT is not set
# CONFIG_F71808E_WDT is not set
# CONFIG_SP5100_TCO is not set
# CONFIG_SBC_FITPC2_WATCHDOG is not set
# CONFIG_EUROTECH_WDT is not set
# CONFIG_IB700_WDT is not set
# CONFIG_IBMASR is not set
# CONFIG_WAFER_WDT is not set
# CONFIG_I6300ESB_WDT is not set
# CONFIG_IE6XX_WDT is not set
# CONFIG_INTEL_OC_WATCHDOG is not set
# CONFIG_ITCO_WDT is not set
# CONFIG_IT8712F_WDT is not set
# CONFIG_IT87_WDT is not set
# CONFIG_HP_WATCHDOG is not set
# CONFIG_SC1200_WDT is not set
# CONFIG_PC87413_WDT is not set
# CONFIG_NV_TCO is not set
# CONFIG_60XX_WDT is not set
# CONFIG_SMSC_SCH311X_WDT is not set
# CONFIG_SMSC37B787_WDT is not set
# CONFIG_TQMX86_WDT is not set
# CONFIG_VIA_WDT is not set
# CONFIG_W83627HF_WDT is not set
# CONFIG_W83877F_WDT is not set
# CONFIG_W83977F_WDT is not set
# CONFIG_SBC_EPX_C3_WATCHDOG is not set
# CONFIG_INTEL_MEI_WDT is not set
# CONFIG_NI903X_WDT is not set
# CONFIG_NIC7018_WDT is not set
# CONFIG_MEN_A21_WDT is not set

#
# PCI-based Watchdog Cards
#
# CONFIG_PCIPCWATCHDOG is not set
# CONFIG_WDTPCI is not set

#
# USB-based Watchdog Cards
#
CONFIG_USBPCWATCHDOG=y
CONFIG_SSB_POSSIBLE=y
CONFIG_SSB=y
CONFIG_SSB_PCIHOST_POSSIBLE=y
# CONFIG_SSB_PCIHOST is not set
CONFIG_SSB_PCMCIAHOST_POSSIBLE=y
# CONFIG_SSB_PCMCIAHOST is not set
CONFIG_SSB_SDIOHOST_POSSIBLE=y
# CONFIG_SSB_SDIOHOST is not set
# CONFIG_SSB_DRIVER_GPIO is not set
CONFIG_BCMA_POSSIBLE=y
CONFIG_BCMA=y
CONFIG_BCMA_HOST_PCI_POSSIBLE=y
# CONFIG_BCMA_HOST_PCI is not set
# CONFIG_BCMA_HOST_SOC is not set
# CONFIG_BCMA_DRIVER_PCI is not set
# CONFIG_BCMA_DRIVER_GMAC_CMN is not set
# CONFIG_BCMA_DRIVER_GPIO is not set
# CONFIG_BCMA_DEBUG is not set

#
# Multifunction device drivers
#
CONFIG_MFD_CORE=y
# CONFIG_MFD_ADP5585 is not set
# CONFIG_MFD_ACT8945A is not set
# CONFIG_MFD_AS3711 is not set
# CONFIG_MFD_SMPRO is not set
# CONFIG_MFD_AS3722 is not set
# CONFIG_PMIC_ADP5520 is not set
# CONFIG_MFD_AAT2870_CORE is not set
# CONFIG_MFD_ATMEL_FLEXCOM is not set
# CONFIG_MFD_ATMEL_HLCDC is not set
# CONFIG_MFD_BCM590XX is not set
# CONFIG_MFD_BD9571MWV is not set
# CONFIG_MFD_AXP20X_I2C is not set
# CONFIG_MFD_CGBC is not set
# CONFIG_MFD_CS40L50_I2C is not set
# CONFIG_MFD_CS40L50_SPI is not set
# CONFIG_MFD_CS42L43_I2C is not set
# CONFIG_MFD_CS42L43_SDW is not set
# CONFIG_MFD_LOCHNAGAR is not set
# CONFIG_MFD_MADERA is not set
# CONFIG_PMIC_DA903X is not set
# CONFIG_MFD_DA9052_SPI is not set
# CONFIG_MFD_DA9052_I2C is not set
# CONFIG_MFD_DA9055 is not set
# CONFIG_MFD_DA9062 is not set
# CONFIG_MFD_DA9063 is not set
# CONFIG_MFD_DA9150 is not set
CONFIG_MFD_DLN2=y
# CONFIG_MFD_GATEWORKS_GSC is not set
# CONFIG_MFD_MC13XXX_SPI is not set
# CONFIG_MFD_MC13XXX_I2C is not set
# CONFIG_MFD_MP2629 is not set
# CONFIG_MFD_PF1550 is not set
# CONFIG_MFD_HI6421_PMIC is not set
# CONFIG_MFD_INTEL_QUARK_I2C_GPIO is not set
CONFIG_LPC_ICH=y
# CONFIG_LPC_SCH is not set
# CONFIG_INTEL_SOC_PMIC is not set
CONFIG_INTEL_SOC_PMIC_BXTWC=y
CONFIG_INTEL_SOC_PMIC_CHTWC=y
# CONFIG_INTEL_SOC_PMIC_CHTDC_TI is not set
# CONFIG_MFD_INTEL_LPSS_ACPI is not set
# CONFIG_MFD_INTEL_LPSS_PCI is not set
CONFIG_MFD_INTEL_PMC_BXT=y
# CONFIG_MFD_IQS62X is not set
# CONFIG_MFD_JANZ_CMODIO is not set
# CONFIG_MFD_KEMPLD is not set
# CONFIG_MFD_88PM800 is not set
# CONFIG_MFD_88PM805 is not set
# CONFIG_MFD_88PM860X is not set
# CONFIG_MFD_88PM886_PMIC is not set
# CONFIG_MFD_MAX5970 is not set
# CONFIG_MFD_MAX14577 is not set
# CONFIG_MFD_MAX77541 is not set
# CONFIG_MFD_MAX77620 is not set
# CONFIG_MFD_MAX77650 is not set
# CONFIG_MFD_MAX77686 is not set
# CONFIG_MFD_MAX77693 is not set
# CONFIG_MFD_MAX77705 is not set
# CONFIG_MFD_MAX77714 is not set
# CONFIG_MFD_MAX77759 is not set
# CONFIG_MFD_MAX77843 is not set
# CONFIG_MFD_MAX8907 is not set
# CONFIG_MFD_MAX8925 is not set
# CONFIG_MFD_MAX8997 is not set
# CONFIG_MFD_MAX8998 is not set
CONFIG_MFD_MT6360=y
CONFIG_MFD_MT6370=y
# CONFIG_MFD_MT6397 is not set
# CONFIG_MFD_MENF21BMC is not set
# CONFIG_MFD_NCT6694 is not set
# CONFIG_MFD_OCELOT is not set
# CONFIG_MFD_CPCAP is not set
CONFIG_MFD_VIPERBOARD=y
# CONFIG_MFD_NTXEC is not set
CONFIG_MFD_RETU=y
# CONFIG_MFD_SY7636A is not set
# CONFIG_MFD_RDC321X is not set
# CONFIG_MFD_RT4831 is not set
# CONFIG_MFD_RT5033 is not set
# CONFIG_MFD_RT5120 is not set
# CONFIG_MFD_RC5T583 is not set
# CONFIG_MFD_RK8XX_I2C is not set
# CONFIG_MFD_RK8XX_SPI is not set
# CONFIG_MFD_RN5T618 is not set
# CONFIG_MFD_SEC_I2C is not set
# CONFIG_MFD_SI476X_CORE is not set
# CONFIG_MFD_SM501 is not set
# CONFIG_MFD_SKY81452 is not set
# CONFIG_MFD_STMPE is not set
CONFIG_MFD_SYSCON=y
# CONFIG_MFD_LP3943 is not set
# CONFIG_MFD_LP8788 is not set
# CONFIG_MFD_TI_LMU is not set
# CONFIG_MFD_BQ257XX is not set
# CONFIG_MFD_PALMAS is not set
# CONFIG_TPS6105X is not set
# CONFIG_TPS65010 is not set
# CONFIG_TPS6507X is not set
# CONFIG_MFD_TPS65086 is not set
# CONFIG_MFD_TPS65090 is not set
# CONFIG_MFD_TPS65217 is not set
# CONFIG_MFD_TI_LP873X is not set
# CONFIG_MFD_TI_LP87565 is not set
# CONFIG_MFD_TPS65218 is not set
# CONFIG_MFD_TPS65219 is not set
# CONFIG_MFD_TPS6586X is not set
# CONFIG_MFD_TPS65910 is not set
# CONFIG_MFD_TPS65912_I2C is not set
# CONFIG_MFD_TPS65912_SPI is not set
# CONFIG_MFD_TPS6594_I2C is not set
# CONFIG_MFD_TPS6594_SPI is not set
CONFIG_TWL4030_CORE=y
# CONFIG_MFD_TWL4030_AUDIO is not set
# CONFIG_TWL6040_CORE is not set
# CONFIG_MFD_LM3533 is not set
# CONFIG_MFD_TC3589X is not set
# CONFIG_MFD_TQMX86 is not set
# CONFIG_MFD_VX855 is not set
# CONFIG_MFD_ARIZONA_I2C is not set
# CONFIG_MFD_ARIZONA_SPI is not set
# CONFIG_MFD_WM8400 is not set
# CONFIG_MFD_WM831X_I2C is not set
# CONFIG_MFD_WM831X_SPI is not set
# CONFIG_MFD_WM8350_I2C is not set
# CONFIG_MFD_WM8994 is not set
# CONFIG_MFD_ROHM_BD718XX is not set
# CONFIG_MFD_ROHM_BD71828 is not set
# CONFIG_MFD_ROHM_BD957XMUF is not set
# CONFIG_MFD_ROHM_BD96801 is not set
# CONFIG_MFD_STPMIC1 is not set
# CONFIG_MFD_STMFX is not set
# CONFIG_MFD_ATC260X_I2C is not set
# CONFIG_MFD_QCOM_PM8008 is not set
# CONFIG_RAVE_SP_CORE is not set
# CONFIG_MFD_INTEL_M10_BMC_SPI is not set
# CONFIG_MFD_QNAP_MCU is not set
# CONFIG_MFD_RSMU_I2C is not set
# CONFIG_MFD_RSMU_SPI is not set
# CONFIG_MFD_UPBOARD_FPGA is not set
# CONFIG_MFD_MAX7360 is not set
# end of Multifunction device drivers

CONFIG_REGULATOR=y
# CONFIG_REGULATOR_DEBUG is not set
CONFIG_REGULATOR_FIXED_VOLTAGE=y
# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set
# CONFIG_REGULATOR_USERSPACE_CONSUMER is not set
# CONFIG_REGULATOR_NETLINK_EVENTS is not set
# CONFIG_REGULATOR_88PG86X is not set
# CONFIG_REGULATOR_ACT8865 is not set
# CONFIG_REGULATOR_AD5398 is not set
# CONFIG_REGULATOR_ADP5055 is not set
# CONFIG_REGULATOR_AW37503 is not set
# CONFIG_REGULATOR_DA9121 is not set
# CONFIG_REGULATOR_DA9210 is not set
# CONFIG_REGULATOR_DA9211 is not set
# CONFIG_REGULATOR_FAN53555 is not set
# CONFIG_REGULATOR_FAN53880 is not set
# CONFIG_REGULATOR_GPIO is not set
# CONFIG_REGULATOR_ISL9305 is not set
# CONFIG_REGULATOR_ISL6271A is not set
# CONFIG_REGULATOR_FP9931 is not set
# CONFIG_REGULATOR_LP3971 is not set
# CONFIG_REGULATOR_LP3972 is not set
# CONFIG_REGULATOR_LP872X is not set
# CONFIG_REGULATOR_LP8755 is not set
# CONFIG_REGULATOR_LTC3589 is not set
# CONFIG_REGULATOR_LTC3676 is not set
# CONFIG_REGULATOR_MAX1586 is not set
# CONFIG_REGULATOR_MAX77503 is not set
# CONFIG_REGULATOR_MAX77675 is not set
# CONFIG_REGULATOR_MAX77857 is not set
# CONFIG_REGULATOR_MAX8649 is not set
# CONFIG_REGULATOR_MAX8660 is not set
# CONFIG_REGULATOR_MAX8893 is not set
# CONFIG_REGULATOR_MAX8952 is not set
# CONFIG_REGULATOR_MAX20086 is not set
# CONFIG_REGULATOR_MAX20411 is not set
# CONFIG_REGULATOR_MAX77826 is not set
# CONFIG_REGULATOR_MAX77838 is not set
# CONFIG_REGULATOR_MCP16502 is not set
# CONFIG_REGULATOR_MP5416 is not set
# CONFIG_REGULATOR_MP8859 is not set
# CONFIG_REGULATOR_MP886X is not set
# CONFIG_REGULATOR_MPQ7920 is not set
# CONFIG_REGULATOR_MT6311 is not set
# CONFIG_REGULATOR_MT6360 is not set
# CONFIG_REGULATOR_MT6370 is not set
# CONFIG_REGULATOR_PCA9450 is not set
# CONFIG_REGULATOR_PF9453 is not set
# CONFIG_REGULATOR_PF0900 is not set
# CONFIG_REGULATOR_PF530X is not set
# CONFIG_REGULATOR_PF8X00 is not set
# CONFIG_REGULATOR_PFUZE100 is not set
# CONFIG_REGULATOR_PV88060 is not set
# CONFIG_REGULATOR_PV88080 is not set
# CONFIG_REGULATOR_PV88090 is not set
# CONFIG_REGULATOR_RAA215300 is not set
# CONFIG_REGULATOR_RT4801 is not set
# CONFIG_REGULATOR_RT4803 is not set
# CONFIG_REGULATOR_RT5133 is not set
# CONFIG_REGULATOR_RT5190A is not set
# CONFIG_REGULATOR_RT5739 is not set
# CONFIG_REGULATOR_RT5759 is not set
# CONFIG_REGULATOR_RT6160 is not set
# CONFIG_REGULATOR_RT6190 is not set
# CONFIG_REGULATOR_RT6245 is not set
# CONFIG_REGULATOR_RT8092 is not set
# CONFIG_REGULATOR_RTQ2134 is not set
# CONFIG_REGULATOR_RTMV20 is not set
# CONFIG_REGULATOR_RTQ6752 is not set
# CONFIG_REGULATOR_RTQ2208 is not set
# CONFIG_REGULATOR_SGM3804 is not set
# CONFIG_REGULATOR_SLG51000 is not set
# CONFIG_REGULATOR_SY8106A is not set
# CONFIG_REGULATOR_SY8824X is not set
# CONFIG_REGULATOR_SY8827N is not set
# CONFIG_REGULATOR_TPS51632 is not set
# CONFIG_REGULATOR_TPS62360 is not set
# CONFIG_REGULATOR_TPS6286X is not set
# CONFIG_REGULATOR_TPS6287X is not set
# CONFIG_REGULATOR_TPS65023 is not set
# CONFIG_REGULATOR_TPS6507X is not set
# CONFIG_REGULATOR_TPS65132 is not set
# CONFIG_REGULATOR_TPS65185 is not set
# CONFIG_REGULATOR_TPS6524X is not set
CONFIG_REGULATOR_TWL4030=y
# CONFIG_REGULATOR_VCTRL is not set
CONFIG_RC_CORE=y
# CONFIG_LIRC is not set
# CONFIG_RC_MAP is not set
# CONFIG_RC_DECODERS is not set
CONFIG_RC_DEVICES=y
# CONFIG_IR_ENE is not set
# CONFIG_IR_FINTEK is not set
# CONFIG_IR_GPIO_CIR is not set
# CONFIG_IR_HIX5HD2 is not set
CONFIG_IR_IGORPLUGUSB=y
CONFIG_IR_IGUANA=y
CONFIG_IR_IMON=y
CONFIG_IR_IMON_RAW=y
# CONFIG_IR_ITE_CIR is not set
CONFIG_IR_MCEUSB=y
# CONFIG_IR_NUVOTON is not set
CONFIG_IR_REDRAT3=y
# CONFIG_IR_SERIAL is not set
CONFIG_IR_STREAMZAP=y
CONFIG_IR_TOY=y
CONFIG_IR_TTUSBIR=y
# CONFIG_IR_WINBOND_CIR is not set
CONFIG_RC_ATI_REMOTE=y
# CONFIG_RC_LOOPBACK is not set
CONFIG_RC_XBOX_DVD=y
CONFIG_CEC_CORE=y

#
# CEC support
#
# CONFIG_MEDIA_CEC_RC is not set
CONFIG_MEDIA_CEC_SUPPORT=y
# CONFIG_CEC_CH7322 is not set
# CONFIG_CEC_NXP_TDA9950 is not set
# CONFIG_CEC_GPIO is not set
# CONFIG_CEC_SECO is not set
# CONFIG_USB_EXTRON_DA_HD_4K_PLUS_CEC is not set
CONFIG_USB_PULSE8_CEC=y
CONFIG_USB_RAINSHADOW_CEC=y
# end of CEC support

CONFIG_MEDIA_SUPPORT=y
CONFIG_MEDIA_SUPPORT_FILTER=y
# CONFIG_MEDIA_SUBDRV_AUTOSELECT is not set

#
# Media device types
#
CONFIG_MEDIA_CAMERA_SUPPORT=y
CONFIG_MEDIA_ANALOG_TV_SUPPORT=y
CONFIG_MEDIA_DIGITAL_TV_SUPPORT=y
CONFIG_MEDIA_RADIO_SUPPORT=y
CONFIG_MEDIA_SDR_SUPPORT=y
CONFIG_MEDIA_PLATFORM_SUPPORT=y
CONFIG_MEDIA_TEST_SUPPORT=y
# end of Media device types

CONFIG_VIDEO_DEV=y
CONFIG_MEDIA_CONTROLLER=y
CONFIG_DVB_CORE=y

#
# Video4Linux options
#
CONFIG_VIDEO_V4L2_I2C=y
CONFIG_VIDEO_V4L2_SUBDEV_API=y
# CONFIG_VIDEO_ADV_DEBUG is not set
# CONFIG_VIDEO_FIXED_MINOR_RANGES is not set
CONFIG_VIDEO_TUNER=y
CONFIG_V4L2_MEM2MEM_DEV=y
# end of Video4Linux options

#
# Media controller options
#
CONFIG_MEDIA_CONTROLLER_DVB=y
# end of Media controller options

#
# Digital TV options
#
# CONFIG_DVB_MMAP is not set
# CONFIG_DVB_NET is not set
CONFIG_DVB_MAX_ADAPTERS=16
# CONFIG_DVB_DYNAMIC_MINORS is not set
# CONFIG_DVB_DEMUX_SECTION_LOSS_LOG is not set
# CONFIG_DVB_ULE_DEBUG is not set
# end of Digital TV options

#
# Media drivers
#

#
# Drivers filtered as selected at 'Filter media drivers'
#

#
# Media drivers
#
CONFIG_MEDIA_USB_SUPPORT=y

#
# Webcam devices
#
CONFIG_USB_GSPCA=y
CONFIG_USB_GSPCA_BENQ=y
CONFIG_USB_GSPCA_CONEX=y
CONFIG_USB_GSPCA_CPIA1=y
CONFIG_USB_GSPCA_DTCS033=y
CONFIG_USB_GSPCA_ETOMS=y
CONFIG_USB_GSPCA_FINEPIX=y
CONFIG_USB_GSPCA_JEILINJ=y
CONFIG_USB_GSPCA_JL2005BCD=y
CONFIG_USB_GSPCA_KINECT=y
CONFIG_USB_GSPCA_KONICA=y
CONFIG_USB_GSPCA_MARS=y
CONFIG_USB_GSPCA_MR97310A=y
CONFIG_USB_GSPCA_NW80X=y
CONFIG_USB_GSPCA_OV519=y
CONFIG_USB_GSPCA_OV534=y
CONFIG_USB_GSPCA_OV534_9=y
CONFIG_USB_GSPCA_PAC207=y
CONFIG_USB_GSPCA_PAC7302=y
CONFIG_USB_GSPCA_PAC7311=y
CONFIG_USB_GSPCA_SE401=y
CONFIG_USB_GSPCA_SN9C2028=y
CONFIG_USB_GSPCA_SN9C20X=y
CONFIG_USB_GSPCA_SONIXB=y
CONFIG_USB_GSPCA_SONIXJ=y
CONFIG_USB_GSPCA_SPCA1528=y
CONFIG_USB_GSPCA_SPCA500=y
CONFIG_USB_GSPCA_SPCA501=y
CONFIG_USB_GSPCA_SPCA505=y
CONFIG_USB_GSPCA_SPCA506=y
CONFIG_USB_GSPCA_SPCA508=y
CONFIG_USB_GSPCA_SPCA561=y
CONFIG_USB_GSPCA_SQ905=y
CONFIG_USB_GSPCA_SQ905C=y
CONFIG_USB_GSPCA_SQ930X=y
CONFIG_USB_GSPCA_STK014=y
CONFIG_USB_GSPCA_STK1135=y
CONFIG_USB_GSPCA_STV0680=y
CONFIG_USB_GSPCA_SUNPLUS=y
CONFIG_USB_GSPCA_T613=y
CONFIG_USB_GSPCA_TOPRO=y
CONFIG_USB_GSPCA_TOUPTEK=y
CONFIG_USB_GSPCA_TV8532=y
CONFIG_USB_GSPCA_VC032X=y
CONFIG_USB_GSPCA_VICAM=y
CONFIG_USB_GSPCA_XIRLINK_CIT=y
CONFIG_USB_GSPCA_ZC3XX=y
CONFIG_USB_GL860=y
CONFIG_USB_M5602=y
CONFIG_USB_STV06XX=y
CONFIG_USB_PWC=y
# CONFIG_USB_PWC_DEBUG is not set
CONFIG_USB_PWC_INPUT_EVDEV=y
CONFIG_USB_S2255=y
CONFIG_VIDEO_USBTV=y
CONFIG_USB_VIDEO_CLASS=y
CONFIG_USB_VIDEO_CLASS_INPUT_EVDEV=y

#
# Analog TV USB devices
#
CONFIG_VIDEO_GO7007=y
CONFIG_VIDEO_GO7007_USB=y
CONFIG_VIDEO_GO7007_LOADER=y
CONFIG_VIDEO_GO7007_USB_S2250_BOARD=y
CONFIG_VIDEO_HDPVR=y
CONFIG_VIDEO_PVRUSB2=y
CONFIG_VIDEO_PVRUSB2_SYSFS=y
CONFIG_VIDEO_PVRUSB2_DVB=y
# CONFIG_VIDEO_PVRUSB2_DEBUGIFC is not set
CONFIG_VIDEO_STK1160=y

#
# Analog/digital TV USB devices
#
CONFIG_VIDEO_AU0828=y
CONFIG_VIDEO_AU0828_V4L2=y
CONFIG_VIDEO_AU0828_RC=y
CONFIG_VIDEO_CX231XX=y
CONFIG_VIDEO_CX231XX_RC=y
CONFIG_VIDEO_CX231XX_ALSA=y
CONFIG_VIDEO_CX231XX_DVB=y

#
# Digital TV USB devices
#
CONFIG_DVB_AS102=y
CONFIG_DVB_B2C2_FLEXCOP_USB=y
# CONFIG_DVB_B2C2_FLEXCOP_USB_DEBUG is not set
CONFIG_DVB_USB_V2=y
CONFIG_DVB_USB_AF9015=y
CONFIG_DVB_USB_AF9035=y
CONFIG_DVB_USB_ANYSEE=y
CONFIG_DVB_USB_AU6610=y
CONFIG_DVB_USB_AZ6007=y
CONFIG_DVB_USB_CE6230=y
CONFIG_DVB_USB_DVBSKY=y
CONFIG_DVB_USB_EC168=y
CONFIG_DVB_USB_GL861=y
CONFIG_DVB_USB_LME2510=y
CONFIG_DVB_USB_MXL111SF=y
CONFIG_DVB_USB_RTL28XXU=y
CONFIG_DVB_USB_ZD1301=y
CONFIG_DVB_USB=y
# CONFIG_DVB_USB_DEBUG is not set
CONFIG_DVB_USB_A800=y
CONFIG_DVB_USB_AF9005=y
CONFIG_DVB_USB_AF9005_REMOTE=y
CONFIG_DVB_USB_AZ6027=y
CONFIG_DVB_USB_CINERGY_T2=y
CONFIG_DVB_USB_CXUSB=y
CONFIG_DVB_USB_CXUSB_ANALOG=y
CONFIG_DVB_USB_DIB0700=y
CONFIG_DVB_USB_DIB3000MC=y
CONFIG_DVB_USB_DIBUSB_MB=y
# CONFIG_DVB_USB_DIBUSB_MB_FAULTY is not set
CONFIG_DVB_USB_DIBUSB_MC=y
CONFIG_DVB_USB_DIGITV=y
CONFIG_DVB_USB_DTT200U=y
CONFIG_DVB_USB_DTV5100=y
CONFIG_DVB_USB_DW2102=y
CONFIG_DVB_USB_GP8PSK=y
CONFIG_DVB_USB_M920X=y
CONFIG_DVB_USB_NOVA_T_USB2=y
CONFIG_DVB_USB_OPERA1=y
CONFIG_DVB_USB_PCTV452E=y
CONFIG_DVB_USB_TECHNISAT_USB2=y
CONFIG_DVB_USB_TTUSB2=y
CONFIG_DVB_USB_UMT_010=y
CONFIG_DVB_USB_VP702X=y
CONFIG_DVB_USB_VP7045=y
CONFIG_SMS_USB_DRV=y
CONFIG_DVB_TTUSB_BUDGET=y
CONFIG_DVB_TTUSB_DEC=y

#
# Webcam, TV (analog/digital) USB devices
#
CONFIG_VIDEO_EM28XX=y
CONFIG_VIDEO_EM28XX_V4L2=y
CONFIG_VIDEO_EM28XX_ALSA=y
CONFIG_VIDEO_EM28XX_DVB=y
CONFIG_VIDEO_EM28XX_RC=y

#
# Software defined radio USB devices
#
CONFIG_USB_AIRSPY=y
CONFIG_USB_HACKRF=y
CONFIG_USB_MSI2500=y
# CONFIG_MEDIA_PCI_SUPPORT is not set
CONFIG_RADIO_ADAPTERS=y
# CONFIG_RADIO_MAXIRADIO is not set
# CONFIG_RADIO_SAA7706H is not set
CONFIG_RADIO_SHARK=y
CONFIG_RADIO_SHARK2=y
CONFIG_RADIO_SI4713=y
CONFIG_RADIO_TEA575X=y
# CONFIG_RADIO_TEA5764 is not set
# CONFIG_RADIO_TEF6862 is not set
CONFIG_USB_DSBR=y
CONFIG_USB_KEENE=y
CONFIG_USB_MA901=y
CONFIG_USB_MR800=y
CONFIG_USB_RAREMONO=y
CONFIG_RADIO_SI470X=y
CONFIG_USB_SI470X=y
# CONFIG_I2C_SI470X is not set
CONFIG_USB_SI4713=y
# CONFIG_PLATFORM_SI4713 is not set
CONFIG_I2C_SI4713=y
# CONFIG_MEDIA_PLATFORM_DRIVERS is not set

#
# MMC/SDIO DVB adapters
#
CONFIG_SMS_SDIO_DRV=y
CONFIG_V4L_TEST_DRIVERS=y
CONFIG_VIDEO_VIM2M=y
CONFIG_VIDEO_VICODEC=y
CONFIG_VIDEO_VIMC=y
CONFIG_VIDEO_VIVID=y
CONFIG_VIDEO_VIVID_CEC=y
# CONFIG_VIDEO_VIVID_OSD is not set
CONFIG_VIDEO_VIVID_MAX_DEVS=64
# CONFIG_VIDEO_VISL is not set
CONFIG_DVB_TEST_DRIVERS=y
CONFIG_DVB_VIDTV=y

#
# FireWire (IEEE 1394) Adapters
#
# CONFIG_DVB_FIREDTV is not set
CONFIG_MEDIA_COMMON_OPTIONS=y

#
# common driver options
#
CONFIG_CYPRESS_FIRMWARE=y
CONFIG_TTPCI_EEPROM=y
CONFIG_UVC_COMMON=y
CONFIG_VIDEO_CX2341X=y
CONFIG_VIDEO_TVEEPROM=y
CONFIG_DVB_B2C2_FLEXCOP=y
CONFIG_SMS_SIANO_MDTV=y
CONFIG_SMS_SIANO_RC=y
CONFIG_SMS_SIANO_DEBUGFS=y
CONFIG_VIDEO_V4L2_TPG=y
CONFIG_VIDEOBUF2_CORE=y
CONFIG_VIDEOBUF2_V4L2=y
CONFIG_VIDEOBUF2_MEMOPS=y
CONFIG_VIDEOBUF2_DMA_CONTIG=y
CONFIG_VIDEOBUF2_VMALLOC=y
CONFIG_VIDEOBUF2_DMA_SG=y
# end of Media drivers

#
# Media ancillary drivers
#
CONFIG_MEDIA_ATTACH=y
# CONFIG_VIDEO_IR_I2C is not set
# CONFIG_VIDEO_CAMERA_SENSOR is not set

#
# Camera ISPs
#
# CONFIG_VIDEO_THP7312 is not set
# end of Camera ISPs

# CONFIG_VIDEO_CAMERA_LENS is not set

#
# Flash devices
#
# CONFIG_VIDEO_ADP1653 is not set
# CONFIG_VIDEO_LM3560 is not set
# CONFIG_VIDEO_LM3646 is not set
# end of Flash devices

#
# Audio decoders, processors and mixers
#
# CONFIG_VIDEO_CS3308 is not set
# CONFIG_VIDEO_CS5345 is not set
CONFIG_VIDEO_CS53L32A=y
CONFIG_VIDEO_MSP3400=y
# CONFIG_VIDEO_SONY_BTF_MPX is not set
# CONFIG_VIDEO_TDA1997X is not set
# CONFIG_VIDEO_TDA7432 is not set
# CONFIG_VIDEO_TDA9840 is not set
# CONFIG_VIDEO_TEA6415C is not set
# CONFIG_VIDEO_TEA6420 is not set
# CONFIG_VIDEO_TLV320AIC23B is not set
# CONFIG_VIDEO_TVAUDIO is not set
# CONFIG_VIDEO_UDA1342 is not set
# CONFIG_VIDEO_VP27SMPX is not set
# CONFIG_VIDEO_WM8739 is not set
CONFIG_VIDEO_WM8775=y
# end of Audio decoders, processors and mixers

#
# RDS decoders
#
# CONFIG_VIDEO_SAA6588 is not set
# end of RDS decoders

#
# Video decoders
#
# CONFIG_VIDEO_ADV7180 is not set
# CONFIG_VIDEO_ADV7183 is not set
# CONFIG_VIDEO_ADV748X is not set
# CONFIG_VIDEO_ADV7604 is not set
# CONFIG_VIDEO_ADV7842 is not set
# CONFIG_VIDEO_BT819 is not set
# CONFIG_VIDEO_BT856 is not set
# CONFIG_VIDEO_BT866 is not set
# CONFIG_VIDEO_ISL7998X is not set
# CONFIG_VIDEO_LT6911UXE is not set
# CONFIG_VIDEO_KS0127 is not set
# CONFIG_VIDEO_MAX9286 is not set
# CONFIG_VIDEO_ML86V7667 is not set
# CONFIG_VIDEO_SAA7110 is not set
CONFIG_VIDEO_SAA711X=y
# CONFIG_VIDEO_TC358743 is not set
# CONFIG_VIDEO_TC358746 is not set
# CONFIG_VIDEO_TVP514X is not set
# CONFIG_VIDEO_TVP5150 is not set
# CONFIG_VIDEO_TVP7002 is not set
# CONFIG_VIDEO_TW2804 is not set
# CONFIG_VIDEO_TW9900 is not set
# CONFIG_VIDEO_TW9903 is not set
# CONFIG_VIDEO_TW9906 is not set
# CONFIG_VIDEO_TW9910 is not set
# CONFIG_VIDEO_VPX3220 is not set

#
# Video and audio decoders
#
# CONFIG_VIDEO_SAA717X is not set
CONFIG_VIDEO_CX25840=y
# end of Video decoders

#
# Video encoders
#
# CONFIG_VIDEO_ADV7170 is not set
# CONFIG_VIDEO_ADV7175 is not set
# CONFIG_VIDEO_ADV7343 is not set
# CONFIG_VIDEO_ADV7393 is not set
# CONFIG_VIDEO_ADV7511 is not set
# CONFIG_VIDEO_AK881X is not set
# CONFIG_VIDEO_SAA7127 is not set
# CONFIG_VIDEO_SAA7185 is not set
# CONFIG_VIDEO_THS8200 is not set
# end of Video encoders

#
# Video improvement chips
#
# CONFIG_VIDEO_UPD64031A is not set
# CONFIG_VIDEO_UPD64083 is not set
# end of Video improvement chips

#
# Audio/Video compression chips
#
# CONFIG_VIDEO_SAA6752HS is not set
# end of Audio/Video compression chips

#
# SDR tuner chips
#
# CONFIG_SDR_MAX2175 is not set
# end of SDR tuner chips

#
# Miscellaneous helper chips
#
# CONFIG_VIDEO_INTEL_CVS is not set
# CONFIG_VIDEO_I2C is not set
# CONFIG_VIDEO_M52790 is not set
# CONFIG_VIDEO_ST_MIPID02 is not set
# CONFIG_VIDEO_THS7303 is not set
# end of Miscellaneous helper chips

#
# Video serializers and deserializers
#
# CONFIG_VIDEO_DS90UB913 is not set
# CONFIG_VIDEO_DS90UB953 is not set
# CONFIG_VIDEO_DS90UB960 is not set
# CONFIG_VIDEO_MAX96714 is not set
# CONFIG_VIDEO_MAX96717 is not set
# end of Video serializers and deserializers

#
# Media SPI Adapters
#
# CONFIG_CXD2880_SPI_DRV is not set
# CONFIG_VIDEO_GS1662 is not set
# end of Media SPI Adapters

CONFIG_MEDIA_TUNER=y

#
# Customize TV tuners
#
# CONFIG_MEDIA_TUNER_E4000 is not set
# CONFIG_MEDIA_TUNER_FC0011 is not set
# CONFIG_MEDIA_TUNER_FC0012 is not set
# CONFIG_MEDIA_TUNER_FC0013 is not set
# CONFIG_MEDIA_TUNER_FC2580 is not set
# CONFIG_MEDIA_TUNER_IT913X is not set
# CONFIG_MEDIA_TUNER_M88RS6000T is not set
# CONFIG_MEDIA_TUNER_MAX2165 is not set
# CONFIG_MEDIA_TUNER_MC44S803 is not set
CONFIG_MEDIA_TUNER_MSI001=y
# CONFIG_MEDIA_TUNER_MT2060 is not set
# CONFIG_MEDIA_TUNER_MT2063 is not set
# CONFIG_MEDIA_TUNER_MT20XX is not set
# CONFIG_MEDIA_TUNER_MT2131 is not set
# CONFIG_MEDIA_TUNER_MT2266 is not set
# CONFIG_MEDIA_TUNER_MXL301RF is not set
# CONFIG_MEDIA_TUNER_MXL5005S is not set
# CONFIG_MEDIA_TUNER_MXL5007T is not set
# CONFIG_MEDIA_TUNER_QM1D1B0004 is not set
# CONFIG_MEDIA_TUNER_QM1D1C0042 is not set
# CONFIG_MEDIA_TUNER_QT1010 is not set
# CONFIG_MEDIA_TUNER_R820T is not set
# CONFIG_MEDIA_TUNER_SI2157 is not set
# CONFIG_MEDIA_TUNER_SIMPLE is not set
# CONFIG_MEDIA_TUNER_TDA18212 is not set
# CONFIG_MEDIA_TUNER_TDA18218 is not set
# CONFIG_MEDIA_TUNER_TDA18250 is not set
# CONFIG_MEDIA_TUNER_TDA18271 is not set
# CONFIG_MEDIA_TUNER_TDA827X is not set
# CONFIG_MEDIA_TUNER_TDA8290 is not set
# CONFIG_MEDIA_TUNER_TDA9887 is not set
# CONFIG_MEDIA_TUNER_TEA5761 is not set
# CONFIG_MEDIA_TUNER_TEA5767 is not set
# CONFIG_MEDIA_TUNER_TUA9001 is not set
# CONFIG_MEDIA_TUNER_XC2028 is not set
# CONFIG_MEDIA_TUNER_XC4000 is not set
# CONFIG_MEDIA_TUNER_XC5000 is not set
# end of Customize TV tuners

#
# Customise DVB Frontends
#

#
# Multistandard (satellite) frontends
#
# CONFIG_DVB_M88DS3103 is not set
# CONFIG_DVB_MXL5XX is not set
# CONFIG_DVB_STB0899 is not set
# CONFIG_DVB_STB6100 is not set
# CONFIG_DVB_STV090x is not set
# CONFIG_DVB_STV0910 is not set
# CONFIG_DVB_STV6110x is not set
# CONFIG_DVB_STV6111 is not set

#
# Multistandard (cable + terrestrial) frontends
#
# CONFIG_DVB_DRXK is not set
# CONFIG_DVB_MN88472 is not set
# CONFIG_DVB_MN88473 is not set
# CONFIG_DVB_SI2165 is not set
# CONFIG_DVB_TDA18271C2DD is not set

#
# DVB-S (satellite) frontends
#
# CONFIG_DVB_CX24110 is not set
# CONFIG_DVB_CX24116 is not set
# CONFIG_DVB_CX24117 is not set
# CONFIG_DVB_CX24120 is not set
# CONFIG_DVB_CX24123 is not set
# CONFIG_DVB_DS3000 is not set
# CONFIG_DVB_MB86A16 is not set
# CONFIG_DVB_MT312 is not set
# CONFIG_DVB_S5H1420 is not set
# CONFIG_DVB_SI21XX is not set
# CONFIG_DVB_STB6000 is not set
# CONFIG_DVB_STV0288 is not set
# CONFIG_DVB_STV0299 is not set
# CONFIG_DVB_STV0900 is not set
# CONFIG_DVB_STV6110 is not set
# CONFIG_DVB_TDA10071 is not set
# CONFIG_DVB_TDA10086 is not set
# CONFIG_DVB_TDA8083 is not set
# CONFIG_DVB_TDA8261 is not set
# CONFIG_DVB_TDA826X is not set
# CONFIG_DVB_TS2020 is not set
# CONFIG_DVB_TUA6100 is not set
# CONFIG_DVB_TUNER_CX24113 is not set
# CONFIG_DVB_TUNER_ITD1000 is not set
# CONFIG_DVB_VES1X93 is not set
# CONFIG_DVB_ZL10036 is not set
# CONFIG_DVB_ZL10039 is not set

#
# DVB-T (terrestrial) frontends
#
CONFIG_DVB_AF9013=y
CONFIG_DVB_AS102_FE=y
# CONFIG_DVB_CX22700 is not set
# CONFIG_DVB_CX22702 is not set
# CONFIG_DVB_CXD2820R is not set
# CONFIG_DVB_CXD2841ER is not set
CONFIG_DVB_DIB3000MB=y
CONFIG_DVB_DIB3000MC=y
# CONFIG_DVB_DIB7000M is not set
# CONFIG_DVB_DIB7000P is not set
# CONFIG_DVB_DIB9000 is not set
# CONFIG_DVB_DRXD is not set
CONFIG_DVB_EC100=y
CONFIG_DVB_GP8PSK_FE=y
# CONFIG_DVB_L64781 is not set
# CONFIG_DVB_MT352 is not set
# CONFIG_DVB_NXT6000 is not set
CONFIG_DVB_RTL2830=y
CONFIG_DVB_RTL2832=y
CONFIG_DVB_RTL2832_SDR=y
# CONFIG_DVB_S5H1432 is not set
# CONFIG_DVB_SI2168 is not set
# CONFIG_DVB_SP887X is not set
# CONFIG_DVB_STV0367 is not set
# CONFIG_DVB_TDA10048 is not set
# CONFIG_DVB_TDA1004X is not set
# CONFIG_DVB_ZD1301_DEMOD is not set
CONFIG_DVB_ZL10353=y
# CONFIG_DVB_CXD2880 is not set

#
# DVB-C (cable) frontends
#
# CONFIG_DVB_STV0297 is not set
# CONFIG_DVB_TDA10021 is not set
# CONFIG_DVB_TDA10023 is not set
# CONFIG_DVB_VES1820 is not set

#
# ATSC (North American/Korean Terrestrial/Cable DTV) frontends
#
# CONFIG_DVB_AU8522_DTV is not set
# CONFIG_DVB_AU8522_V4L is not set
# CONFIG_DVB_BCM3510 is not set
# CONFIG_DVB_LG2160 is not set
# CONFIG_DVB_LGDT3305 is not set
# CONFIG_DVB_LGDT3306A is not set
# CONFIG_DVB_LGDT330X is not set
# CONFIG_DVB_MXL692 is not set
# CONFIG_DVB_NXT200X is not set
# CONFIG_DVB_OR51132 is not set
# CONFIG_DVB_OR51211 is not set
# CONFIG_DVB_S5H1409 is not set
# CONFIG_DVB_S5H1411 is not set

#
# ISDB-T (terrestrial) frontends
#
# CONFIG_DVB_DIB8000 is not set
# CONFIG_DVB_MB86A20S is not set
# CONFIG_DVB_S921 is not set

#
# ISDB-S (satellite) & ISDB-T (terrestrial) frontends
#
# CONFIG_DVB_MN88443X is not set
# CONFIG_DVB_TC90522 is not set

#
# Digital terrestrial only tuners/PLL
#
# CONFIG_DVB_PLL is not set
# CONFIG_DVB_TUNER_DIB0070 is not set
# CONFIG_DVB_TUNER_DIB0090 is not set

#
# SEC control devices for DVB-S
#
# CONFIG_DVB_A8293 is not set
CONFIG_DVB_AF9033=y
# CONFIG_DVB_ASCOT2E is not set
# CONFIG_DVB_ATBM8830 is not set
# CONFIG_DVB_HELENE is not set
# CONFIG_DVB_HORUS3A is not set
# CONFIG_DVB_ISL6405 is not set
# CONFIG_DVB_ISL6421 is not set
# CONFIG_DVB_ISL6423 is not set
# CONFIG_DVB_IX2505V is not set
# CONFIG_DVB_LGS8GL5 is not set
# CONFIG_DVB_LGS8GXX is not set
# CONFIG_DVB_LNBH25 is not set
# CONFIG_DVB_LNBH29 is not set
# CONFIG_DVB_LNBP21 is not set
# CONFIG_DVB_LNBP22 is not set
# CONFIG_DVB_M88RS2000 is not set
# CONFIG_DVB_TDA665x is not set
# CONFIG_DVB_DRX39XYJ is not set

#
# Common Interface (EN50221) controller drivers
#
# CONFIG_DVB_CXD2099 is not set
# CONFIG_DVB_SP2 is not set
# end of Customise DVB Frontends

#
# Tools to develop new frontends
#
# CONFIG_DVB_DUMMY_FE is not set
# end of Media ancillary drivers

#
# Graphics support
#
CONFIG_APERTURE_HELPERS=y
CONFIG_SCREEN_INFO=y
CONFIG_VIDEO=y
# CONFIG_AUXDISPLAY is not set
# CONFIG_PANEL is not set
CONFIG_AGP=y
CONFIG_AGP_AMD64=y
CONFIG_AGP_INTEL=y
# CONFIG_AGP_SIS is not set
# CONFIG_AGP_VIA is not set
CONFIG_INTEL_GTT=y
# CONFIG_VGA_SWITCHEROO is not set
CONFIG_GPU_BUDDY=y
CONFIG_DRM=y

#
# DRM debugging options
#
# CONFIG_DRM_WERROR is not set
CONFIG_DRM_DEBUG_MM=y
# end of DRM debugging options

CONFIG_DRM_MIPI_DSI=y
CONFIG_DRM_KMS_HELPER=y
# CONFIG_DRM_PANIC is not set
# CONFIG_DRM_RAS is not set
# CONFIG_DRM_DEBUG_DP_MST_TOPOLOGY_REFS is not set
# CONFIG_DRM_DEBUG_MODESET_LOCK is not set
CONFIG_DRM_CLIENT=y
CONFIG_DRM_CLIENT_LIB=y
CONFIG_DRM_CLIENT_SELECTION=y
CONFIG_DRM_CLIENT_SETUP=y

#
# Supported DRM clients
#
CONFIG_DRM_FBDEV_EMULATION=y
CONFIG_DRM_FBDEV_OVERALLOC=100
# CONFIG_DRM_FBDEV_LEAK_PHYS_SMEM is not set
# CONFIG_DRM_CLIENT_LOG is not set
CONFIG_DRM_CLIENT_DEFAULT_FBDEV=y
CONFIG_DRM_CLIENT_DEFAULT="fbdev"
# end of Supported DRM clients

# CONFIG_DRM_LOAD_EDID_FIRMWARE is not set
CONFIG_DRM_DISPLAY_DP_AUX_BUS=y
CONFIG_DRM_DISPLAY_HELPER=y
# CONFIG_DRM_DISPLAY_DP_AUX_CEC is not set
# CONFIG_DRM_DISPLAY_DP_AUX_CHARDEV is not set
CONFIG_DRM_DISPLAY_DP_HELPER=y
CONFIG_DRM_DISPLAY_DSC_HELPER=y
CONFIG_DRM_DISPLAY_HDCP_HELPER=y
CONFIG_DRM_DISPLAY_HDMI_HELPER=y
CONFIG_DRM_TTM=y
CONFIG_DRM_BUDDY=y
CONFIG_DRM_TTM_HELPER=y
CONFIG_DRM_GEM_SHMEM_HELPER=y
# CONFIG_DRM_AMDGPU is not set

#
# ARM devices
#
# CONFIG_DRM_KOMEDA is not set
# end of ARM devices

# CONFIG_DRM_AST is not set
CONFIG_DRM_BRIDGE=y
CONFIG_DRM_PANEL_BRIDGE=y
CONFIG_DRM_AUX_BRIDGE=y
CONFIG_DRM_AUX_HPD_BRIDGE=y

#
# Display Interface Bridges
#
# CONFIG_DRM_CHIPONE_ICN6211 is not set
# CONFIG_DRM_CHRONTEL_CH7033 is not set
# CONFIG_DRM_DISPLAY_CONNECTOR is not set
# CONFIG_DRM_I2C_NXP_TDA998X is not set
# CONFIG_DRM_ITE_IT6263 is not set
# CONFIG_DRM_ITE_IT6505 is not set
# CONFIG_DRM_LONTIUM_LT8912B is not set
# CONFIG_DRM_LONTIUM_LT9211 is not set
# CONFIG_DRM_LONTIUM_LT9611 is not set
# CONFIG_DRM_LONTIUM_LT9611UXC is not set
# CONFIG_DRM_LONTIUM_LT8713SX is not set
# CONFIG_DRM_ITE_IT66121 is not set
# CONFIG_DRM_LVDS_CODEC is not set
# CONFIG_DRM_MEGACHIPS_STDPXXXX_GE_B850V3_FW is not set
# CONFIG_DRM_NWL_MIPI_DSI is not set
# CONFIG_DRM_NXP_PTN3460 is not set
# CONFIG_DRM_PARADE_PS8622 is not set
# CONFIG_DRM_PARADE_PS8640 is not set
# CONFIG_DRM_SAMSUNG_DSIM is not set
# CONFIG_DRM_SIL_SII8620 is not set
# CONFIG_DRM_SII902X is not set
# CONFIG_DRM_SII9234 is not set
# CONFIG_DRM_SIMPLE_BRIDGE is not set
# CONFIG_DRM_SOLOMON_SSD2825 is not set
# CONFIG_DRM_THINE_THC63LVD1024 is not set
# CONFIG_DRM_TOSHIBA_TC358762 is not set
# CONFIG_DRM_TOSHIBA_TC358764 is not set
# CONFIG_DRM_TOSHIBA_TC358767 is not set
# CONFIG_DRM_TOSHIBA_TC358768 is not set
# CONFIG_DRM_TOSHIBA_TC358775 is not set
# CONFIG_DRM_TI_DLPC3433 is not set
# CONFIG_DRM_TI_TDP158 is not set
# CONFIG_DRM_TI_TFP410 is not set
# CONFIG_DRM_TI_SN65DSI83 is not set
# CONFIG_DRM_TI_SN65DSI86 is not set
# CONFIG_DRM_TI_TPD12S015 is not set
# CONFIG_DRM_WAVESHARE_BRIDGE is not set
# CONFIG_DRM_ANALOGIX_ANX6345 is not set
# CONFIG_DRM_ANALOGIX_ANX78XX is not set
# CONFIG_DRM_ANALOGIX_ANX7625 is not set
# CONFIG_DRM_I2C_ADV7511 is not set
# CONFIG_DRM_CDNS_DSI is not set
# CONFIG_DRM_CDNS_MHDP8546 is not set
# end of Display Interface Bridges

# CONFIG_DRM_ETNAVIV is not set
# CONFIG_DRM_GMA500 is not set
CONFIG_DRM_GUD=y
# CONFIG_DRM_HISI_HIBMC is not set
CONFIG_DRM_I915=y
CONFIG_DRM_I915_FORCE_PROBE=""
CONFIG_DRM_I915_CAPTURE_ERROR=y
CONFIG_DRM_I915_COMPRESS_ERROR=y
CONFIG_DRM_I915_USERPTR=y
# CONFIG_DRM_I915_GVT_KVMGT is not set
# CONFIG_DRM_I915_DP_TUNNEL is not set

#
# drm/i915 Debugging
#
# CONFIG_DRM_I915_WERROR is not set
# CONFIG_DRM_I915_REPLAY_GPU_HANGS_API is not set
# CONFIG_DRM_I915_DEBUG is not set
# CONFIG_DRM_I915_DEBUG_MMIO is not set
# CONFIG_DRM_I915_SW_FENCE_DEBUG_OBJECTS is not set
# CONFIG_DRM_I915_SW_FENCE_CHECK_DAG is not set
# CONFIG_DRM_I915_DEBUG_GUC is not set
# CONFIG_DRM_I915_SELFTEST is not set
# CONFIG_DRM_I915_LOW_LEVEL_TRACEPOINTS is not set
# CONFIG_DRM_I915_DEBUG_VBLANK_EVADE is not set
# CONFIG_DRM_I915_DEBUG_RUNTIME_PM is not set
# CONFIG_DRM_I915_DEBUG_WAKEREF is not set
# end of drm/i915 Debugging

#
# drm/i915 Profile Guided Optimisation
#
CONFIG_DRM_I915_REQUEST_TIMEOUT=20000
CONFIG_DRM_I915_FENCE_TIMEOUT=10000
CONFIG_DRM_I915_USERFAULT_AUTOSUSPEND=250
CONFIG_DRM_I915_HEARTBEAT_INTERVAL=2500
CONFIG_DRM_I915_PREEMPT_TIMEOUT=640
CONFIG_DRM_I915_PREEMPT_TIMEOUT_COMPUTE=7500
CONFIG_DRM_I915_MAX_REQUEST_BUSYWAIT=8000
CONFIG_DRM_I915_STOP_TIMEOUT=100
CONFIG_DRM_I915_TIMESLICE_DURATION=1
# end of drm/i915 Profile Guided Optimisation

# CONFIG_DRM_LOGICVC is not set
# CONFIG_DRM_MGAG200 is not set
# CONFIG_DRM_NOUVEAU is not set
CONFIG_DRM_PANEL=y

#
# Display Panels
#
# CONFIG_DRM_PANEL_ABT_Y030XX067A is not set
# CONFIG_DRM_PANEL_ARM_VERSATILE is not set
# CONFIG_DRM_PANEL_ASUS_Z00T_TM5P5_NT35596 is not set
# CONFIG_DRM_PANEL_AUO_A030JTN01 is not set
# CONFIG_DRM_PANEL_BOE_BF060Y8M_AJ0 is not set
# CONFIG_DRM_PANEL_BOE_HIMAX8279D is not set
# CONFIG_DRM_PANEL_BOE_TD4320 is not set
# CONFIG_DRM_PANEL_BOE_TH101MB31UIG002_28A is not set
# CONFIG_DRM_PANEL_BOE_TV101WUM_NL6 is not set
# CONFIG_DRM_PANEL_BOE_TV101WUM_LL2 is not set
# CONFIG_DRM_PANEL_CHIPWEALTH_CH13726A is not set
# CONFIG_DRM_PANEL_EBBG_FT8719 is not set
# CONFIG_DRM_PANEL_ELIDA_KD35T133 is not set
# CONFIG_DRM_PANEL_FEIXIN_K101_IM2BA02 is not set
# CONFIG_DRM_PANEL_FEIYANG_FY07024DI26A30D is not set
# CONFIG_DRM_PANEL_FOCALTECH_OTA7290B is not set
# CONFIG_DRM_PANEL_DSI_CM is not set
# CONFIG_DRM_PANEL_LVDS is not set
# CONFIG_DRM_PANEL_HIMAX_HX8279 is not set
# CONFIG_DRM_PANEL_HIMAX_HX83102 is not set
# CONFIG_DRM_PANEL_HIMAX_HX83112A is not set
# CONFIG_DRM_PANEL_HIMAX_HX83112B is not set
# CONFIG_DRM_PANEL_HIMAX_HX83121A is not set
# CONFIG_DRM_PANEL_HIMAX_HX8394 is not set
# CONFIG_DRM_PANEL_HYDIS_HV101HD1 is not set
# CONFIG_DRM_PANEL_ILITEK_IL9322 is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9341 is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9805 is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9806E_DSI is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9806E_SPI is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9881C is not set
# CONFIG_DRM_PANEL_ILITEK_ILI9882T is not set
# CONFIG_DRM_PANEL_INNOLUX_EJ030NA is not set
# CONFIG_DRM_PANEL_INNOLUX_P079ZCA is not set
# CONFIG_DRM_PANEL_JADARD_JD9365DA_H3 is not set
# CONFIG_DRM_PANEL_JDI_LPM102A188A is not set
# CONFIG_DRM_PANEL_JDI_LT070ME05000 is not set
# CONFIG_DRM_PANEL_JDI_R63452 is not set
# CONFIG_DRM_PANEL_KHADAS_TS050 is not set
# CONFIG_DRM_PANEL_KINGDISPLAY_KD097D04 is not set
# CONFIG_DRM_PANEL_LEADTEK_LTK050H3146W is not set
# CONFIG_DRM_PANEL_LEADTEK_LTK500HD1829 is not set
# CONFIG_DRM_PANEL_LINCOLNTECH_LCD197 is not set
# CONFIG_DRM_PANEL_LG_LB035Q02 is not set
# CONFIG_DRM_PANEL_LG_LD070WX3 is not set
# CONFIG_DRM_PANEL_LG_LG4573 is not set
# CONFIG_DRM_PANEL_LG_SW43408 is not set
# CONFIG_DRM_PANEL_LXD_M9189A is not set
# CONFIG_DRM_PANEL_MAGNACHIP_D53E6EA8966 is not set
# CONFIG_DRM_PANEL_MANTIX_MLAF057WE51 is not set
# CONFIG_DRM_PANEL_MOTOROLA_MOT is not set
# CONFIG_DRM_PANEL_NEC_NL8048HL11 is not set
# CONFIG_DRM_PANEL_NEWVISION_NV3051D is not set
# CONFIG_DRM_PANEL_NEWVISION_NV3052C is not set
# CONFIG_DRM_PANEL_NOVATEK_NT35510 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT35532 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT35560 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT35950 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT36523 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT36672A is not set
# CONFIG_DRM_PANEL_NOVATEK_NT36672E is not set
# CONFIG_DRM_PANEL_NOVATEK_NT37700F is not set
# CONFIG_DRM_PANEL_NOVATEK_NT37801 is not set
# CONFIG_DRM_PANEL_NOVATEK_NT39016 is not set
# CONFIG_DRM_PANEL_OLIMEX_LCD_OLINUXINO is not set
# CONFIG_DRM_PANEL_ORISETECH_OTA5601A is not set
# CONFIG_DRM_PANEL_ORISETECH_OTM8009A is not set
# CONFIG_DRM_PANEL_OSD_OSD101T2587_53TS is not set
# CONFIG_DRM_PANEL_PANASONIC_VVX10F034N00 is not set
# CONFIG_DRM_PANEL_RASPBERRYPI_TOUCHSCREEN is not set
# CONFIG_DRM_PANEL_RAYDIUM_RM67191 is not set
# CONFIG_DRM_PANEL_RAYDIUM_RM67200 is not set
# CONFIG_DRM_PANEL_RAYDIUM_RM68200 is not set
# CONFIG_DRM_PANEL_RAYDIUM_RM692E5 is not set
# CONFIG_DRM_PANEL_RAYDIUM_RM69380 is not set
# CONFIG_DRM_PANEL_RENESAS_R61307 is not set
# CONFIG_DRM_PANEL_RENESAS_R69328 is not set
# CONFIG_DRM_PANEL_RONBO_RB070D30 is not set
# CONFIG_DRM_PANEL_SAMSUNG_AMS581VF01 is not set
# CONFIG_DRM_PANEL_SAMSUNG_AMS639RQ08 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E88A0_AMS427AP24 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E88A0_AMS452EF01 is not set
# CONFIG_DRM_PANEL_SAMSUNG_ATNA33XC20 is not set
# CONFIG_DRM_PANEL_SAMSUNG_DB7430 is not set
# CONFIG_DRM_PANEL_SAMSUNG_LD9040 is not set
# CONFIG_DRM_PANEL_SAMSUNG_LTL106HL02 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E3FA7 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6D16D0 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6D27A1 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6D7AA0 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E3FC2X01 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E3HA2 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E3HA8 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E63J0X03 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E63M0 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E8AA0 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E8AA5X01_AMS561RA01 is not set
# CONFIG_DRM_PANEL_SAMSUNG_S6E8FC0 is not set
# CONFIG_DRM_PANEL_SAMSUNG_SOFEF00 is not set
# CONFIG_DRM_PANEL_SEIKO_43WVF1G is not set
# CONFIG_DRM_PANEL_SHARP_LQ079L1SX01 is not set
# CONFIG_DRM_PANEL_SHARP_LQ101R1SX01 is not set
# CONFIG_DRM_PANEL_SHARP_LS037V7DW01 is not set
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SHARP_LS060T1SX01 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
# CONFIG_DRM_PANEL_SONY_TD4353_JDI is not set
# CONFIG_DRM_PANEL_SONY_TULIP_TRULY_NT35521 is not set
# CONFIG_DRM_PANEL_STARTEK_KD070FHFID015 is not set
CONFIG_DRM_PANEL_EDP=y
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SUMMIT is not set
# CONFIG_DRM_PANEL_SYNAPTICS_R63353 is not set
# CONFIG_DRM_PANEL_SYNAPTICS_TDDI is not set
# CONFIG_DRM_PANEL_TDO_TL070WSH30 is not set
# CONFIG_DRM_PANEL_TPO_TD028TTEC1 is not set
# CONFIG_DRM_PANEL_TPO_TD043MTEA1 is not set
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
# CONFIG_DRM_PANEL_VISIONOX_G2647FB105 is not set
# CONFIG_DRM_PANEL_VISIONOX_R66451 is not set
# CONFIG_DRM_PANEL_VISIONOX_RM69299 is not set
# CONFIG_DRM_PANEL_VISIONOX_RM692E5 is not set
# CONFIG_DRM_PANEL_VISIONOX_VTDR6130 is not set
# CONFIG_DRM_PANEL_WIDECHIPS_WS2401 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
# end of Display Panels

# CONFIG_DRM_QXL is not set
# CONFIG_DRM_RADEON is not set
# CONFIG_DRM_ST7571 is not set
# CONFIG_DRM_ST7586 is not set
# CONFIG_DRM_ST7735R is not set
# CONFIG_DRM_ST7920 is not set
# CONFIG_DRM_SSD130X is not set

#
# Drivers for system framebuffers
#
CONFIG_DRM_SYSFB_HELPER=y
CONFIG_DRM_SIMPLEDRM=y
# CONFIG_DRM_VESADRM is not set
# end of Drivers for system framebuffers

# CONFIG_DRM_APPLETBDRM is not set
# CONFIG_DRM_ARCPGU is not set
CONFIG_DRM_BOCHS=y
CONFIG_DRM_CIRRUS_QEMU=y
CONFIG_DRM_GM12U320=y
# CONFIG_DRM_PANEL_MIPI_DBI is not set
# CONFIG_DRM_PIXPAPER is not set
# CONFIG_TINYDRM_HX8357D is not set
# CONFIG_TINYDRM_ILI9163 is not set
# CONFIG_TINYDRM_ILI9225 is not set
# CONFIG_TINYDRM_ILI9341 is not set
# CONFIG_TINYDRM_ILI9486 is not set
# CONFIG_TINYDRM_MI0283QT is not set
# CONFIG_TINYDRM_REPAPER is not set
# CONFIG_TINYDRM_SHARP_MEMORY is not set
CONFIG_DRM_UDL=y
# CONFIG_DRM_VBOXVIDEO is not set
CONFIG_DRM_VGEM=y
CONFIG_DRM_VIRTIO_GPU=y
CONFIG_DRM_VIRTIO_GPU_KMS=y
CONFIG_DRM_VKMS=y
CONFIG_DRM_VMWGFX=y
# CONFIG_DRM_VMWGFX_MKSSTATS is not set
# CONFIG_DRM_XE is not set
CONFIG_DRM_PANEL_ORIENTATION_QUIRKS=y

#
# Frame buffer Devices
#
CONFIG_FB=y
# CONFIG_FB_CIRRUS is not set
# CONFIG_FB_PM2 is not set
# CONFIG_FB_CYBER2000 is not set
# CONFIG_FB_ARC is not set
# CONFIG_FB_ASILIANT is not set
# CONFIG_FB_IMSTT is not set
CONFIG_FB_VGA16=y
# CONFIG_FB_UVESA is not set
CONFIG_FB_VESA=y
# CONFIG_FB_N411 is not set
# CONFIG_FB_OPENCORES is not set
# CONFIG_FB_S1D13XXX is not set
# CONFIG_FB_NVIDIA is not set
# CONFIG_FB_RIVA is not set
# CONFIG_FB_I740 is not set
# CONFIG_FB_MATROX is not set
# CONFIG_FB_RADEON is not set
# CONFIG_FB_ATY128 is not set
# CONFIG_FB_ATY is not set
# CONFIG_FB_S3 is not set
# CONFIG_FB_SAVAGE is not set
# CONFIG_FB_SIS is not set
# CONFIG_FB_VIA is not set
# CONFIG_FB_NEOMAGIC is not set
# CONFIG_FB_KYRO is not set
# CONFIG_FB_3DFX is not set
# CONFIG_FB_VOODOO1 is not set
# CONFIG_FB_VT8623 is not set
# CONFIG_FB_TRIDENT is not set
# CONFIG_FB_ARK is not set
# CONFIG_FB_PM3 is not set
# CONFIG_FB_CARMINE is not set
# CONFIG_FB_SMSCUFX is not set
# CONFIG_FB_UDL is not set
# CONFIG_FB_IBM_GXT4500 is not set
CONFIG_FB_VIRTUAL=y
# CONFIG_FB_METRONOME is not set
# CONFIG_FB_MB862XX is not set
# CONFIG_FB_SSD1307 is not set
# CONFIG_FB_SM712 is not set
CONFIG_FB_CORE=y
CONFIG_FB_NOTIFY=y
CONFIG_FB_DEVICE=y
CONFIG_FB_CFB_FILLRECT=y
CONFIG_FB_CFB_COPYAREA=y
CONFIG_FB_CFB_IMAGEBLIT=y
CONFIG_FB_SYS_FILLRECT=y
CONFIG_FB_SYS_COPYAREA=y
CONFIG_FB_SYS_IMAGEBLIT=y
# CONFIG_FB_FOREIGN_ENDIAN is not set
CONFIG_FB_SYSMEM_FOPS=y
CONFIG_FB_DEFERRED_IO=y
CONFIG_FB_IOMEM_FOPS=y
CONFIG_FB_IOMEM_HELPERS=y
CONFIG_FB_SYSMEM_HELPERS=y
CONFIG_FB_SYSMEM_HELPERS_DEFERRED=y
CONFIG_FB_TILEBLITTING=y
# end of Frame buffer Devices

#
# Backlight & LCD device support
#
CONFIG_LCD_CLASS_DEVICE=y
# CONFIG_LCD_L4F00242T03 is not set
# CONFIG_LCD_LMS283GF05 is not set
# CONFIG_LCD_LTV350QV is not set
# CONFIG_LCD_ILI922X is not set
# CONFIG_LCD_ILI9320 is not set
# CONFIG_LCD_TDO24M is not set
# CONFIG_LCD_VGG2432A4 is not set
# CONFIG_LCD_PLATFORM is not set
# CONFIG_LCD_AMS369FG06 is not set
# CONFIG_LCD_LMS501KF03 is not set
# CONFIG_LCD_HX8357 is not set
# CONFIG_LCD_OTM3225A is not set
CONFIG_BACKLIGHT_CLASS_DEVICE=y
# CONFIG_BACKLIGHT_AW99706 is not set
# CONFIG_BACKLIGHT_KTD253 is not set
# CONFIG_BACKLIGHT_KTD2801 is not set
# CONFIG_BACKLIGHT_KTZ8866 is not set
# CONFIG_BACKLIGHT_MAX25014 is not set
# CONFIG_BACKLIGHT_MT6370 is not set
# CONFIG_BACKLIGHT_APPLE is not set
# CONFIG_BACKLIGHT_QCOM_WLED is not set
# CONFIG_BACKLIGHT_SAHARA is not set
# CONFIG_BACKLIGHT_ADP8860 is not set
# CONFIG_BACKLIGHT_ADP8870 is not set
# CONFIG_BACKLIGHT_LM3509 is not set
# CONFIG_BACKLIGHT_LM3639 is not set
# CONFIG_BACKLIGHT_PANDORA is not set
# CONFIG_BACKLIGHT_GPIO is not set
# CONFIG_BACKLIGHT_LV5207LP is not set
# CONFIG_BACKLIGHT_BD6107 is not set
# CONFIG_BACKLIGHT_ARCXCNN is not set
# CONFIG_BACKLIGHT_LED is not set
# end of Backlight & LCD device support

CONFIG_VGASTATE=y
CONFIG_VIDEOMODE_HELPERS=y
CONFIG_HDMI=y
# CONFIG_FIRMWARE_EDID is not set

#
# Console display driver support
#
CONFIG_VGA_CONSOLE=y
CONFIG_DUMMY_CONSOLE=y
CONFIG_DUMMY_CONSOLE_COLUMNS=80
CONFIG_DUMMY_CONSOLE_ROWS=25
CONFIG_FRAMEBUFFER_CONSOLE=y
# CONFIG_FRAMEBUFFER_CONSOLE_LEGACY_ACCELERATION is not set
CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y
# CONFIG_FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER is not set
# end of Console display driver support

CONFIG_LOGO=y
CONFIG_LOGO_LINUX_MONO=y
CONFIG_LOGO_LINUX_MONO_FILE="drivers/video/logo/logo_linux_mono.pbm"
CONFIG_LOGO_LINUX_VGA16=y
CONFIG_LOGO_LINUX_VGA16_FILE="drivers/video/logo/logo_linux_vga16.ppm"
# CONFIG_LOGO_LINUX_CLUT224 is not set
# CONFIG_TRACE_GPU_MEM is not set
# end of Graphics support

# CONFIG_DRM_ACCEL is not set
CONFIG_SOUND=y
CONFIG_SOUND_OSS_CORE=y
CONFIG_SOUND_OSS_CORE_PRECLAIM=y
CONFIG_SND=y
CONFIG_SND_TIMER=y
CONFIG_SND_PCM=y
CONFIG_SND_HWDEP=y
CONFIG_SND_SEQ_DEVICE=y
CONFIG_SND_RAWMIDI=y
CONFIG_SND_UMP=y
CONFIG_SND_UMP_LEGACY_RAWMIDI=y
CONFIG_SND_JACK=y
CONFIG_SND_JACK_INPUT_DEV=y
CONFIG_SND_OSSEMUL=y
CONFIG_SND_MIXER_OSS=y
CONFIG_SND_PCM_OSS=y
CONFIG_SND_PCM_OSS_PLUGINS=y
CONFIG_SND_PCM_TIMER=y
CONFIG_SND_HRTIMER=y
# CONFIG_SND_DYNAMIC_MINORS is not set
# CONFIG_SND_SUPPORT_OLD_API is not set
CONFIG_SND_PROC_FS=y
CONFIG_SND_VERBOSE_PROCFS=y
CONFIG_SND_CTL_FAST_LOOKUP=y
CONFIG_SND_DEBUG=y
# CONFIG_SND_DEBUG_VERBOSE is not set
CONFIG_SND_PCM_XRUN_DEBUG=y
# CONFIG_SND_CTL_INPUT_VALIDATION is not set
# CONFIG_SND_CTL_DEBUG is not set
# CONFIG_SND_JACK_INJECTION_DEBUG is not set
# CONFIG_SND_UTIMER is not set
CONFIG_SND_VMASTER=y
CONFIG_SND_DMA_SGBUF=y
CONFIG_SND_CTL_LED=y
CONFIG_SND_SEQUENCER=y
CONFIG_SND_SEQ_DUMMY=y
CONFIG_SND_SEQUENCER_OSS=y
CONFIG_SND_SEQ_HRTIMER_DEFAULT=y
CONFIG_SND_SEQ_MIDI_EVENT=y
CONFIG_SND_SEQ_MIDI=y
CONFIG_SND_SEQ_VIRMIDI=y
# CONFIG_SND_SEQ_UMP is not set
CONFIG_SND_DRIVERS=y
# CONFIG_SND_PCSP is not set
CONFIG_SND_DUMMY=y
CONFIG_SND_ALOOP=y
# CONFIG_SND_PCMTEST is not set
CONFIG_SND_VIRMIDI=y
# CONFIG_SND_MTPAV is not set
# CONFIG_SND_MTS64 is not set
# CONFIG_SND_SERIAL_U16550 is not set
# CONFIG_SND_SERIAL_GENERIC is not set
# CONFIG_SND_MPU401 is not set
# CONFIG_SND_PORTMAN2X4 is not set
CONFIG_SND_PCI=y
# CONFIG_SND_AD1889 is not set
# CONFIG_SND_ALS300 is not set
# CONFIG_SND_ALS4000 is not set
# CONFIG_SND_ALI5451 is not set
# CONFIG_SND_ASIHPI is not set
# CONFIG_SND_ATIIXP is not set
# CONFIG_SND_ATIIXP_MODEM is not set
# CONFIG_SND_AU8810 is not set
# CONFIG_SND_AU8820 is not set
# CONFIG_SND_AU8830 is not set
# CONFIG_SND_AW2 is not set
# CONFIG_SND_AZT3328 is not set
# CONFIG_SND_BT87X is not set
# CONFIG_SND_CA0106 is not set
# CONFIG_SND_CMIPCI is not set
# CONFIG_SND_OXYGEN is not set
# CONFIG_SND_CS4281 is not set
# CONFIG_SND_CS46XX is not set
# CONFIG_SND_CTXFI is not set
# CONFIG_SND_DARLA20 is not set
# CONFIG_SND_GINA20 is not set
# CONFIG_SND_LAYLA20 is not set
# CONFIG_SND_DARLA24 is not set
# CONFIG_SND_GINA24 is not set
# CONFIG_SND_LAYLA24 is not set
# CONFIG_SND_MONA is not set
# CONFIG_SND_MIA is not set
# CONFIG_SND_ECHO3G is not set
# CONFIG_SND_INDIGO is not set
# CONFIG_SND_INDIGOIO is not set
# CONFIG_SND_INDIGODJ is not set
# CONFIG_SND_INDIGOIOX is not set
# CONFIG_SND_INDIGODJX is not set
# CONFIG_SND_EMU10K1 is not set
# CONFIG_SND_EMU10K1X is not set
# CONFIG_SND_ENS1370 is not set
# CONFIG_SND_ENS1371 is not set
# CONFIG_SND_ES1938 is not set
# CONFIG_SND_ES1968 is not set
# CONFIG_SND_FM801 is not set
# CONFIG_SND_HDSP is not set
# CONFIG_SND_HDSPM is not set
# CONFIG_SND_ICE1712 is not set
# CONFIG_SND_ICE1724 is not set
# CONFIG_SND_INTEL8X0 is not set
# CONFIG_SND_INTEL8X0M is not set
# CONFIG_SND_KORG1212 is not set
# CONFIG_SND_LOLA is not set
# CONFIG_SND_LX6464ES is not set
# CONFIG_SND_MAESTRO3 is not set
# CONFIG_SND_MIXART is not set
# CONFIG_SND_NM256 is not set
# CONFIG_SND_PCXHR is not set
# CONFIG_SND_RIPTIDE is not set
# CONFIG_SND_RME32 is not set
# CONFIG_SND_RME96 is not set
# CONFIG_SND_RME9652 is not set
# CONFIG_SND_SE6X is not set
# CONFIG_SND_SONICVIBES is not set
# CONFIG_SND_TRIDENT is not set
# CONFIG_SND_VIA82XX is not set
# CONFIG_SND_VIA82XX_MODEM is not set
# CONFIG_SND_VIRTUOSO is not set
# CONFIG_SND_VX222 is not set
# CONFIG_SND_YMFPCI is not set

#
# HD-Audio
#
CONFIG_SND_HDA=y
CONFIG_SND_HDA_HWDEP=y
CONFIG_SND_HDA_RECONFIG=y
CONFIG_SND_HDA_INPUT_BEEP=y
CONFIG_SND_HDA_INPUT_BEEP_MODE=1
CONFIG_SND_HDA_PATCH_LOADER=y
CONFIG_SND_HDA_POWER_SAVE_DEFAULT=0
# CONFIG_SND_HDA_CTL_DEV_ID is not set
CONFIG_SND_HDA_PREALLOC_SIZE=0
CONFIG_SND_HDA_INTEL=y
# CONFIG_SND_HDA_ACPI is not set
CONFIG_SND_HDA_GENERIC_LEDS=y
CONFIG_SND_HDA_CODEC_ANALOG=y
CONFIG_SND_HDA_CODEC_SIGMATEL=y
CONFIG_SND_HDA_CODEC_VIA=y
CONFIG_SND_HDA_CODEC_CONEXANT=y
# CONFIG_SND_HDA_CODEC_SENARYTECH is not set
CONFIG_SND_HDA_CODEC_CA0110=y
CONFIG_SND_HDA_CODEC_CA0132=y
# CONFIG_SND_HDA_CODEC_CA0132_DSP is not set
CONFIG_SND_HDA_CODEC_CMEDIA=y
# CONFIG_SND_HDA_CODEC_CM9825 is not set
CONFIG_SND_HDA_CODEC_SI3054=y
CONFIG_SND_HDA_GENERIC=y
CONFIG_SND_HDA_CODEC_REALTEK=y
# CONFIG_SND_HDA_CODEC_ALC260 is not set
# CONFIG_SND_HDA_CODEC_ALC262 is not set
# CONFIG_SND_HDA_CODEC_ALC268 is not set
# CONFIG_SND_HDA_CODEC_ALC269 is not set
# CONFIG_SND_HDA_CODEC_ALC662 is not set
# CONFIG_SND_HDA_CODEC_ALC680 is not set
# CONFIG_SND_HDA_CODEC_ALC861 is not set
# CONFIG_SND_HDA_CODEC_ALC861VD is not set
# CONFIG_SND_HDA_CODEC_ALC880 is not set
# CONFIG_SND_HDA_CODEC_ALC882 is not set
CONFIG_SND_HDA_CODEC_CIRRUS=y
# CONFIG_SND_HDA_CODEC_CS420X is not set
# CONFIG_SND_HDA_CODEC_CS421X is not set
# CONFIG_SND_HDA_CODEC_CS8409 is not set
CONFIG_SND_HDA_CODEC_HDMI=y
# CONFIG_SND_HDA_CODEC_HDMI_GENERIC is not set
# CONFIG_SND_HDA_CODEC_HDMI_SIMPLE is not set
# CONFIG_SND_HDA_CODEC_HDMI_INTEL is not set
# CONFIG_SND_HDA_CODEC_HDMI_ATI is not set
# CONFIG_SND_HDA_CODEC_HDMI_NVIDIA is not set
# CONFIG_SND_HDA_CODEC_HDMI_NVIDIA_MCP is not set
# CONFIG_SND_HDA_CODEC_HDMI_TEGRA is not set
# CONFIG_SND_HDA_SCODEC_CS35L56_I2C is not set
# CONFIG_SND_HDA_SCODEC_CS35L56_SPI is not set
CONFIG_SND_HDA_CORE=y
CONFIG_SND_HDA_COMPONENT=y
CONFIG_SND_HDA_I915=y
CONFIG_SND_INTEL_NHLT=y
CONFIG_SND_INTEL_DSP_CONFIG=y
CONFIG_SND_INTEL_SOUNDWIRE_ACPI=y
# end of HD-Audio

# CONFIG_SND_SPI is not set
CONFIG_SND_USB=y
CONFIG_SND_USB_AUDIO=y
CONFIG_SND_USB_AUDIO_MIDI_V2=y
CONFIG_SND_USB_AUDIO_USE_MEDIA_CONTROLLER=y
CONFIG_SND_USB_UA101=y
CONFIG_SND_USB_USX2Y=y
CONFIG_SND_USB_CAIAQ=y
CONFIG_SND_USB_CAIAQ_INPUT=y
CONFIG_SND_USB_US122L=y
# CONFIG_SND_USB_US144MKII is not set
CONFIG_SND_USB_6FIRE=y
CONFIG_SND_USB_HIFACE=y
CONFIG_SND_BCD2000=y
CONFIG_SND_USB_LINE6=y
CONFIG_SND_USB_POD=y
CONFIG_SND_USB_PODHD=y
CONFIG_SND_USB_TONEPORT=y
CONFIG_SND_USB_VARIAX=y
# CONFIG_SND_FIREWIRE is not set
CONFIG_SND_PCMCIA=y
# CONFIG_SND_VXPOCKET is not set
# CONFIG_SND_PDAUDIOCF is not set
CONFIG_SND_SOC=y
# CONFIG_SND_SOC_USB is not set

#
# Analog Devices
#
# CONFIG_SND_SOC_ADI_AXI_I2S is not set
# CONFIG_SND_SOC_ADI_AXI_SPDIF is not set
# end of Analog Devices

#
# AMD
#
# CONFIG_SND_SOC_AMD_ACP is not set
# CONFIG_SND_SOC_AMD_ACP3x is not set
# CONFIG_SND_SOC_AMD_RENOIR is not set
# CONFIG_SND_SOC_AMD_ACP5x is not set
# CONFIG_SND_SOC_AMD_ACP6x is not set
# CONFIG_SND_AMD_ACP_CONFIG is not set
# CONFIG_SND_SOC_AMD_ACP_COMMON is not set
# end of AMD

#
# Apple
#
# end of Apple

#
# Atmel
#
# CONFIG_SND_SOC_MIKROE_PROTO is not set
# end of Atmel

#
# Au1x
#
# end of Au1x

#
# Broadcom
#
# CONFIG_SND_BCM63XX_I2S_WHISTLER is not set
# end of Broadcom

#
# Cirrus Logic
#
# end of Cirrus Logic

#
# DesignWare
#
# CONFIG_SND_DESIGNWARE_I2S is not set
# end of DesignWare

#
# Freescale
#

#
# Common SoC Audio options for Freescale CPUs:
#
# CONFIG_SND_SOC_FSL_ASRC is not set
# CONFIG_SND_SOC_FSL_SAI is not set
# CONFIG_SND_SOC_FSL_AUDMIX is not set
# CONFIG_SND_SOC_FSL_SSI is not set
# CONFIG_SND_SOC_FSL_SPDIF is not set
# CONFIG_SND_SOC_FSL_ESAI is not set
# CONFIG_SND_SOC_FSL_MICFIL is not set
# CONFIG_SND_SOC_FSL_XCVR is not set
# CONFIG_SND_SOC_IMX_AUDMUX is not set
# end of Freescale

#
# Google
#
# CONFIG_SND_SOC_CHV3_I2S is not set
# end of Google

#
# Hisilicon
#
# CONFIG_SND_I2S_HI6210_I2S is not set
# end of Hisilicon

#
# JZ4740
#
# end of JZ4740

#
# Kirkwood
#
# end of Kirkwood

#
# Loongson
#
# end of Loongson

#
# Intel
#
# CONFIG_SND_SOC_INTEL_SST_TOPLEVEL is not set
# CONFIG_SND_SOC_INTEL_AVS is not set
# end of Intel

#
# Mediatek
#
# CONFIG_SND_SOC_MTK_BTCVSD is not set
# end of Mediatek

#
# PXA
#
# end of PXA

#
# SoundWire (SDCA)
#
# CONFIG_SND_SOC_SDCA is not set
CONFIG_SND_SOC_SDCA_OPTIONAL=y
# end of SoundWire (SDCA)

#
# ST SPEAr
#
# end of ST SPEAr

#
# Spreadtrum
#
# end of Spreadtrum

#
# STMicroelectronics STM32
#
# end of STMicroelectronics STM32

#
# Tegra
#
# end of Tegra

#
# Xilinx
#
# CONFIG_SND_SOC_XILINX_I2S is not set
# CONFIG_SND_SOC_XILINX_AUDIO_FORMATTER is not set
# CONFIG_SND_SOC_XILINX_SPDIF is not set
# end of Xilinx

#
# Xtensa
#
# CONFIG_SND_SOC_XTFPGA_I2S is not set
# end of Xtensa

# CONFIG_SND_SOC_SOF_TOPLEVEL is not set
CONFIG_SND_SOC_I2C_AND_SPI=y

#
# CODEC drivers
#
# CONFIG_SND_SOC_AC97_CODEC is not set
# CONFIG_SND_SOC_ADAU1372_I2C is not set
# CONFIG_SND_SOC_ADAU1372_SPI is not set
# CONFIG_SND_SOC_ADAU1373 is not set
# CONFIG_SND_SOC_ADAU1701 is not set
# CONFIG_SND_SOC_ADAU1761_I2C is not set
# CONFIG_SND_SOC_ADAU1761_SPI is not set
# CONFIG_SND_SOC_ADAU7002 is not set
# CONFIG_SND_SOC_ADAU7118_HW is not set
# CONFIG_SND_SOC_ADAU7118_I2C is not set
# CONFIG_SND_SOC_AK4104 is not set
# CONFIG_SND_SOC_AK4118 is not set
# CONFIG_SND_SOC_AK4375 is not set
# CONFIG_SND_SOC_AK4458 is not set
# CONFIG_SND_SOC_AK4554 is not set
# CONFIG_SND_SOC_AK4613 is not set
# CONFIG_SND_SOC_AK4619 is not set
# CONFIG_SND_SOC_AK4642 is not set
# CONFIG_SND_SOC_AK5386 is not set
# CONFIG_SND_SOC_AK5558 is not set
# CONFIG_SND_SOC_ALC5623 is not set
# CONFIG_SND_SOC_AUDIO_IIO_AUX is not set
# CONFIG_SND_SOC_AW8738 is not set
# CONFIG_SND_SOC_AW88395 is not set
# CONFIG_SND_SOC_AW88166 is not set
# CONFIG_SND_SOC_AW88261 is not set
# CONFIG_SND_SOC_AW88081 is not set
# CONFIG_SND_SOC_AW87390 is not set
# CONFIG_SND_SOC_AW88399 is not set
# CONFIG_SND_SOC_BD28623 is not set
# CONFIG_SND_SOC_BT_SCO is not set
# CONFIG_SND_SOC_CHV3_CODEC is not set
# CONFIG_SND_SOC_CS35L32 is not set
# CONFIG_SND_SOC_CS35L33 is not set
# CONFIG_SND_SOC_CS35L34 is not set
# CONFIG_SND_SOC_CS35L35 is not set
# CONFIG_SND_SOC_CS35L36 is not set
# CONFIG_SND_SOC_CS35L41_SPI is not set
# CONFIG_SND_SOC_CS35L41_I2C is not set
# CONFIG_SND_SOC_CS35L45_SPI is not set
# CONFIG_SND_SOC_CS35L45_I2C is not set
# CONFIG_SND_SOC_CS35L56_I2C is not set
# CONFIG_SND_SOC_CS35L56_SPI is not set
# CONFIG_SND_SOC_CS35L56_SDW is not set
# CONFIG_SND_SOC_CS42L42 is not set
# CONFIG_SND_SOC_CS42L42_SDW is not set
# CONFIG_SND_SOC_CS42L51_I2C is not set
# CONFIG_SND_SOC_CS42L52 is not set
# CONFIG_SND_SOC_CS42L56 is not set
# CONFIG_SND_SOC_CS42L73 is not set
# CONFIG_SND_SOC_CS42L83 is not set
# CONFIG_SND_SOC_CS42L84 is not set
# CONFIG_SND_SOC_CS4234 is not set
# CONFIG_SND_SOC_CS4265 is not set
# CONFIG_SND_SOC_CS4270 is not set
# CONFIG_SND_SOC_CS4271_I2C is not set
# CONFIG_SND_SOC_CS4271_SPI is not set
# CONFIG_SND_SOC_CS42XX8_SPI is not set
# CONFIG_SND_SOC_CS42XX8_I2C is not set
# CONFIG_SND_SOC_CS43130 is not set
# CONFIG_SND_SOC_CS4341 is not set
# CONFIG_SND_SOC_CS4349 is not set
# CONFIG_SND_SOC_CS48L32 is not set
# CONFIG_SND_SOC_CS53L30 is not set
# CONFIG_SND_SOC_CS530X_I2C is not set
# CONFIG_SND_SOC_CS530X_SPI is not set
# CONFIG_SND_SOC_CX2072X is not set
# CONFIG_SND_SOC_DA7213 is not set
# CONFIG_SND_SOC_DMIC is not set
# CONFIG_SND_SOC_ES7134 is not set
# CONFIG_SND_SOC_ES7241 is not set
# CONFIG_SND_SOC_ES8311 is not set
# CONFIG_SND_SOC_ES8316 is not set
# CONFIG_SND_SOC_ES8323 is not set
# CONFIG_SND_SOC_ES8326 is not set
# CONFIG_SND_SOC_ES8328_I2C is not set
# CONFIG_SND_SOC_ES8328_SPI is not set
# CONFIG_SND_SOC_ES8375 is not set
# CONFIG_SND_SOC_ES8389 is not set
# CONFIG_SND_SOC_FS210X is not set
# CONFIG_SND_SOC_GTM601 is not set
# CONFIG_SND_SOC_HDA is not set
# CONFIG_SND_SOC_ICS43432 is not set
# CONFIG_SND_SOC_IDT821034 is not set
# CONFIG_SND_SOC_MAX98088 is not set
# CONFIG_SND_SOC_MAX98090 is not set
# CONFIG_SND_SOC_MAX98357A is not set
# CONFIG_SND_SOC_MAX98504 is not set
# CONFIG_SND_SOC_MAX9867 is not set
# CONFIG_SND_SOC_MAX98927 is not set
# CONFIG_SND_SOC_MAX98520 is not set
# CONFIG_SND_SOC_MAX98363 is not set
# CONFIG_SND_SOC_MAX98373_I2C is not set
# CONFIG_SND_SOC_MAX98373_SDW is not set
# CONFIG_SND_SOC_MAX98388 is not set
# CONFIG_SND_SOC_MAX98390 is not set
# CONFIG_SND_SOC_MAX98396 is not set
# CONFIG_SND_SOC_MAX9860 is not set
# CONFIG_SND_SOC_MSM8916_WCD_DIGITAL is not set
# CONFIG_SND_SOC_PCM1681 is not set
# CONFIG_SND_SOC_PCM1754 is not set
# CONFIG_SND_SOC_PCM1789_I2C is not set
# CONFIG_SND_SOC_PCM179X_I2C is not set
# CONFIG_SND_SOC_PCM179X_SPI is not set
# CONFIG_SND_SOC_PCM186X_I2C is not set
# CONFIG_SND_SOC_PCM186X_SPI is not set
# CONFIG_SND_SOC_PCM3060_I2C is not set
# CONFIG_SND_SOC_PCM3060_SPI is not set
# CONFIG_SND_SOC_PCM3168A_I2C is not set
# CONFIG_SND_SOC_PCM3168A_SPI is not set
# CONFIG_SND_SOC_PCM5102A is not set
# CONFIG_SND_SOC_PCM512x_I2C is not set
# CONFIG_SND_SOC_PCM512x_SPI is not set
# CONFIG_SND_SOC_PCM6240 is not set
# CONFIG_SND_SOC_PEB2466 is not set
# CONFIG_SND_SOC_PM4125_SDW is not set
# CONFIG_SND_SOC_RT1017_SDCA_SDW is not set
# CONFIG_SND_SOC_RT1308_SDW is not set
# CONFIG_SND_SOC_RT1316_SDW is not set
# CONFIG_SND_SOC_RT1318_SDW is not set
# CONFIG_SND_SOC_RT1320_SDW is not set
# CONFIG_SND_SOC_RT5575 is not set
# CONFIG_SND_SOC_RT5616 is not set
# CONFIG_SND_SOC_RT5631 is not set
# CONFIG_SND_SOC_RT5640 is not set
# CONFIG_SND_SOC_RT5659 is not set
# CONFIG_SND_SOC_RT5682_SDW is not set
# CONFIG_SND_SOC_RT700_SDW is not set
# CONFIG_SND_SOC_RT711_SDW is not set
# CONFIG_SND_SOC_RT711_SDCA_SDW is not set
# CONFIG_SND_SOC_RT712_SDCA_SDW is not set
# CONFIG_SND_SOC_RT712_SDCA_DMIC_SDW is not set
# CONFIG_SND_SOC_RT721_SDCA_SDW is not set
# CONFIG_SND_SOC_RT722_SDCA_SDW is not set
# CONFIG_SND_SOC_RT715_SDW is not set
# CONFIG_SND_SOC_RT715_SDCA_SDW is not set
# CONFIG_SND_SOC_RT9120 is not set
# CONFIG_SND_SOC_RT9123 is not set
# CONFIG_SND_SOC_RT9123P is not set
# CONFIG_SND_SOC_RTQ9124 is not set
# CONFIG_SND_SOC_RTQ9128 is not set
# CONFIG_SND_SOC_SDW_MOCKUP is not set
# CONFIG_SND_SOC_SGTL5000 is not set
# CONFIG_SND_SOC_SIMPLE_AMPLIFIER is not set
# CONFIG_SND_SOC_SIMPLE_MUX is not set
# CONFIG_SND_SOC_SMA1303 is not set
# CONFIG_SND_SOC_SMA1307 is not set
# CONFIG_SND_SOC_SPDIF is not set
# CONFIG_SND_SOC_SRC4XXX_I2C is not set
# CONFIG_SND_SOC_SSM2305 is not set
# CONFIG_SND_SOC_SSM2518 is not set
# CONFIG_SND_SOC_SSM2602_SPI is not set
# CONFIG_SND_SOC_SSM2602_I2C is not set
# CONFIG_SND_SOC_SSM3515 is not set
# CONFIG_SND_SOC_SSM4567 is not set
# CONFIG_SND_SOC_STA32X is not set
# CONFIG_SND_SOC_STA350 is not set
# CONFIG_SND_SOC_STI_SAS is not set
# CONFIG_SND_SOC_TAS2552 is not set
# CONFIG_SND_SOC_TAS2562 is not set
# CONFIG_SND_SOC_TAS2764 is not set
# CONFIG_SND_SOC_TAS2770 is not set
# CONFIG_SND_SOC_TAS2780 is not set
# CONFIG_SND_SOC_TAS2781_I2C is not set
# CONFIG_SND_SOC_TAS5086 is not set
# CONFIG_SND_SOC_TAS571X is not set
# CONFIG_SND_SOC_TAS5720 is not set
# CONFIG_SND_SOC_TAS5805M is not set
# CONFIG_SND_SOC_TAS6424 is not set
# CONFIG_SND_SOC_TAS675X is not set
# CONFIG_SND_SOC_TDA7419 is not set
# CONFIG_SND_SOC_TFA9879 is not set
# CONFIG_SND_SOC_TFA989X is not set
# CONFIG_SND_SOC_TLV320ADC3XXX is not set
# CONFIG_SND_SOC_TLV320AIC23_I2C is not set
# CONFIG_SND_SOC_TLV320AIC23_SPI is not set
# CONFIG_SND_SOC_TLV320AIC31XX is not set
# CONFIG_SND_SOC_TLV320AIC32X4_I2C is not set
# CONFIG_SND_SOC_TLV320AIC32X4_SPI is not set
# CONFIG_SND_SOC_TLV320AIC3X_I2C is not set
# CONFIG_SND_SOC_TLV320AIC3X_SPI is not set
# CONFIG_SND_SOC_TLV320ADCX140 is not set
# CONFIG_SND_SOC_TS3A227E is not set
# CONFIG_SND_SOC_TSCS42XX is not set
# CONFIG_SND_SOC_TSCS454 is not set
# CONFIG_SND_SOC_UDA1334 is not set
# CONFIG_SND_SOC_UDA1342 is not set
# CONFIG_SND_SOC_UDA1380 is not set
# CONFIG_SND_SOC_WCD937X_SDW is not set
# CONFIG_SND_SOC_WCD938X_SDW is not set
# CONFIG_SND_SOC_WCD939X_SDW is not set
# CONFIG_SND_SOC_WM8510 is not set
# CONFIG_SND_SOC_WM8523 is not set
# CONFIG_SND_SOC_WM8524 is not set
# CONFIG_SND_SOC_WM8580 is not set
# CONFIG_SND_SOC_WM8711 is not set
# CONFIG_SND_SOC_WM8728 is not set
# CONFIG_SND_SOC_WM8731_I2C is not set
# CONFIG_SND_SOC_WM8731_SPI is not set
# CONFIG_SND_SOC_WM8737 is not set
# CONFIG_SND_SOC_WM8741 is not set
# CONFIG_SND_SOC_WM8750 is not set
# CONFIG_SND_SOC_WM8753 is not set
# CONFIG_SND_SOC_WM8770 is not set
# CONFIG_SND_SOC_WM8776 is not set
# CONFIG_SND_SOC_WM8782 is not set
# CONFIG_SND_SOC_WM8804_I2C is not set
# CONFIG_SND_SOC_WM8804_SPI is not set
# CONFIG_SND_SOC_WM8903 is not set
# CONFIG_SND_SOC_WM8904 is not set
# CONFIG_SND_SOC_WM8940 is not set
# CONFIG_SND_SOC_WM8960 is not set
# CONFIG_SND_SOC_WM8961 is not set
# CONFIG_SND_SOC_WM8962 is not set
# CONFIG_SND_SOC_WM8974 is not set
# CONFIG_SND_SOC_WM8978 is not set
# CONFIG_SND_SOC_WM8985 is not set
# CONFIG_SND_SOC_WSA881X is not set
# CONFIG_SND_SOC_WSA883X is not set
# CONFIG_SND_SOC_WSA884X is not set
# CONFIG_SND_SOC_ZL38060 is not set
# CONFIG_SND_SOC_MAX9759 is not set
# CONFIG_SND_SOC_MT6351 is not set
# CONFIG_SND_SOC_MT6357 is not set
# CONFIG_SND_SOC_MT6358 is not set
# CONFIG_SND_SOC_MT6660 is not set
# CONFIG_SND_SOC_NAU8315 is not set
# CONFIG_SND_SOC_NAU8325 is not set
# CONFIG_SND_SOC_NAU8540 is not set
# CONFIG_SND_SOC_NAU8810 is not set
# CONFIG_SND_SOC_NAU8821 is not set
# CONFIG_SND_SOC_NAU8822 is not set
# CONFIG_SND_SOC_NAU8824 is not set
# CONFIG_SND_SOC_NTP8918 is not set
# CONFIG_SND_SOC_NTP8835 is not set
# CONFIG_SND_SOC_TPA6130A2 is not set
# CONFIG_SND_SOC_LPASS_WSA_MACRO is not set
# CONFIG_SND_SOC_LPASS_VA_MACRO is not set
# CONFIG_SND_SOC_LPASS_RX_MACRO is not set
# CONFIG_SND_SOC_LPASS_TX_MACRO is not set
# end of CODEC drivers

#
# Generic drivers
#
# CONFIG_SND_SIMPLE_CARD is not set
# CONFIG_SND_AUDIO_GRAPH_CARD is not set
# CONFIG_SND_AUDIO_GRAPH_CARD2 is not set
# CONFIG_SND_TEST_COMPONENT is not set
# end of Generic drivers

CONFIG_SND_X86=y
# CONFIG_HDMI_LPE_AUDIO is not set
CONFIG_SND_VIRTIO=y
CONFIG_HID_SUPPORT=y
CONFIG_HID=y
CONFIG_HID_BATTERY_STRENGTH=y
CONFIG_HIDRAW=y
CONFIG_UHID=y
CONFIG_HID_GENERIC=y
CONFIG_HID_HAPTIC=y

#
# Special HID drivers
#
CONFIG_HID_A4TECH=y
CONFIG_HID_ACCUTOUCH=y
CONFIG_HID_ACRUX=y
CONFIG_HID_ACRUX_FF=y
CONFIG_HID_APPLE=y
CONFIG_HID_APPLEIR=y
# CONFIG_HID_APPLETB_BL is not set
# CONFIG_HID_APPLETB_KBD is not set
CONFIG_HID_ASUS=y
CONFIG_HID_AUREAL=y
CONFIG_HID_BELKIN=y
CONFIG_HID_BETOP_FF=y
CONFIG_HID_BIGBEN_FF=y
CONFIG_HID_CHERRY=y
CONFIG_HID_CHICONY=y
CONFIG_HID_CORSAIR=y
CONFIG_HID_COUGAR=y
CONFIG_HID_MACALLY=y
CONFIG_HID_PRODIKEYS=y
CONFIG_HID_CMEDIA=y
CONFIG_HID_CP2112=y
CONFIG_HID_CREATIVE_SB0540=y
CONFIG_HID_CYPRESS=y
CONFIG_HID_DRAGONRISE=y
CONFIG_DRAGONRISE_FF=y
CONFIG_HID_EMS_FF=y
CONFIG_HID_ELAN=y
CONFIG_HID_ELECOM=y
CONFIG_HID_ELO=y
CONFIG_HID_EVISION=y
CONFIG_HID_EZKEY=y
CONFIG_HID_FT260=y
CONFIG_HID_GEMBIRD=y
CONFIG_HID_GFRM=y
CONFIG_HID_GLORIOUS=y
CONFIG_HID_HOLTEK=y
CONFIG_HOLTEK_FF=y
CONFIG_HID_VIVALDI_COMMON=y
# CONFIG_HID_GOODIX_SPI is not set
CONFIG_HID_GOOGLE_STADIA_FF=y
CONFIG_HID_VIVALDI=y
CONFIG_HID_GT683R=y
CONFIG_HID_KEYTOUCH=y
CONFIG_HID_KYE=y
# CONFIG_HID_KYSONA is not set
CONFIG_HID_UCLOGIC=y
CONFIG_HID_WALTOP=y
CONFIG_HID_VIEWSONIC=y
CONFIG_HID_VRC2=y
CONFIG_HID_XIAOMI=y
CONFIG_HID_GYRATION=y
CONFIG_HID_ICADE=y
CONFIG_HID_ITE=y
CONFIG_HID_JABRA=y
CONFIG_HID_TWINHAN=y
CONFIG_HID_KENSINGTON=y
CONFIG_HID_LCPOWER=y
CONFIG_HID_LED=y
CONFIG_HID_LENOVO=y
# CONFIG_HID_LENOVO_GO is not set
# CONFIG_HID_LENOVO_GO_S is not set
CONFIG_HID_LETSKETCH=y
CONFIG_HID_LOGITECH=y
CONFIG_HID_LOGITECH_DJ=y
CONFIG_HID_LOGITECH_HIDPP=y
CONFIG_LOGITECH_FF=y
CONFIG_LOGIRUMBLEPAD2_FF=y
CONFIG_LOGIG940_FF=y
CONFIG_LOGIWHEELS_FF=y
CONFIG_HID_MAGICMOUSE=y
CONFIG_HID_MALTRON=y
CONFIG_HID_MAYFLASH=y
CONFIG_HID_MEGAWORLD_FF=y
# CONFIG_HID_RAKK is not set
CONFIG_HID_REDRAGON=y
CONFIG_HID_MICROSOFT=y
CONFIG_HID_MONTEREY=y
CONFIG_HID_MULTITOUCH=y
CONFIG_HID_NINTENDO=y
CONFIG_NINTENDO_FF=y
CONFIG_HID_NTI=y
CONFIG_HID_NTRIG=y
CONFIG_HID_NVIDIA_SHIELD=y
CONFIG_NVIDIA_SHIELD_FF=y
CONFIG_HID_ORTEK=y
# CONFIG_HID_OXP is not set
CONFIG_HID_PANTHERLORD=y
CONFIG_PANTHERLORD_FF=y
CONFIG_HID_PENMOUNT=y
CONFIG_HID_PETALYNX=y
CONFIG_HID_PICOLCD=y
CONFIG_HID_PICOLCD_FB=y
CONFIG_HID_PICOLCD_BACKLIGHT=y
CONFIG_HID_PICOLCD_LCD=y
CONFIG_HID_PICOLCD_LEDS=y
CONFIG_HID_PICOLCD_CIR=y
CONFIG_HID_PLANTRONICS=y
CONFIG_HID_PLAYSTATION=y
CONFIG_PLAYSTATION_FF=y
CONFIG_HID_PXRC=y
# CONFIG_HID_RAPOO is not set
CONFIG_HID_RAZER=y
CONFIG_HID_PRIMAX=y
CONFIG_HID_RETRODE=y
CONFIG_HID_ROCCAT=y
CONFIG_HID_SAITEK=y
CONFIG_HID_SAMSUNG=y
CONFIG_HID_SEMITEK=y
CONFIG_HID_SIGMAMICRO=y
CONFIG_HID_SONY=y
CONFIG_SONY_FF=y
CONFIG_HID_SPEEDLINK=y
CONFIG_HID_STEAM=y
CONFIG_STEAM_FF=y
CONFIG_HID_STEELSERIES=y
CONFIG_HID_SUNPLUS=y
CONFIG_HID_RMI=y
CONFIG_HID_GREENASIA=y
CONFIG_GREENASIA_FF=y
CONFIG_HID_SMARTJOYPLUS=y
CONFIG_SMARTJOYPLUS_FF=y
CONFIG_HID_TIVO=y
CONFIG_HID_TOPSEED=y
CONFIG_HID_TOPRE=y
CONFIG_HID_THINGM=y
CONFIG_HID_THRUSTMASTER=y
CONFIG_THRUSTMASTER_FF=y
CONFIG_HID_UDRAW_PS3=y
CONFIG_HID_U2FZERO=y
# CONFIG_HID_UNIVERSAL_PIDFF is not set
CONFIG_HID_WACOM=y
CONFIG_HID_WIIMOTE=y
# CONFIG_HID_WINWING is not set
CONFIG_HID_XINMO=y
CONFIG_HID_ZEROPLUS=y
CONFIG_ZEROPLUS_FF=y
CONFIG_HID_ZYDACRON=y
CONFIG_HID_SENSOR_HUB=y
CONFIG_HID_SENSOR_CUSTOM_SENSOR=y
CONFIG_HID_ALPS=y
CONFIG_HID_MCP2200=y
CONFIG_HID_MCP2221=y
CONFIG_HID_HUAWEI=y
# end of Special HID drivers

#
# HID-BPF support
#
# end of HID-BPF support

CONFIG_I2C_HID=y
CONFIG_I2C_HID_ACPI=y
CONFIG_I2C_HID_OF=y
# CONFIG_I2C_HID_OF_ELAN is not set
# CONFIG_I2C_HID_OF_GOODIX is not set
CONFIG_I2C_HID_CORE=y

#
# Intel ISH HID support
#
CONFIG_INTEL_ISH_HID=y
CONFIG_INTEL_ISH_FIRMWARE_DOWNLOADER=y
# end of Intel ISH HID support

#
# AMD SFH HID Support
#
CONFIG_AMD_SFH_HID=y
# end of AMD SFH HID Support

#
# Surface System Aggregator Module HID support
#
CONFIG_SURFACE_HID=y
CONFIG_SURFACE_KBD=y
# end of Surface System Aggregator Module HID support

CONFIG_SURFACE_HID_CORE=y

#
# Intel THC HID Support
#
# CONFIG_INTEL_THC_HID is not set
# end of Intel THC HID Support

#
# USB HID support
#
CONFIG_USB_HID=y
CONFIG_HID_PID=y
CONFIG_USB_HIDDEV=y
# end of USB HID support

CONFIG_USB_OHCI_LITTLE_ENDIAN=y
CONFIG_USB_SUPPORT=y
CONFIG_USB_COMMON=y
CONFIG_USB_LED_TRIG=y
CONFIG_USB_ULPI_BUS=y
CONFIG_USB_CONN_GPIO=y
CONFIG_USB_ARCH_HAS_HCD=y
CONFIG_USB=y
CONFIG_USB_PCI=y
CONFIG_USB_PCI_AMD=y
CONFIG_USB_ANNOUNCE_NEW_DEVICES=y

#
# Miscellaneous USB options
#
CONFIG_USB_DEFAULT_PERSIST=y
CONFIG_USB_FEW_INIT_RETRIES=y
CONFIG_USB_DYNAMIC_MINORS=y
CONFIG_USB_OTG=y
# CONFIG_USB_OTG_PRODUCTLIST is not set
# CONFIG_USB_OTG_DISABLE_EXTERNAL_HUB is not set
CONFIG_USB_OTG_FSM=y
CONFIG_USB_LEDS_TRIGGER_USBPORT=y
CONFIG_USB_AUTOSUSPEND_DELAY=2
CONFIG_USB_DEFAULT_AUTHORIZATION_MODE=1
CONFIG_USB_MON=y

#
# USB Host Controller Drivers
#
CONFIG_USB_C67X00_HCD=y
CONFIG_USB_XHCI_HCD=y
CONFIG_USB_XHCI_DBGCAP=y
CONFIG_USB_XHCI_PCI=y
CONFIG_USB_XHCI_PCI_RENESAS=y
CONFIG_USB_XHCI_PLATFORM=y
# CONFIG_USB_XHCI_SIDEBAND is not set
CONFIG_USB_EHCI_HCD=y
CONFIG_USB_EHCI_ROOT_HUB_TT=y
CONFIG_USB_EHCI_TT_NEWSCHED=y
CONFIG_USB_EHCI_PCI=y
CONFIG_USB_EHCI_FSL=y
CONFIG_USB_EHCI_HCD_PLATFORM=y
CONFIG_USB_OXU210HP_HCD=y
CONFIG_USB_ISP116X_HCD=y
CONFIG_USB_MAX3421_HCD=y
CONFIG_USB_OHCI_HCD=y
CONFIG_USB_OHCI_HCD_PCI=y
# CONFIG_USB_OHCI_HCD_SSB is not set
CONFIG_USB_OHCI_HCD_PLATFORM=y
CONFIG_USB_UHCI_HCD=y
CONFIG_USB_SL811_HCD=y
CONFIG_USB_SL811_HCD_ISO=y
CONFIG_USB_SL811_CS=y
CONFIG_USB_R8A66597_HCD=y
CONFIG_USB_HCD_BCMA=y
CONFIG_USB_HCD_SSB=y
# CONFIG_USB_HCD_TEST_MODE is not set

#
# USB Device Class drivers
#
CONFIG_USB_ACM=y
CONFIG_USB_PRINTER=y
CONFIG_USB_WDM=y
CONFIG_USB_TMC=y

#
# NOTE: USB_STORAGE depends on SCSI but BLK_DEV_SD may also be needed; see USB_STORAGE Help for more info
#
CONFIG_USB_STORAGE=y
# CONFIG_USB_STORAGE_DEBUG is not set
CONFIG_USB_STORAGE_REALTEK=y
CONFIG_REALTEK_AUTOPM=y
CONFIG_USB_STORAGE_DATAFAB=y
CONFIG_USB_STORAGE_FREECOM=y
CONFIG_USB_STORAGE_ISD200=y
CONFIG_USB_STORAGE_USBAT=y
CONFIG_USB_STORAGE_SDDR09=y
CONFIG_USB_STORAGE_SDDR55=y
CONFIG_USB_STORAGE_JUMPSHOT=y
CONFIG_USB_STORAGE_ALAUDA=y
CONFIG_USB_STORAGE_ONETOUCH=y
CONFIG_USB_STORAGE_KARMA=y
CONFIG_USB_STORAGE_CYPRESS_ATACB=y
CONFIG_USB_STORAGE_ENE_UB6250=y
CONFIG_USB_UAS=y

#
# USB Imaging devices
#
CONFIG_USB_MDC800=y
CONFIG_USB_MICROTEK=y
CONFIG_USBIP_CORE=y
CONFIG_USBIP_VHCI_HCD=y
CONFIG_USBIP_VHCI_HC_PORTS=8
CONFIG_USBIP_VHCI_NR_HCS=16
CONFIG_USBIP_HOST=y
CONFIG_USBIP_VUDC=y
# CONFIG_USBIP_DEBUG is not set

#
# USB dual-mode controller drivers
#
CONFIG_USB_CDNS_SUPPORT=y
CONFIG_USB_CDNS3=y
CONFIG_USB_CDNS3_HOST=y
CONFIG_USB_CDNS3_GADGET=y

#
# Platform glue driver support
#
CONFIG_USB_CDNS3_PCI_WRAP=y
CONFIG_USB_CDNSP_PCI=y
CONFIG_USB_MUSB_HDRC=y
# CONFIG_USB_MUSB_HOST is not set
# CONFIG_USB_MUSB_GADGET is not set
CONFIG_USB_MUSB_DUAL_ROLE=y

#
# Platform Glue Layer
#

#
# MUSB DMA mode
#
CONFIG_MUSB_PIO_ONLY=y
CONFIG_USB_DWC3=y
CONFIG_USB_DWC3_ULPI=y
# CONFIG_USB_DWC3_HOST is not set
CONFIG_USB_DWC3_GADGET=y
# CONFIG_USB_DWC3_DUAL_ROLE is not set

#
# Platform Glue Driver Support
#
CONFIG_USB_DWC3_PCI=y
CONFIG_USB_DWC3_HAPS=y
CONFIG_USB_DWC3_OF_SIMPLE=y
CONFIG_USB_DWC3_GENERIC_PLAT=y
# CONFIG_USB_DWC3_GOOGLE is not set
CONFIG_USB_DWC2=y
CONFIG_USB_DWC2_HOST=y

#
# Gadget/Dual-role mode requires USB Gadget support to be enabled
#
# CONFIG_USB_DWC2_PERIPHERAL is not set
# CONFIG_USB_DWC2_DUAL_ROLE is not set
CONFIG_USB_DWC2_PCI=y
# CONFIG_USB_DWC2_DEBUG is not set
# CONFIG_USB_DWC2_TRACK_MISSED_SOFS is not set
CONFIG_USB_CHIPIDEA=y
CONFIG_USB_CHIPIDEA_UDC=y
CONFIG_USB_CHIPIDEA_HOST=y
CONFIG_USB_CHIPIDEA_PCI=y
CONFIG_USB_CHIPIDEA_MSM=y
CONFIG_USB_CHIPIDEA_NPCM=y
# CONFIG_USB_CHIPIDEA_IMX is not set
CONFIG_USB_CHIPIDEA_GENERIC=y
# CONFIG_USB_CHIPIDEA_TEGRA is not set
CONFIG_USB_ISP1760=y
CONFIG_USB_ISP1760_HCD=y
CONFIG_USB_ISP1761_UDC=y
# CONFIG_USB_ISP1760_HOST_ROLE is not set
# CONFIG_USB_ISP1760_GADGET_ROLE is not set
CONFIG_USB_ISP1760_DUAL_ROLE=y

#
# USB port drivers
#
CONFIG_USB_SERIAL=y
CONFIG_USB_SERIAL_CONSOLE=y
CONFIG_USB_SERIAL_GENERIC=y
CONFIG_USB_SERIAL_SIMPLE=y
CONFIG_USB_SERIAL_AIRCABLE=y
CONFIG_USB_SERIAL_ARK3116=y
CONFIG_USB_SERIAL_BELKIN=y
CONFIG_USB_SERIAL_CH341=y
CONFIG_USB_SERIAL_WHITEHEAT=y
CONFIG_USB_SERIAL_DIGI_ACCELEPORT=y
CONFIG_USB_SERIAL_CP210X=y
CONFIG_USB_SERIAL_CYPRESS_M8=y
CONFIG_USB_SERIAL_EMPEG=y
CONFIG_USB_SERIAL_FTDI_SIO=y
CONFIG_USB_SERIAL_VISOR=y
CONFIG_USB_SERIAL_IPAQ=y
CONFIG_USB_SERIAL_IR=y
CONFIG_USB_SERIAL_EDGEPORT=y
CONFIG_USB_SERIAL_EDGEPORT_TI=y
CONFIG_USB_SERIAL_F81232=y
CONFIG_USB_SERIAL_F8153X=y
CONFIG_USB_SERIAL_GARMIN=y
CONFIG_USB_SERIAL_IPW=y
CONFIG_USB_SERIAL_IUU=y
CONFIG_USB_SERIAL_KEYSPAN_PDA=y
CONFIG_USB_SERIAL_KEYSPAN=y
CONFIG_USB_SERIAL_KLSI=y
CONFIG_USB_SERIAL_KOBIL_SCT=y
CONFIG_USB_SERIAL_MCT_U232=y
CONFIG_USB_SERIAL_METRO=y
CONFIG_USB_SERIAL_MOS7720=y
CONFIG_USB_SERIAL_MOS7715_PARPORT=y
CONFIG_USB_SERIAL_MOS7840=y
CONFIG_USB_SERIAL_MXUPORT=y
CONFIG_USB_SERIAL_NAVMAN=y
CONFIG_USB_SERIAL_PL2303=y
CONFIG_USB_SERIAL_OTI6858=y
CONFIG_USB_SERIAL_QCAUX=y
CONFIG_USB_SERIAL_QUALCOMM=y
CONFIG_USB_SERIAL_SPCP8X5=y
CONFIG_USB_SERIAL_SAFE=y
# CONFIG_USB_SERIAL_SAFE_PADDED is not set
CONFIG_USB_SERIAL_SIERRAWIRELESS=y
CONFIG_USB_SERIAL_SYMBOL=y
CONFIG_USB_SERIAL_TI=y
CONFIG_USB_SERIAL_CYBERJACK=y
CONFIG_USB_SERIAL_WWAN=y
CONFIG_USB_SERIAL_OPTION=y
CONFIG_USB_SERIAL_OMNINET=y
CONFIG_USB_SERIAL_OPTICON=y
CONFIG_USB_SERIAL_XSENS_MT=y
CONFIG_USB_SERIAL_WISHBONE=y
CONFIG_USB_SERIAL_SSU100=y
CONFIG_USB_SERIAL_QT2=y
CONFIG_USB_SERIAL_UPD78F0730=y
CONFIG_USB_SERIAL_XR=y
CONFIG_USB_SERIAL_DEBUG=y

#
# USB Miscellaneous drivers
#
CONFIG_USB_USS720=y
CONFIG_USB_EMI62=y
CONFIG_USB_EMI26=y
CONFIG_USB_ADUTUX=y
CONFIG_USB_SEVSEG=y
CONFIG_USB_LEGOTOWER=y
CONFIG_USB_LCD=y
CONFIG_USB_CYPRESS_CY7C63=y
CONFIG_USB_CYTHERM=y
CONFIG_USB_IDMOUSE=y
CONFIG_USB_APPLEDISPLAY=y
CONFIG_APPLE_MFI_FASTCHARGE=y
CONFIG_USB_LJCA=y
# CONFIG_USB_USBIO is not set
CONFIG_USB_SISUSBVGA=y
CONFIG_USB_LD=y
CONFIG_USB_TRANCEVIBRATOR=y
CONFIG_USB_IOWARRIOR=y
CONFIG_USB_TEST=y
CONFIG_USB_EHSET_TEST_FIXTURE=y
CONFIG_USB_ISIGHTFW=y
CONFIG_USB_YUREX=y
CONFIG_USB_EZUSB_FX2=y
CONFIG_USB_HUB_USB251XB=y
CONFIG_USB_HSIC_USB3503=y
CONFIG_USB_HSIC_USB4604=y
CONFIG_USB_LINK_LAYER_TEST=y
CONFIG_USB_CHAOSKEY=y
# CONFIG_USB_ONBOARD_DEV is not set
CONFIG_USB_ATM=y
CONFIG_USB_SPEEDTOUCH=y
CONFIG_USB_CXACRU=y
CONFIG_USB_UEAGLEATM=y
CONFIG_USB_XUSBATM=y

#
# USB Physical Layer drivers
#
CONFIG_USB_PHY=y
CONFIG_NOP_USB_XCEIV=y
CONFIG_TAHVO_USB=y
CONFIG_TAHVO_USB_HOST_BY_DEFAULT=y
CONFIG_USB_ISP1301=y
# end of USB Physical Layer drivers

CONFIG_USB_GADGET=y
# CONFIG_USB_GADGET_DEBUG is not set
CONFIG_USB_GADGET_DEBUG_FILES=y
CONFIG_USB_GADGET_DEBUG_FS=y
CONFIG_USB_GADGET_VBUS_DRAW=2
CONFIG_USB_GADGET_STORAGE_NUM_BUFFERS=2
CONFIG_U_SERIAL_CONSOLE=y

#
# USB Peripheral Controller
#
CONFIG_USB_GR_UDC=y
CONFIG_USB_R8A66597=y
CONFIG_USB_PXA27X=y
CONFIG_USB_SNP_CORE=y
# CONFIG_USB_SNP_UDC_PLAT is not set
# CONFIG_USB_M66592 is not set
CONFIG_USB_BDC_UDC=y
CONFIG_USB_AMD5536UDC=y
CONFIG_USB_NET2280=y
CONFIG_USB_GOKU=y
CONFIG_USB_EG20T=y
# CONFIG_USB_GADGET_XILINX is not set
CONFIG_USB_MAX3420_UDC=y
CONFIG_USB_CDNS2_UDC=y
CONFIG_USB_DUMMY_HCD=y
# end of USB Peripheral Controller

CONFIG_USB_LIBCOMPOSITE=y
CONFIG_USB_F_ACM=y
CONFIG_USB_F_SS_LB=y
CONFIG_USB_U_SERIAL=y
CONFIG_USB_U_ETHER=y
CONFIG_USB_U_AUDIO=y
CONFIG_USB_F_SERIAL=y
CONFIG_USB_F_OBEX=y
CONFIG_USB_F_NCM=y
CONFIG_USB_F_ECM=y
CONFIG_USB_F_PHONET=y
CONFIG_USB_F_EEM=y
CONFIG_USB_F_SUBSET=y
CONFIG_USB_F_RNDIS=y
CONFIG_USB_F_MASS_STORAGE=y
CONFIG_USB_F_FS=y
CONFIG_USB_F_UAC1=y
CONFIG_USB_F_UAC1_LEGACY=y
CONFIG_USB_F_UAC2=y
CONFIG_USB_F_UVC=y
CONFIG_USB_F_MIDI=y
CONFIG_USB_F_MIDI2=y
CONFIG_USB_F_HID=y
CONFIG_USB_F_PRINTER=y
CONFIG_USB_F_TCM=y
CONFIG_USB_CONFIGFS=y
CONFIG_USB_CONFIGFS_SERIAL=y
CONFIG_USB_CONFIGFS_ACM=y
CONFIG_USB_CONFIGFS_OBEX=y
CONFIG_USB_CONFIGFS_NCM=y
CONFIG_USB_CONFIGFS_ECM=y
CONFIG_USB_CONFIGFS_ECM_SUBSET=y
CONFIG_USB_CONFIGFS_RNDIS=y
CONFIG_USB_CONFIGFS_EEM=y
CONFIG_USB_CONFIGFS_PHONET=y
CONFIG_USB_CONFIGFS_MASS_STORAGE=y
CONFIG_USB_CONFIGFS_F_LB_SS=y
CONFIG_USB_CONFIGFS_F_FS=y
CONFIG_USB_CONFIGFS_F_UAC1=y
CONFIG_USB_CONFIGFS_F_UAC1_LEGACY=y
CONFIG_USB_CONFIGFS_F_UAC2=y
CONFIG_USB_CONFIGFS_F_MIDI=y
CONFIG_USB_CONFIGFS_F_MIDI2=y
CONFIG_USB_CONFIGFS_F_HID=y
CONFIG_USB_CONFIGFS_F_UVC=y
CONFIG_USB_CONFIGFS_F_PRINTER=y
CONFIG_USB_CONFIGFS_F_TCM=y

#
# USB Gadget precomposed configurations
#
# CONFIG_USB_ZERO is not set
# CONFIG_USB_AUDIO is not set
# CONFIG_USB_ETH is not set
# CONFIG_USB_G_NCM is not set
CONFIG_USB_GADGETFS=y
# CONFIG_USB_FUNCTIONFS is not set
# CONFIG_USB_MASS_STORAGE is not set
# CONFIG_USB_GADGET_TARGET is not set
# CONFIG_USB_G_SERIAL is not set
# CONFIG_USB_MIDI_GADGET is not set
# CONFIG_USB_G_PRINTER is not set
# CONFIG_USB_CDC_COMPOSITE is not set
# CONFIG_USB_G_NOKIA is not set
# CONFIG_USB_G_ACM_MS is not set
# CONFIG_USB_G_MULTI is not set
# CONFIG_USB_G_HID is not set
# CONFIG_USB_G_DBGP is not set
# CONFIG_USB_G_WEBCAM is not set
CONFIG_USB_RAW_GADGET=y
# end of USB Gadget precomposed configurations

CONFIG_TYPEC=y
CONFIG_TYPEC_TCPM=y
CONFIG_TYPEC_TCPCI=y
CONFIG_TYPEC_RT1711H=y
CONFIG_TYPEC_MT6360=y
CONFIG_TYPEC_TCPCI_MT6370=y
CONFIG_TYPEC_TCPCI_MAXIM=y
CONFIG_TYPEC_FUSB302=y
CONFIG_TYPEC_WCOVE=y
CONFIG_TYPEC_UCSI=y
CONFIG_UCSI_CCG=y
CONFIG_UCSI_ACPI=y
CONFIG_UCSI_STM32G0=y
CONFIG_TYPEC_TPS6598X=y
CONFIG_TYPEC_ANX7411=y
CONFIG_TYPEC_RT1719=y
CONFIG_TYPEC_HD3SS3220=y
CONFIG_TYPEC_STUSB160X=y
CONFIG_TYPEC_WUSB3801=y

#
# USB Type-C Multiplexer/DeMultiplexer Switch support
#
CONFIG_TYPEC_MUX_FSA4480=y
CONFIG_TYPEC_MUX_GPIO_SBU=y
CONFIG_TYPEC_MUX_PI3USB30532=y
CONFIG_TYPEC_MUX_INTEL_PMC=y
# CONFIG_TYPEC_MUX_IT5205 is not set
CONFIG_TYPEC_MUX_NB7VPQ904M=y
# CONFIG_TYPEC_MUX_PS883X is not set
CONFIG_TYPEC_MUX_PTN36502=y
# CONFIG_TYPEC_MUX_TUSB1046 is not set
CONFIG_TYPEC_MUX_WCD939X_USBSS=y
# end of USB Type-C Multiplexer/DeMultiplexer Switch support

#
# USB Type-C Alternate Mode drivers
#
CONFIG_TYPEC_DP_ALTMODE=y
CONFIG_TYPEC_NVIDIA_ALTMODE=y
# CONFIG_TYPEC_TBT_ALTMODE is not set
# end of USB Type-C Alternate Mode drivers

CONFIG_USB_ROLE_SWITCH=y
CONFIG_USB_ROLES_INTEL_XHCI=y
CONFIG_MMC=y
# CONFIG_PWRSEQ_EMMC is not set
# CONFIG_PWRSEQ_SD8787 is not set
# CONFIG_PWRSEQ_SIMPLE is not set
# CONFIG_MMC_BLOCK is not set
# CONFIG_SDIO_UART is not set
# CONFIG_MMC_TEST is not set
# CONFIG_MMC_CRYPTO is not set

#
# MMC/SD/SDIO Host Controller Drivers
#
# CONFIG_MMC_DEBUG is not set
# CONFIG_MMC_SDHCI is not set
# CONFIG_MMC_WBSD is not set
# CONFIG_MMC_TIFM_SD is not set
# CONFIG_MMC_SPI is not set
# CONFIG_MMC_SDRICOH_CS is not set
# CONFIG_MMC_CB710 is not set
# CONFIG_MMC_VIA_SDMMC is not set
CONFIG_MMC_VUB300=y
CONFIG_MMC_USHC=y
# CONFIG_MMC_USDHI6ROL0 is not set
CONFIG_MMC_REALTEK_USB=y
# CONFIG_MMC_CQHCI is not set
# CONFIG_MMC_HSQ is not set
# CONFIG_MMC_TOSHIBA_PCI is not set
# CONFIG_MMC_MTK is not set
# CONFIG_SCSI_UFSHCD is not set
CONFIG_MEMSTICK=y
# CONFIG_MEMSTICK_DEBUG is not set

#
# MemoryStick drivers
#
# CONFIG_MEMSTICK_UNSAFE_RESUME is not set
# CONFIG_MSPRO_BLOCK is not set
# CONFIG_MS_BLOCK is not set

#
# MemoryStick Host Controller Drivers
#
# CONFIG_MEMSTICK_TIFM_MS is not set
# CONFIG_MEMSTICK_JMICRON_38X is not set
# CONFIG_MEMSTICK_R592 is not set
CONFIG_MEMSTICK_REALTEK_USB=y
CONFIG_NEW_LEDS=y
CONFIG_LEDS_CLASS=y
# CONFIG_LEDS_CLASS_FLASH is not set
CONFIG_LEDS_CLASS_MULTICOLOR=y
# CONFIG_LEDS_BRIGHTNESS_HW_CHANGED is not set

#
# LED drivers
#
# CONFIG_LEDS_AN30259A is not set
# CONFIG_LEDS_APU is not set
# CONFIG_LEDS_OSRAM_AMS_AS3668 is not set
# CONFIG_LEDS_AW200XX is not set
# CONFIG_LEDS_AW2013 is not set
# CONFIG_LEDS_BCM6328 is not set
# CONFIG_LEDS_BCM6358 is not set
# CONFIG_LEDS_CHT_WCOVE is not set
# CONFIG_LEDS_CR0014114 is not set
# CONFIG_LEDS_EL15203000 is not set
# CONFIG_LEDS_LM3530 is not set
# CONFIG_LEDS_LM3532 is not set
# CONFIG_LEDS_LM3642 is not set
# CONFIG_LEDS_LM3692X is not set
# CONFIG_LEDS_PCA9532 is not set
# CONFIG_LEDS_GPIO is not set
# CONFIG_LEDS_LP3944 is not set
# CONFIG_LEDS_LP3952 is not set
# CONFIG_LEDS_LP50XX is not set
# CONFIG_LEDS_LP55XX_COMMON is not set
# CONFIG_LEDS_LP8860 is not set
# CONFIG_LEDS_LP8864 is not set
# CONFIG_LEDS_PCA955X is not set
# CONFIG_LEDS_PCA963X is not set
# CONFIG_LEDS_PCA995X is not set
# CONFIG_LEDS_DAC124S085 is not set
# CONFIG_LEDS_REGULATOR is not set
# CONFIG_LEDS_BD2606MVV is not set
# CONFIG_LEDS_BD2802 is not set
# CONFIG_LEDS_INTEL_SS4200 is not set
# CONFIG_LEDS_LT3593 is not set
# CONFIG_LEDS_TCA6507 is not set
# CONFIG_LEDS_TLC591XX is not set
# CONFIG_LEDS_LM355x is not set
# CONFIG_LEDS_IS31FL319X is not set
# CONFIG_LEDS_IS31FL32XX is not set

#
# LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)
#
# CONFIG_LEDS_BLINKM is not set
# CONFIG_LEDS_SYSCON is not set
# CONFIG_LEDS_MLXCPLD is not set
# CONFIG_LEDS_MLXREG is not set
# CONFIG_LEDS_USER is not set
# CONFIG_LEDS_NIC78BX is not set
# CONFIG_LEDS_SPI_BYTE is not set
# CONFIG_LEDS_LM3697 is not set
# CONFIG_LEDS_ST1202 is not set
# CONFIG_LEDS_LGM is not set

#
# Flash and Torch LED drivers
#

#
# RGB LED drivers
#
# CONFIG_LEDS_GROUP_MULTICOLOR is not set
# CONFIG_LEDS_KTD202X is not set
# CONFIG_LEDS_LP5812 is not set
# CONFIG_LEDS_LP5860_CORE is not set
# CONFIG_LEDS_LP5860_SPI is not set
# CONFIG_LEDS_NCP5623 is not set
# CONFIG_LEDS_MT6370_RGB is not set

#
# LED Triggers
#
CONFIG_LEDS_TRIGGERS=y
# CONFIG_LEDS_TRIGGER_TIMER is not set
# CONFIG_LEDS_TRIGGER_ONESHOT is not set
# CONFIG_LEDS_TRIGGER_DISK is not set
# CONFIG_LEDS_TRIGGER_MTD is not set
# CONFIG_LEDS_TRIGGER_HEARTBEAT is not set
# CONFIG_LEDS_TRIGGER_BACKLIGHT is not set
# CONFIG_LEDS_TRIGGER_CPU is not set
# CONFIG_LEDS_TRIGGER_ACTIVITY is not set
# CONFIG_LEDS_TRIGGER_GPIO is not set
# CONFIG_LEDS_TRIGGER_DEFAULT_ON is not set

#
# iptables trigger is under Netfilter config (LED target)
#
# CONFIG_LEDS_TRIGGER_TRANSIENT is not set
# CONFIG_LEDS_TRIGGER_CAMERA is not set
# CONFIG_LEDS_TRIGGER_PANIC is not set
# CONFIG_LEDS_TRIGGER_NETDEV is not set
# CONFIG_LEDS_TRIGGER_PATTERN is not set
# CONFIG_LEDS_TRIGGER_TTY is not set
# CONFIG_LEDS_TRIGGER_INPUT_EVENTS is not set

#
# Simatic LED drivers
#
# CONFIG_ACCESSIBILITY is not set
CONFIG_INFINIBAND=y
CONFIG_INFINIBAND_USER_MAD=y
CONFIG_INFINIBAND_USER_ACCESS=y
CONFIG_INFINIBAND_USER_ACCESS_CORE=y
CONFIG_INFINIBAND_USER_MEM=y
CONFIG_INFINIBAND_ON_DEMAND_PAGING=y
CONFIG_INFINIBAND_ADDR_TRANS=y
CONFIG_INFINIBAND_ADDR_TRANS_CONFIGFS=y
CONFIG_INFINIBAND_VIRT_DMA=y
# CONFIG_INFINIBAND_EFA is not set
# CONFIG_INFINIBAND_ERDMA is not set
CONFIG_MLX4_INFINIBAND=y
# CONFIG_INFINIBAND_MTHCA is not set
# CONFIG_INFINIBAND_OCRDMA is not set
# CONFIG_INFINIBAND_USNIC is not set
# CONFIG_INFINIBAND_VMWARE_PVRDMA is not set
# CONFIG_INFINIBAND_RDMAVT is not set
CONFIG_RDMA_RXE=y
CONFIG_RDMA_SIW=y
CONFIG_INFINIBAND_IPOIB=y
CONFIG_INFINIBAND_IPOIB_CM=y
CONFIG_INFINIBAND_IPOIB_DEBUG=y
# CONFIG_INFINIBAND_IPOIB_DEBUG_DATA is not set
CONFIG_INFINIBAND_SRP=y
# CONFIG_INFINIBAND_SRPT is not set
CONFIG_INFINIBAND_ISER=y
CONFIG_INFINIBAND_RTRS=y
CONFIG_INFINIBAND_RTRS_CLIENT=y
# CONFIG_INFINIBAND_RTRS_SERVER is not set
CONFIG_EDAC_ATOMIC_SCRUB=y
CONFIG_EDAC_SUPPORT=y
CONFIG_EDAC=y
# CONFIG_EDAC_DEBUG is not set
# CONFIG_EDAC_DECODE_MCE is not set
# CONFIG_EDAC_SCRUB is not set
# CONFIG_EDAC_ECS is not set
# CONFIG_EDAC_MEM_REPAIR is not set
# CONFIG_EDAC_E752X is not set
# CONFIG_EDAC_I82975X is not set
# CONFIG_EDAC_I3000 is not set
# CONFIG_EDAC_I3200 is not set
# CONFIG_EDAC_IE31200 is not set
# CONFIG_EDAC_X38 is not set
# CONFIG_EDAC_I5400 is not set
# CONFIG_EDAC_I7CORE is not set
# CONFIG_EDAC_I5100 is not set
# CONFIG_EDAC_I7300 is not set
# CONFIG_EDAC_SBRIDGE is not set
# CONFIG_EDAC_SKX is not set
# CONFIG_EDAC_I10NM is not set
# CONFIG_EDAC_IMH is not set
# CONFIG_EDAC_PND2 is not set
# CONFIG_EDAC_IGEN6 is not set
CONFIG_RTC_LIB=y
CONFIG_RTC_MC146818_LIB=y
CONFIG_RTC_CLASS=y
# CONFIG_RTC_HCTOSYS is not set
CONFIG_RTC_SYSTOHC=y
CONFIG_RTC_SYSTOHC_DEVICE="rtc0"
# CONFIG_RTC_DEBUG is not set
# CONFIG_RTC_NVMEM is not set

#
# RTC interfaces
#
CONFIG_RTC_INTF_SYSFS=y
CONFIG_RTC_INTF_PROC=y
CONFIG_RTC_INTF_DEV=y
# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set
# CONFIG_RTC_DRV_TEST is not set

#
# I2C RTC drivers
#
# CONFIG_RTC_DRV_ABB5ZES3 is not set
# CONFIG_RTC_DRV_ABEOZ9 is not set
# CONFIG_RTC_DRV_ABX80X is not set
# CONFIG_RTC_DRV_DS1307 is not set
# CONFIG_RTC_DRV_DS1374 is not set
# CONFIG_RTC_DRV_DS1672 is not set
# CONFIG_RTC_DRV_HYM8563 is not set
# CONFIG_RTC_DRV_MAX6900 is not set
# CONFIG_RTC_DRV_MAX31335 is not set
# CONFIG_RTC_DRV_NCT3018Y is not set
# CONFIG_RTC_DRV_RS5C372 is not set
# CONFIG_RTC_DRV_ISL1208 is not set
# CONFIG_RTC_DRV_ISL12022 is not set
# CONFIG_RTC_DRV_ISL12026 is not set
# CONFIG_RTC_DRV_X1205 is not set
# CONFIG_RTC_DRV_PCF8523 is not set
# CONFIG_RTC_DRV_PCF85363 is not set
# CONFIG_RTC_DRV_PCF8563 is not set
# CONFIG_RTC_DRV_PCF8583 is not set
# CONFIG_RTC_DRV_M41T80 is not set
# CONFIG_RTC_DRV_BQ32K is not set
# CONFIG_RTC_DRV_TWL4030 is not set
# CONFIG_RTC_DRV_S35390A is not set
# CONFIG_RTC_DRV_FM3130 is not set
# CONFIG_RTC_DRV_RX8010 is not set
# CONFIG_RTC_DRV_RX8111 is not set
# CONFIG_RTC_DRV_RX8581 is not set
# CONFIG_RTC_DRV_RX8025 is not set
# CONFIG_RTC_DRV_EM3027 is not set
# CONFIG_RTC_DRV_RV3028 is not set
# CONFIG_RTC_DRV_RV3032 is not set
# CONFIG_RTC_DRV_RV8803 is not set
# CONFIG_RTC_DRV_SD2405AL is not set
# CONFIG_RTC_DRV_SD3078 is not set

#
# SPI RTC drivers
#
# CONFIG_RTC_DRV_M41T93 is not set
# CONFIG_RTC_DRV_M41T94 is not set
# CONFIG_RTC_DRV_DS1302 is not set
# CONFIG_RTC_DRV_DS1305 is not set
# CONFIG_RTC_DRV_DS1343 is not set
# CONFIG_RTC_DRV_DS1347 is not set
# CONFIG_RTC_DRV_DS1390 is not set
# CONFIG_RTC_DRV_MAX6916 is not set
# CONFIG_RTC_DRV_R9701 is not set
# CONFIG_RTC_DRV_RX4581 is not set
# CONFIG_RTC_DRV_RS5C348 is not set
# CONFIG_RTC_DRV_MAX6902 is not set
# CONFIG_RTC_DRV_PCF2123 is not set
# CONFIG_RTC_DRV_MCP795 is not set
CONFIG_RTC_I2C_AND_SPI=y

#
# SPI and I2C RTC drivers
#
# CONFIG_RTC_DRV_DS3232 is not set
# CONFIG_RTC_DRV_PCF2127 is not set
# CONFIG_RTC_DRV_PCF85063 is not set
# CONFIG_RTC_DRV_RV3029C2 is not set
# CONFIG_RTC_DRV_RX6110 is not set

#
# Platform RTC drivers
#
CONFIG_RTC_DRV_CMOS=y
# CONFIG_RTC_DRV_DS1286 is not set
# CONFIG_RTC_DRV_DS1511 is not set
# CONFIG_RTC_DRV_DS1553 is not set
# CONFIG_RTC_DRV_DS1685_FAMILY is not set
# CONFIG_RTC_DRV_DS1742 is not set
# CONFIG_RTC_DRV_DS2404 is not set
# CONFIG_RTC_DRV_STK17TA8 is not set
# CONFIG_RTC_DRV_M48T86 is not set
# CONFIG_RTC_DRV_M48T35 is not set
# CONFIG_RTC_DRV_M48T59 is not set
# CONFIG_RTC_DRV_MSM6242 is not set
# CONFIG_RTC_DRV_RP5C01 is not set
# CONFIG_RTC_DRV_ZYNQMP is not set

#
# on-CPU RTC drivers
#
# CONFIG_RTC_DRV_CADENCE is not set
# CONFIG_RTC_DRV_FTRTC010 is not set
# CONFIG_RTC_DRV_R7301 is not set
# CONFIG_RTC_DRV_GOLDFISH is not set

#
# HID Sensor RTC drivers
#
CONFIG_RTC_DRV_HID_SENSOR_TIME=y
CONFIG_DMADEVICES=y
# CONFIG_DMADEVICES_DEBUG is not set

#
# DMA Devices
#
CONFIG_DMA_ENGINE=y
CONFIG_DMA_VIRTUAL_CHANNELS=y
CONFIG_DMA_ACPI=y
CONFIG_DMA_OF=y
# CONFIG_ALTERA_MSGDMA is not set
# CONFIG_DW_AXI_DMAC is not set
# CONFIG_FSL_EDMA is not set
CONFIG_INTEL_IDMA64=y
# CONFIG_INTEL_IDXD is not set
# CONFIG_INTEL_IDXD_COMPAT is not set
CONFIG_INTEL_IOATDMA=y
# CONFIG_PLX_DMA is not set
# CONFIG_SWITCHTEC_DMA is not set
# CONFIG_XILINX_DMA is not set
# CONFIG_XILINX_XDMA is not set
# CONFIG_XILINX_ZYNQMP_DPDMA is not set
# CONFIG_AMD_PTDMA is not set
# CONFIG_AMD_QDMA is not set
# CONFIG_QCOM_HIDMA_MGMT is not set
# CONFIG_QCOM_HIDMA is not set
CONFIG_DW_DMAC_CORE=y
# CONFIG_DW_DMAC is not set
# CONFIG_DW_DMAC_PCI is not set
# CONFIG_DW_EDMA is not set
CONFIG_HSU_DMA=y
# CONFIG_SF_PDMA is not set
# CONFIG_INTEL_LDMA is not set

#
# DMA Clients
#
CONFIG_ASYNC_TX_DMA=y
# CONFIG_DMATEST is not set
CONFIG_DMA_ENGINE_RAID=y

#
# DMABUF options
#
CONFIG_SYNC_FILE=y
CONFIG_SW_SYNC=y
CONFIG_UDMABUF=y
# CONFIG_DMABUF_DEBUG is not set
CONFIG_DMABUF_HEAPS=y
CONFIG_DMABUF_HEAPS_SYSTEM=y
# CONFIG_DMABUF_HEAPS_SYSTEM_CC_SHARED is not set
CONFIG_DMABUF_HEAPS_CMA=y
# end of DMABUF options

CONFIG_DCA=y
# CONFIG_UIO is not set
CONFIG_VFIO=y
CONFIG_VFIO_DEVICE_CDEV=y
# CONFIG_VFIO_GROUP is not set
CONFIG_VFIO_VIRQFD=y
# CONFIG_VFIO_DEBUGFS is not set

#
# VFIO support for PCI devices
#
CONFIG_VFIO_PCI_CORE=y
CONFIG_VFIO_PCI_INTX=y
CONFIG_VFIO_PCI=y
# CONFIG_VFIO_PCI_VGA is not set
# CONFIG_VFIO_PCI_IGD is not set
# CONFIG_VIRTIO_VFIO_PCI is not set
# end of VFIO support for PCI devices

CONFIG_IRQ_BYPASS_MANAGER=y
# CONFIG_VIRT_DRIVERS is not set
CONFIG_VIRTIO_ANCHOR=y
CONFIG_VIRTIO=y
CONFIG_VIRTIO_PCI_LIB=y
CONFIG_VIRTIO_PCI_LIB_LEGACY=y
CONFIG_VIRTIO_MENU=y
CONFIG_VIRTIO_PCI=y
CONFIG_VIRTIO_PCI_ADMIN_LEGACY=y
CONFIG_VIRTIO_PCI_LEGACY=y
CONFIG_VIRTIO_VDPA=y
CONFIG_VIRTIO_PMEM=y
CONFIG_VIRTIO_BALLOON=y
CONFIG_VIRTIO_MEM=y
CONFIG_VIRTIO_INPUT=y
CONFIG_VIRTIO_MMIO=y
CONFIG_VIRTIO_MMIO_CMDLINE_DEVICES=y
CONFIG_VIRTIO_DMA_SHARED_BUFFER=y
# CONFIG_VIRTIO_DEBUG is not set
# CONFIG_VIRTIO_RTC is not set
CONFIG_VDPA=y
CONFIG_VDPA_SIM=y
CONFIG_VDPA_SIM_NET=y
CONFIG_VDPA_SIM_BLOCK=y
# CONFIG_VDPA_USER is not set
# CONFIG_IFCVF is not set
# CONFIG_MLX5_VDPA_STEERING_DEBUG is not set
CONFIG_VP_VDPA=y
# CONFIG_ALIBABA_ENI_VDPA is not set
# CONFIG_SNET_VDPA is not set
# CONFIG_OCTEONEP_VDPA is not set
CONFIG_VHOST_IOTLB=y
CONFIG_VHOST_RING=y
CONFIG_VHOST_TASK=y
CONFIG_VHOST=y
CONFIG_VHOST_MENU=y
CONFIG_VHOST_NET=y
# CONFIG_VHOST_SCSI is not set
CONFIG_VHOST_VSOCK=y
CONFIG_VHOST_VDPA=y
CONFIG_VHOST_CROSS_ENDIAN_LEGACY=y
CONFIG_VHOST_ENABLE_FORK_OWNER_CONTROL=y

#
# Microsoft Hyper-V guest support
#
# CONFIG_HYPERV is not set
# end of Microsoft Hyper-V guest support

CONFIG_GREYBUS=y
# CONFIG_GREYBUS_BEAGLEPLAY is not set
CONFIG_GREYBUS_ES2=y
CONFIG_COMEDI=y
# CONFIG_COMEDI_DEBUG is not set
CONFIG_COMEDI_DEFAULT_BUF_SIZE_KB=2048
CONFIG_COMEDI_DEFAULT_BUF_MAXSIZE_KB=20480
CONFIG_COMEDI_MISC_DRIVERS=y
CONFIG_COMEDI_BOND=y
CONFIG_COMEDI_TEST=y
CONFIG_COMEDI_PARPORT=y
CONFIG_COMEDI_ISA_DRIVERS=y
CONFIG_COMEDI_PCL711=y
CONFIG_COMEDI_PCL724=y
CONFIG_COMEDI_PCL726=y
CONFIG_COMEDI_PCL730=y
CONFIG_COMEDI_PCL812=y
CONFIG_COMEDI_PCL816=y
CONFIG_COMEDI_PCL818=y
CONFIG_COMEDI_PCM3724=y
CONFIG_COMEDI_AMPLC_DIO200_ISA=y
CONFIG_COMEDI_AMPLC_PC236_ISA=y
CONFIG_COMEDI_AMPLC_PC263_ISA=y
CONFIG_COMEDI_RTI800=y
CONFIG_COMEDI_RTI802=y
CONFIG_COMEDI_DAC02=y
CONFIG_COMEDI_DAS16M1=y
CONFIG_COMEDI_DAS08_ISA=y
# CONFIG_COMEDI_DAS16 is not set
CONFIG_COMEDI_DAS800=y
CONFIG_COMEDI_DAS1800=y
CONFIG_COMEDI_DAS6402=y
CONFIG_COMEDI_DT2801=y
CONFIG_COMEDI_DT2811=y
CONFIG_COMEDI_DT2814=y
CONFIG_COMEDI_DT2815=y
CONFIG_COMEDI_DT2817=y
CONFIG_COMEDI_DT282X=y
CONFIG_COMEDI_DMM32AT=y
CONFIG_COMEDI_FL512=y
CONFIG_COMEDI_AIO_AIO12_8=y
CONFIG_COMEDI_AIO_IIRO_16=y
# CONFIG_COMEDI_II_PCI20KC is not set
CONFIG_COMEDI_C6XDIGIO=y
CONFIG_COMEDI_MPC624=y
CONFIG_COMEDI_ADQ12B=y
CONFIG_COMEDI_NI_AT_A2150=y
CONFIG_COMEDI_NI_AT_AO=y
# CONFIG_COMEDI_NI_ATMIO is not set
CONFIG_COMEDI_NI_ATMIO16D=y
CONFIG_COMEDI_NI_LABPC_ISA=y
CONFIG_COMEDI_PCMAD=y
CONFIG_COMEDI_PCMDA12=y
CONFIG_COMEDI_PCMMIO=y
CONFIG_COMEDI_PCMUIO=y
CONFIG_COMEDI_MULTIQ3=y
CONFIG_COMEDI_S526=y
CONFIG_COMEDI_PCI_DRIVERS=y
CONFIG_COMEDI_8255_PCI=y
# CONFIG_COMEDI_ADDI_APCI_1032 is not set
# CONFIG_COMEDI_ADDI_APCI_1500 is not set
# CONFIG_COMEDI_ADDI_APCI_1516 is not set
# CONFIG_COMEDI_ADDI_APCI_1564 is not set
# CONFIG_COMEDI_ADDI_APCI_16XX is not set
# CONFIG_COMEDI_ADDI_APCI_2032 is not set
# CONFIG_COMEDI_ADDI_APCI_2200 is not set
# CONFIG_COMEDI_ADDI_APCI_3120 is not set
# CONFIG_COMEDI_ADDI_APCI_3501 is not set
# CONFIG_COMEDI_ADDI_APCI_3XXX is not set
# CONFIG_COMEDI_ADL_PCI6208 is not set
# CONFIG_COMEDI_ADL_PCI7250 is not set
# CONFIG_COMEDI_ADL_PCI7X3X is not set
# CONFIG_COMEDI_ADL_PCI8164 is not set
# CONFIG_COMEDI_ADL_PCI9111 is not set
CONFIG_COMEDI_ADL_PCI9118=y
# CONFIG_COMEDI_ADV_PCI1710 is not set
# CONFIG_COMEDI_ADV_PCI1720 is not set
# CONFIG_COMEDI_ADV_PCI1723 is not set
# CONFIG_COMEDI_ADV_PCI1724 is not set
# CONFIG_COMEDI_ADV_PCI1760 is not set
# CONFIG_COMEDI_ADV_PCI_DIO is not set
# CONFIG_COMEDI_AMPLC_DIO200_PCI is not set
# CONFIG_COMEDI_AMPLC_PC236_PCI is not set
# CONFIG_COMEDI_AMPLC_PC263_PCI is not set
# CONFIG_COMEDI_AMPLC_PCI224 is not set
# CONFIG_COMEDI_AMPLC_PCI230 is not set
# CONFIG_COMEDI_CONTEC_PCI_DIO is not set
# CONFIG_COMEDI_DAS08_PCI is not set
# CONFIG_COMEDI_DT3000 is not set
# CONFIG_COMEDI_DYNA_PCI10XX is not set
# CONFIG_COMEDI_GSC_HPDI is not set
# CONFIG_COMEDI_MF6X4 is not set
# CONFIG_COMEDI_ICP_MULTI is not set
# CONFIG_COMEDI_DAQBOARD2000 is not set
# CONFIG_COMEDI_JR3_PCI is not set
# CONFIG_COMEDI_KE_COUNTER is not set
# CONFIG_COMEDI_CB_PCIDAS64 is not set
# CONFIG_COMEDI_CB_PCIDAS is not set
# CONFIG_COMEDI_CB_PCIDDA is not set
# CONFIG_COMEDI_CB_PCIMDAS is not set
# CONFIG_COMEDI_CB_PCIMDDA is not set
# CONFIG_COMEDI_ME4000 is not set
# CONFIG_COMEDI_ME_DAQ is not set
# CONFIG_COMEDI_NI_6527 is not set
# CONFIG_COMEDI_NI_65XX is not set
# CONFIG_COMEDI_NI_660X is not set
# CONFIG_COMEDI_NI_670X is not set
CONFIG_COMEDI_NI_LABPC_PCI=y
# CONFIG_COMEDI_NI_PCIDIO is not set
# CONFIG_COMEDI_NI_PCIMIO is not set
# CONFIG_COMEDI_RTD520 is not set
# CONFIG_COMEDI_S626 is not set
CONFIG_COMEDI_PCMCIA_DRIVERS=y
# CONFIG_COMEDI_CB_DAS16_CS is not set
# CONFIG_COMEDI_DAS08_CS is not set
CONFIG_COMEDI_NI_DAQ_700_CS=y
# CONFIG_COMEDI_NI_DAQ_DIO24_CS is not set
CONFIG_COMEDI_NI_LABPC_CS=y
# CONFIG_COMEDI_NI_MIO_CS is not set
# CONFIG_COMEDI_QUATECH_DAQP_CS is not set
CONFIG_COMEDI_USB_DRIVERS=y
CONFIG_COMEDI_DT9812=y
CONFIG_COMEDI_NI_USB6501=y
CONFIG_COMEDI_USBDUX=y
CONFIG_COMEDI_USBDUXFAST=y
CONFIG_COMEDI_USBDUXSIGMA=y
CONFIG_COMEDI_VMK80XX=y
CONFIG_COMEDI_8254=y
CONFIG_COMEDI_8255=y
CONFIG_COMEDI_8255_SA=y
CONFIG_COMEDI_KCOMEDILIB=y
CONFIG_COMEDI_AMPLC_DIO200=y
CONFIG_COMEDI_AMPLC_PC236=y
CONFIG_COMEDI_DAS08=y
CONFIG_COMEDI_ISADMA=y
CONFIG_COMEDI_NI_LABPC=y
CONFIG_COMEDI_NI_LABPC_ISADMA=y
# CONFIG_COMEDI_TESTS is not set
# CONFIG_GPIB is not set
CONFIG_STAGING=y
# CONFIG_RTL8723BS is not set

#
# IIO staging drivers
#

#
# Accelerometers
#
# CONFIG_ADIS16203 is not set
# end of Accelerometers

#
# Analog to digital converters
#
# CONFIG_AD7816 is not set
# end of Analog to digital converters

#
# Analog digital bi-direction converters
#
# CONFIG_ADT7316 is not set
# end of Analog digital bi-direction converters

#
# Direct Digital Synthesis
#
# CONFIG_AD9832 is not set
# CONFIG_AD9834 is not set
# end of Direct Digital Synthesis

#
# Network Analyzer, Impedance Converters
#
# CONFIG_AD5933 is not set
# end of Network Analyzer, Impedance Converters
# end of IIO staging drivers

# CONFIG_FB_SM750 is not set
# CONFIG_STAGING_MEDIA is not set
# CONFIG_FB_TFT is not set
# CONFIG_MOST_COMPONENTS is not set
# CONFIG_GREYBUS_AUDIO is not set
# CONFIG_GREYBUS_BOOTROM is not set
# CONFIG_GREYBUS_FIRMWARE is not set
CONFIG_GREYBUS_HID=y
# CONFIG_GREYBUS_LOG is not set
# CONFIG_GREYBUS_LOOPBACK is not set
# CONFIG_GREYBUS_POWER is not set
# CONFIG_GREYBUS_RAW is not set
# CONFIG_GREYBUS_VIBRATOR is not set
CONFIG_GREYBUS_BRIDGED_PHY=y
# CONFIG_GREYBUS_GPIO is not set
# CONFIG_GREYBUS_I2C is not set
# CONFIG_GREYBUS_SDIO is not set
# CONFIG_GREYBUS_SPI is not set
# CONFIG_GREYBUS_UART is not set
CONFIG_GREYBUS_USB=y
# CONFIG_XIL_AXIS_FIFO is not set
# CONFIG_VME_BUS is not set
# CONFIG_GOLDFISH is not set
# CONFIG_CHROME_PLATFORMS is not set
# CONFIG_MELLANOX_PLATFORM is not set
CONFIG_SURFACE_PLATFORMS=y
# CONFIG_SURFACE3_WMI is not set
# CONFIG_SURFACE_3_POWER_OPREGION is not set
# CONFIG_SURFACE_ACPI_NOTIFY is not set
# CONFIG_SURFACE_AGGREGATOR_CDEV is not set
# CONFIG_SURFACE_AGGREGATOR_HUB is not set
CONFIG_SURFACE_AGGREGATOR_REGISTRY=y
# CONFIG_SURFACE_AGGREGATOR_TABLET_SWITCH is not set
# CONFIG_SURFACE_DTX is not set
# CONFIG_SURFACE_GPE is not set
# CONFIG_SURFACE_HOTPLUG is not set
# CONFIG_SURFACE_PLATFORM_PROFILE is not set
# CONFIG_SURFACE_PRO3_BUTTON is not set
CONFIG_SURFACE_AGGREGATOR=y
CONFIG_SURFACE_AGGREGATOR_BUS=y
CONFIG_X86_PLATFORM_DEVICES=y
CONFIG_WMI_BMOF=y
# CONFIG_HUAWEI_WMI is not set
# CONFIG_X86_PLATFORM_DRIVERS_UNIWILL is not set
# CONFIG_MXM_WMI is not set
# CONFIG_NVIDIA_WMI_EC_BACKLIGHT is not set
# CONFIG_XIAOMI_WMI is not set
# CONFIG_REDMI_WMI is not set
# CONFIG_GIGABYTE_WMI is not set
# CONFIG_BITLAND_MIFS_WMI is not set
# CONFIG_ACERHDF is not set
# CONFIG_ACER_WIRELESS is not set
# CONFIG_ACER_WMI is not set

#
# AMD HSMP Driver
#
# CONFIG_AMD_HSMP_ACPI is not set
# CONFIG_AMD_HSMP_PLAT is not set
# end of AMD HSMP Driver

# CONFIG_AMD_PMC is not set
# CONFIG_AMD_HFI is not set
# CONFIG_AMD_3D_VCACHE is not set
# CONFIG_AMD_WBRF is not set
# CONFIG_AMD_ISP_PLATFORM is not set
# CONFIG_ADV_SWBUTTON is not set
# CONFIG_APPLE_GMUX is not set
# CONFIG_ASUS_LAPTOP is not set
# CONFIG_ASUS_WIRELESS is not set
# CONFIG_ASUS_ARMOURY is not set
CONFIG_ASUS_WMI=y
# CONFIG_ASUS_WMI_DEPRECATED_ATTRS is not set
# CONFIG_ASUS_NB_WMI is not set
CONFIG_ASUS_TF103C_DOCK=y
# CONFIG_AYANEO_EC is not set
CONFIG_EEEPC_LAPTOP=y
# CONFIG_EEEPC_WMI is not set
# CONFIG_X86_PLATFORM_DRIVERS_DELL is not set
# CONFIG_AMILO_RFKILL is not set
# CONFIG_FUJITSU_LAPTOP is not set
# CONFIG_FUJITSU_TABLET is not set
# CONFIG_GPD_POCKET_FAN is not set
# CONFIG_X86_PLATFORM_DRIVERS_HP is not set
# CONFIG_WIRELESS_HOTKEY is not set
# CONFIG_IBM_RTL is not set
# CONFIG_SENSORS_HDAPS is not set
# CONFIG_INTEL_ATOMISP2_PM is not set
# CONFIG_INTEL_IFS is not set
# CONFIG_INTEL_SAR_INT1092 is not set
# CONFIG_INTEL_SKL_INT3472 is not set

#
# Intel Speed Select Technology interface support
#
# CONFIG_INTEL_SPEED_SELECT_INTERFACE is not set
# end of Intel Speed Select Technology interface support

# CONFIG_INTEL_WMI_SBL_FW_UPDATE is not set
# CONFIG_INTEL_WMI_THUNDERBOLT is not set

#
# Intel Uncore Frequency Control
#
# CONFIG_INTEL_UNCORE_FREQ_CONTROL is not set
# end of Intel Uncore Frequency Control

# CONFIG_INTEL_HID_EVENT is not set
# CONFIG_INTEL_VBTN is not set
# CONFIG_INTEL_EHL_PSE_IO is not set
# CONFIG_INTEL_INT0002_VGPIO is not set
# CONFIG_INTEL_OAKTRAIL is not set
# CONFIG_INTEL_BXTWC_PMIC_TMU is not set
CONFIG_INTEL_CHTWC_INT33FE=y
CONFIG_INTEL_ISHTP_ECLITE=y
# CONFIG_INTEL_PUNIT_IPC is not set
# CONFIG_INTEL_RST is not set
# CONFIG_INTEL_SMARTCONNECT is not set
# CONFIG_INTEL_TURBO_MAX_3 is not set
# CONFIG_INTEL_VSEC is not set
# CONFIG_IDEAPAD_LAPTOP is not set
# CONFIG_LENOVO_WMI_HOTKEY_UTILITIES is not set
# CONFIG_LENOVO_WMI_CAMERA is not set
# CONFIG_THINKPAD_ACPI is not set
# CONFIG_THINKPAD_LMI is not set
# CONFIG_YOGABOOK is not set
# CONFIG_YT2_1380 is not set
# CONFIG_LENOVO_WMI_GAMEZONE is not set
# CONFIG_LENOVO_WMI_TUNING is not set
# CONFIG_ACPI_QUICKSTART is not set
# CONFIG_MEEGOPAD_ANX7428 is not set
# CONFIG_MSI_EC is not set
# CONFIG_MSI_LAPTOP is not set
# CONFIG_MSI_WMI is not set
# CONFIG_MSI_WMI_PLATFORM is not set
# CONFIG_PCENGINES_APU2 is not set
# CONFIG_PORTWELL_EC is not set
# CONFIG_BARCO_P50_GPIO is not set
# CONFIG_SAMSUNG_GALAXYBOOK is not set
# CONFIG_SAMSUNG_LAPTOP is not set
# CONFIG_SAMSUNG_Q10 is not set
# CONFIG_ACPI_TOSHIBA is not set
# CONFIG_TOSHIBA_BT_RFKILL is not set
# CONFIG_TOSHIBA_HAPS is not set
# CONFIG_TOSHIBA_WMI is not set
# CONFIG_ACPI_CMPC is not set
# CONFIG_COMPAL_LAPTOP is not set
# CONFIG_LG_LAPTOP is not set
# CONFIG_PANASONIC_LAPTOP is not set
# CONFIG_SONY_LAPTOP is not set
# CONFIG_SYSTEM76_ACPI is not set
# CONFIG_TOPSTAR_LAPTOP is not set
# CONFIG_SERIAL_MULTI_INSTANTIATE is not set
# CONFIG_INSPUR_PLATFORM_PROFILE is not set
# CONFIG_DASHARO_ACPI is not set
# CONFIG_INTEL_IPS is not set
CONFIG_INTEL_SCU_IPC=y
# CONFIG_INTEL_SCU_PCI is not set
# CONFIG_INTEL_SCU_PLATFORM is not set
# CONFIG_SIEMENS_SIMATIC_IPC is not set
# CONFIG_SILICOM_PLATFORM is not set
# CONFIG_WINMATE_FM07_KEYS is not set
# CONFIG_OXP_EC is not set
# CONFIG_TUXEDO_NB04_WMI_AB is not set
CONFIG_P2SB=y
CONFIG_ACPI_WMI=y
# CONFIG_ACPI_WMI_LEGACY_DEVICE_NAMES is not set
CONFIG_HAVE_CLK=y
CONFIG_HAVE_CLK_PREPARE=y
CONFIG_COMMON_CLK=y
# CONFIG_LMK04832 is not set
# CONFIG_COMMON_CLK_MAX9485 is not set
# CONFIG_COMMON_CLK_SI5341 is not set
# CONFIG_COMMON_CLK_SI5351 is not set
# CONFIG_COMMON_CLK_SI514 is not set
# CONFIG_COMMON_CLK_SI544 is not set
# CONFIG_COMMON_CLK_SI570 is not set
# CONFIG_COMMON_CLK_CDCE706 is not set
# CONFIG_COMMON_CLK_CDCE925 is not set
# CONFIG_COMMON_CLK_CS2000_CP is not set
# CONFIG_CLK_TWL is not set
# CONFIG_COMMON_CLK_AXI_CLKGEN is not set
# CONFIG_COMMON_CLK_RS9_PCIE is not set
# CONFIG_COMMON_CLK_SI521XX is not set
# CONFIG_COMMON_CLK_VC3 is not set
# CONFIG_COMMON_CLK_VC5 is not set
# CONFIG_COMMON_CLK_VC7 is not set
# CONFIG_COMMON_CLK_FIXED_MMIO is not set
# CONFIG_CLK_LGM_CGU is not set
# CONFIG_XILINX_VCU is not set
# CONFIG_COMMON_CLK_XLNX_CLKWZRD is not set
# CONFIG_HWSPINLOCK is not set

#
# Clock Source drivers
#
CONFIG_CLKEVT_I8253=y
CONFIG_I8253_LOCK=y
CONFIG_CLKBLD_I8253=y
# end of Clock Source drivers

CONFIG_MAILBOX=y
# CONFIG_PLATFORM_MHU is not set
CONFIG_PCC=y
# CONFIG_ALTERA_MBOX is not set
# CONFIG_MAILBOX_TEST is not set
CONFIG_IOMMU_IOVA=y
CONFIG_IOMMU_API=y
CONFIG_IOMMUFD_DRIVER=y
CONFIG_IOMMU_SUPPORT=y

#
# Generic IOMMU Pagetable Support
#
# end of Generic IOMMU Pagetable Support

# CONFIG_IOMMU_DEBUGFS is not set
# CONFIG_IOMMU_DEFAULT_DMA_STRICT is not set
CONFIG_IOMMU_DEFAULT_DMA_LAZY=y
# CONFIG_IOMMU_DEFAULT_PASSTHROUGH is not set
CONFIG_OF_IOMMU=y
CONFIG_IOMMU_DMA=y
CONFIG_IOMMU_SVA=y
CONFIG_IOMMU_IOPF=y
CONFIG_AMD_IOMMU=y
# CONFIG_AMD_IOMMU_IOMMUFD is not set
CONFIG_DMAR_TABLE=y
CONFIG_INTEL_IOMMU=y
CONFIG_INTEL_IOMMU_SVM=y
CONFIG_INTEL_IOMMU_DEFAULT_ON=y
CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON=y
CONFIG_INTEL_IOMMU_PERF_EVENTS=y
CONFIG_IOMMUFD_DRIVER_CORE=y
CONFIG_IOMMUFD=y
CONFIG_IOMMUFD_TEST=y
CONFIG_IRQ_REMAP=y
# CONFIG_VIRTIO_IOMMU is not set
CONFIG_GENERIC_PT=y
CONFIG_DEBUG_GENERIC_PT=y
CONFIG_IOMMU_PT=y
CONFIG_IOMMU_PT_AMDV1=y
CONFIG_IOMMU_PT_VTDSS=y
# CONFIG_IOMMU_PT_RISCV64 is not set
CONFIG_IOMMU_PT_X86_64=y

#
# Remoteproc drivers
#
# CONFIG_REMOTEPROC is not set
# end of Remoteproc drivers

#
# Rpmsg drivers
#
# CONFIG_RPMSG_QCOM_GLINK_RPM is not set
# CONFIG_RPMSG_VIRTIO is not set
# end of Rpmsg drivers

CONFIG_SOUNDWIRE=y

#
# SoundWire Devices
#
# CONFIG_SOUNDWIRE_AMD is not set
# CONFIG_SOUNDWIRE_INTEL is not set
# CONFIG_SOUNDWIRE_QCOM is not set

#
# SOC (System On Chip) specific Drivers
#

#
# Amlogic SoC drivers
#
# end of Amlogic SoC drivers

#
# Broadcom SoC drivers
#
# end of Broadcom SoC drivers

#
# NXP/Freescale QorIQ SoC drivers
#
# end of NXP/Freescale QorIQ SoC drivers

#
# fujitsu SoC drivers
#
# end of fujitsu SoC drivers

#
# i.MX SoC drivers
#
# end of i.MX SoC drivers

#
# Enable LiteX SoC Builder specific drivers
#
# CONFIG_LITEX_SOC_CONTROLLER is not set
# end of Enable LiteX SoC Builder specific drivers

# CONFIG_WPCM450_SOC is not set

#
# Qualcomm SoC drivers
#
CONFIG_QCOM_QMI_HELPERS=y
# end of Qualcomm SoC drivers

# CONFIG_SOC_TI is not set

#
# Xilinx SoC drivers
#
# end of Xilinx SoC drivers
# end of SOC (System On Chip) specific Drivers

#
# PM Domains
#

#
# Amlogic PM Domains
#
# end of Amlogic PM Domains

#
# Broadcom PM Domains
#
# end of Broadcom PM Domains

#
# i.MX PM Domains
#
# end of i.MX PM Domains

#
# Qualcomm PM Domains
#
# end of Qualcomm PM Domains
# end of PM Domains

# CONFIG_PM_DEVFREQ is not set
CONFIG_EXTCON=y

#
# Extcon Device Drivers
#
# CONFIG_EXTCON_ADC_JACK is not set
# CONFIG_EXTCON_FSA9480 is not set
# CONFIG_EXTCON_GPIO is not set
# CONFIG_EXTCON_INTEL_INT3496 is not set
CONFIG_EXTCON_INTEL_CHT_WC=y
# CONFIG_EXTCON_LC824206XA is not set
# CONFIG_EXTCON_MAX3355 is not set
# CONFIG_EXTCON_MAX14526 is not set
CONFIG_EXTCON_PTN5150=y
# CONFIG_EXTCON_RT8973A is not set
# CONFIG_EXTCON_SM5502 is not set
# CONFIG_EXTCON_USB_GPIO is not set
CONFIG_EXTCON_USBC_TUSB320=y
# CONFIG_MEMORY is not set
CONFIG_IIO=y
CONFIG_IIO_BUFFER=y
# CONFIG_IIO_BUFFER_CB is not set
# CONFIG_IIO_BUFFER_DMA is not set
# CONFIG_IIO_BUFFER_DMAENGINE is not set
# CONFIG_IIO_BUFFER_HW_CONSUMER is not set
CONFIG_IIO_KFIFO_BUF=y
CONFIG_IIO_TRIGGERED_BUFFER=y
# CONFIG_IIO_CONFIGFS is not set
CONFIG_IIO_TRIGGER=y
CONFIG_IIO_CONSUMERS_PER_TRIGGER=2
# CONFIG_IIO_SW_DEVICE is not set
# CONFIG_IIO_SW_TRIGGER is not set
# CONFIG_IIO_TRIGGERED_EVENT is not set

#
# Accelerometers
#
# CONFIG_ADIS16201 is not set
# CONFIG_ADIS16209 is not set
# CONFIG_ADXL313_I2C is not set
# CONFIG_ADXL313_SPI is not set
# CONFIG_ADXL345_I2C is not set
# CONFIG_ADXL345_SPI is not set
# CONFIG_ADXL355_I2C is not set
# CONFIG_ADXL355_SPI is not set
# CONFIG_ADXL367_SPI is not set
# CONFIG_ADXL367_I2C is not set
# CONFIG_ADXL372_SPI is not set
# CONFIG_ADXL372_I2C is not set
# CONFIG_ADXL380_SPI is not set
# CONFIG_ADXL380_I2C is not set
# CONFIG_BMA180 is not set
# CONFIG_BMA220 is not set
# CONFIG_BMA400 is not set
# CONFIG_BMC150_ACCEL is not set
# CONFIG_BMI088_ACCEL is not set
# CONFIG_DA280 is not set
# CONFIG_DA311 is not set
# CONFIG_DMARD06 is not set
# CONFIG_DMARD09 is not set
# CONFIG_DMARD10 is not set
# CONFIG_FXLS8962AF_I2C is not set
# CONFIG_FXLS8962AF_SPI is not set
CONFIG_HID_SENSOR_ACCEL_3D=y
# CONFIG_IIO_ST_ACCEL_3AXIS is not set
# CONFIG_IIO_KX022A_SPI is not set
# CONFIG_IIO_KX022A_I2C is not set
# CONFIG_KXSD9 is not set
# CONFIG_KXCJK1013 is not set
# CONFIG_MC3230 is not set
# CONFIG_MMA7455_I2C is not set
# CONFIG_MMA7455_SPI is not set
# CONFIG_MMA7660 is not set
# CONFIG_MMA8452 is not set
# CONFIG_MMA9551 is not set
# CONFIG_MMA9553 is not set
# CONFIG_MSA311 is not set
# CONFIG_MXC4005 is not set
# CONFIG_MXC6255 is not set
# CONFIG_SCA3000 is not set
# CONFIG_SCA3300 is not set
# CONFIG_STK8312 is not set
# CONFIG_STK8BA50 is not set
# end of Accelerometers

#
# Analog to digital converters
#
# CONFIG_AD4000 is not set
# CONFIG_AD4080 is not set
# CONFIG_AD4130 is not set
# CONFIG_AD4134 is not set
# CONFIG_AD4170_4 is not set
# CONFIG_AD4691 is not set
# CONFIG_AD4695 is not set
# CONFIG_AD7091R5 is not set
# CONFIG_AD7091R8 is not set
# CONFIG_AD7124 is not set
# CONFIG_AD7173 is not set
# CONFIG_AD7191 is not set
# CONFIG_AD7192 is not set
# CONFIG_AD7266 is not set
# CONFIG_AD7280 is not set
# CONFIG_AD7291 is not set
# CONFIG_AD7292 is not set
# CONFIG_AD7298 is not set
# CONFIG_AD7380 is not set
# CONFIG_AD7476 is not set
# CONFIG_AD7606_IFACE_PARALLEL is not set
# CONFIG_AD7606_IFACE_SPI is not set
# CONFIG_AD7766 is not set
# CONFIG_AD7768_1 is not set
# CONFIG_AD7779 is not set
# CONFIG_AD7780 is not set
# CONFIG_AD7791 is not set
# CONFIG_AD7793 is not set
# CONFIG_AD7887 is not set
# CONFIG_AD7923 is not set
# CONFIG_AD7944 is not set
# CONFIG_AD7949 is not set
# CONFIG_AD799X is not set
# CONFIG_AD9467 is not set
# CONFIG_ADE9000 is not set
# CONFIG_CC10001_ADC is not set
CONFIG_DLN2_ADC=y
# CONFIG_ENVELOPE_DETECTOR is not set
# CONFIG_GEHC_PMC_ADC is not set
# CONFIG_HI8435 is not set
# CONFIG_HX711 is not set
# CONFIG_INA2XX_ADC is not set
# CONFIG_LTC2309 is not set
# CONFIG_LTC2471 is not set
# CONFIG_LTC2485 is not set
# CONFIG_LTC2496 is not set
# CONFIG_LTC2497 is not set
# CONFIG_MAX1027 is not set
# CONFIG_MAX11100 is not set
# CONFIG_MAX1118 is not set
# CONFIG_MAX11205 is not set
# CONFIG_MAX11410 is not set
# CONFIG_MAX1241 is not set
# CONFIG_MAX1363 is not set
# CONFIG_MAX14001 is not set
# CONFIG_MAX34408 is not set
# CONFIG_MAX9611 is not set
# CONFIG_MCP320X is not set
# CONFIG_MCP3422 is not set
# CONFIG_MCP3564 is not set
# CONFIG_MCP3911 is not set
# CONFIG_MEDIATEK_MT6360_ADC is not set
# CONFIG_MEDIATEK_MT6370_ADC is not set
# CONFIG_NAU7802 is not set
# CONFIG_NCT7201 is not set
# CONFIG_PAC1921 is not set
# CONFIG_PAC1934 is not set
# CONFIG_ROHM_BD79112 is not set
# CONFIG_ROHM_BD79124 is not set
# CONFIG_RICHTEK_RTQ6056 is not set
# CONFIG_SD_ADC_MODULATOR is not set
# CONFIG_TI_ADC081C is not set
# CONFIG_TI_ADC0832 is not set
# CONFIG_TI_ADC084S021 is not set
# CONFIG_TI_ADC108S102 is not set
# CONFIG_TI_ADC12138 is not set
# CONFIG_TI_ADC128S052 is not set
# CONFIG_TI_ADC161S626 is not set
# CONFIG_TI_ADS1015 is not set
# CONFIG_TI_ADS1018 is not set
# CONFIG_TI_ADS1100 is not set
# CONFIG_TI_ADS1119 is not set
# CONFIG_TI_ADS124S08 is not set
# CONFIG_TI_ADS1298 is not set
# CONFIG_TI_ADS131E08 is not set
# CONFIG_TI_ADS131M02 is not set
# CONFIG_TI_ADS7138 is not set
# CONFIG_TI_ADS7924 is not set
# CONFIG_TI_ADS7950 is not set
# CONFIG_TI_ADS8344 is not set
# CONFIG_TI_ADS8688 is not set
# CONFIG_TI_LMP92064 is not set
# CONFIG_TI_TLC4541 is not set
# CONFIG_TI_TSC2046 is not set
# CONFIG_TWL4030_MADC is not set
# CONFIG_TWL6030_GPADC is not set
# CONFIG_VF610_ADC is not set
CONFIG_VIPERBOARD_ADC=y
# CONFIG_XILINX_XADC is not set
# end of Analog to digital converters

#
# Analog to digital and digital to analog converters
#
# CONFIG_AD74115 is not set
# CONFIG_AD74413R is not set
# end of Analog to digital and digital to analog converters

#
# Analog Front Ends
#
# CONFIG_IIO_RESCALE is not set
# end of Analog Front Ends

#
# Amplifiers
#
# CONFIG_AD8366 is not set
# CONFIG_ADA4250 is not set
# CONFIG_ADL8113 is not set
# CONFIG_HMC425 is not set
# end of Amplifiers

#
# Capacitance to digital converters
#
# CONFIG_AD7150 is not set
# CONFIG_AD7746 is not set
# end of Capacitance to digital converters

#
# Chemical Sensors
#
# CONFIG_AOSONG_AGS02MA is not set
# CONFIG_ATLAS_PH_SENSOR is not set
# CONFIG_ATLAS_EZO_SENSOR is not set
# CONFIG_BME680 is not set
# CONFIG_CCS811 is not set
# CONFIG_ENS160 is not set
# CONFIG_IAQCORE is not set
# CONFIG_MHZ19B is not set
# CONFIG_PMS7003 is not set
# CONFIG_SCD30_CORE is not set
# CONFIG_SCD4X is not set
# CONFIG_SEN0322 is not set
# CONFIG_SENSIRION_SGP30 is not set
# CONFIG_SENSIRION_SGP40 is not set
# CONFIG_SPS30_I2C is not set
# CONFIG_SPS30_SERIAL is not set
# CONFIG_SENSEAIR_SUNRISE_CO2 is not set
# CONFIG_VZ89X is not set
# end of Chemical Sensors

#
# Hid Sensor IIO Common
#
CONFIG_HID_SENSOR_IIO_COMMON=y
CONFIG_HID_SENSOR_IIO_TRIGGER=y
# end of Hid Sensor IIO Common

#
# IIO SCMI Sensors
#
# end of IIO SCMI Sensors

#
# SSP Sensor Common
#
# CONFIG_IIO_SSP_SENSORHUB is not set
# end of SSP Sensor Common

#
# Digital to analog converters
#
# CONFIG_AD3530R is not set
# CONFIG_AD3552R_HS is not set
# CONFIG_AD3552R is not set
# CONFIG_AD5064 is not set
# CONFIG_AD5360 is not set
# CONFIG_AD5380 is not set
# CONFIG_AD5421 is not set
# CONFIG_AD5446_SPI is not set
# CONFIG_AD5446_I2C is not set
# CONFIG_AD5449 is not set
# CONFIG_AD5592R is not set
# CONFIG_AD5593R is not set
# CONFIG_AD5504 is not set
# CONFIG_AD5624R_SPI is not set
# CONFIG_AD5706R is not set
# CONFIG_AD9739A is not set
# CONFIG_LTC2688 is not set
# CONFIG_AD5686_SPI is not set
# CONFIG_AD5696_I2C is not set
# CONFIG_AD5755 is not set
# CONFIG_AD5758 is not set
# CONFIG_AD5761 is not set
# CONFIG_AD5764 is not set
# CONFIG_AD5766 is not set
# CONFIG_AD5770R is not set
# CONFIG_AD5791 is not set
# CONFIG_AD7293 is not set
# CONFIG_AD7303 is not set
# CONFIG_AD8460 is not set
# CONFIG_AD8801 is not set
# CONFIG_BD79703 is not set
# CONFIG_CIO_DAC is not set
# CONFIG_DPOT_DAC is not set
# CONFIG_DS4424 is not set
# CONFIG_LTC1660 is not set
# CONFIG_LTC2632 is not set
# CONFIG_LTC2664 is not set
# CONFIG_M62332 is not set
# CONFIG_MAX517 is not set
# CONFIG_MAX22007 is not set
# CONFIG_MAX5522 is not set
# CONFIG_MAX5821 is not set
# CONFIG_MCP4725 is not set
# CONFIG_MCP4728 is not set
# CONFIG_MCP47FEB02 is not set
# CONFIG_MCP4821 is not set
# CONFIG_MCP4922 is not set
# CONFIG_TI_DAC082S085 is not set
# CONFIG_TI_DAC5571 is not set
# CONFIG_TI_DAC7311 is not set
# CONFIG_TI_DAC7612 is not set
# CONFIG_VF610_DAC is not set
# end of Digital to analog converters

#
# IIO dummy driver
#
# end of IIO dummy driver

#
# Filters
#
# CONFIG_ADMV8818 is not set
# end of Filters

#
# Frequency Synthesizers DDS/PLL
#

#
# Clock Generator/Distribution
#
# CONFIG_AD9523 is not set
# end of Clock Generator/Distribution

#
# Phase-Locked Loop (PLL) frequency synthesizers
#
# CONFIG_ADF4350 is not set
# CONFIG_ADF4371 is not set
# CONFIG_ADF4377 is not set
# CONFIG_ADMFM2000 is not set
# CONFIG_ADMV1013 is not set
# CONFIG_ADMV1014 is not set
# CONFIG_ADMV4420 is not set
# CONFIG_ADRF6780 is not set
# end of Phase-Locked Loop (PLL) frequency synthesizers
# end of Frequency Synthesizers DDS/PLL

#
# Digital gyroscope sensors
#
# CONFIG_ADIS16080 is not set
# CONFIG_ADIS16130 is not set
# CONFIG_ADIS16136 is not set
# CONFIG_ADIS16260 is not set
# CONFIG_ADXRS290 is not set
# CONFIG_ADXRS450 is not set
# CONFIG_BMG160 is not set
# CONFIG_FXAS21002C is not set
CONFIG_HID_SENSOR_GYRO_3D=y
# CONFIG_MPU3050_I2C is not set
# CONFIG_IIO_ST_GYRO_3AXIS is not set
# CONFIG_ITG3200 is not set
# end of Digital gyroscope sensors

#
# Health Sensors
#

#
# Heart Rate Monitors
#
# CONFIG_AFE4403 is not set
# CONFIG_AFE4404 is not set
# CONFIG_MAX30100 is not set
# CONFIG_MAX30102 is not set
# end of Heart Rate Monitors
# end of Health Sensors

#
# Humidity sensors
#
# CONFIG_AM2315 is not set
# CONFIG_DHT11 is not set
# CONFIG_ENS210 is not set
# CONFIG_HDC100X is not set
# CONFIG_HDC2010 is not set
# CONFIG_HDC3020 is not set
CONFIG_HID_SENSOR_HUMIDITY=y
# CONFIG_HTS221 is not set
# CONFIG_HTU21 is not set
# CONFIG_SI7005 is not set
# CONFIG_SI7020 is not set
# end of Humidity sensors

#
# Inertial measurement units
#
# CONFIG_ADIS16400 is not set
# CONFIG_ADIS16460 is not set
# CONFIG_ADIS16475 is not set
# CONFIG_ADIS16480 is not set
# CONFIG_ADIS16550 is not set
# CONFIG_BMI160_I2C is not set
# CONFIG_BMI160_SPI is not set
# CONFIG_BMI270_I2C is not set
# CONFIG_BMI270_SPI is not set
# CONFIG_BMI323_I2C is not set
# CONFIG_BMI323_SPI is not set
# CONFIG_BOSCH_BNO055_SERIAL is not set
# CONFIG_BOSCH_BNO055_I2C is not set
# CONFIG_FXOS8700_I2C is not set
# CONFIG_FXOS8700_SPI is not set
# CONFIG_KMX61 is not set
# CONFIG_INV_ICM42600_I2C is not set
# CONFIG_INV_ICM42600_SPI is not set
# CONFIG_INV_ICM45600_I2C is not set
# CONFIG_INV_ICM45600_SPI is not set
# CONFIG_INV_MPU6050_I2C is not set
# CONFIG_INV_MPU6050_SPI is not set
# CONFIG_SMI240 is not set
# CONFIG_SMI330_I2C is not set
# CONFIG_SMI330_SPI is not set
# CONFIG_IIO_ST_LSM6DSX is not set
# CONFIG_IIO_ST_LSM9DS0 is not set
# end of Inertial measurement units

#
# Light sensors
#
# CONFIG_ACPI_ALS is not set
# CONFIG_ADJD_S311 is not set
# CONFIG_ADUX1020 is not set
# CONFIG_AL3000A is not set
# CONFIG_AL3010 is not set
# CONFIG_AL3320A is not set
# CONFIG_APDS9160 is not set
# CONFIG_APDS9300 is not set
# CONFIG_APDS9306 is not set
# CONFIG_APDS9960 is not set
# CONFIG_APDS9999 is not set
# CONFIG_AS73211 is not set
# CONFIG_BH1745 is not set
# CONFIG_BH1750 is not set
# CONFIG_BH1780 is not set
# CONFIG_CM32181 is not set
# CONFIG_CM3232 is not set
# CONFIG_CM3323 is not set
# CONFIG_CM3605 is not set
# CONFIG_CM36651 is not set
# CONFIG_GP2AP002 is not set
# CONFIG_GP2AP020A00F is not set
# CONFIG_SENSORS_ISL29018 is not set
# CONFIG_SENSORS_ISL29028 is not set
# CONFIG_ISL29125 is not set
# CONFIG_ISL76682 is not set
CONFIG_HID_SENSOR_ALS=y
CONFIG_HID_SENSOR_PROX=y
# CONFIG_JSA1212 is not set
# CONFIG_ROHM_BU27034 is not set
# CONFIG_RPR0521 is not set
# CONFIG_LTR390 is not set
# CONFIG_LTR501 is not set
# CONFIG_LTRF216A is not set
# CONFIG_LV0104CS is not set
# CONFIG_MAX44000 is not set
# CONFIG_MAX44009 is not set
# CONFIG_NOA1305 is not set
# CONFIG_OPT3001 is not set
# CONFIG_OPT4001 is not set
# CONFIG_OPT4060 is not set
# CONFIG_PA12203001 is not set
# CONFIG_SI1133 is not set
# CONFIG_SI1145 is not set
# CONFIG_STK3310 is not set
# CONFIG_ST_UVIS25 is not set
# CONFIG_TCS3414 is not set
# CONFIG_TCS3472 is not set
# CONFIG_SENSORS_TSL2563 is not set
# CONFIG_TSL2583 is not set
# CONFIG_TSL2591 is not set
# CONFIG_TSL2772 is not set
# CONFIG_TSL4531 is not set
# CONFIG_US5182D is not set
# CONFIG_VCNL4000 is not set
# CONFIG_VCNL4035 is not set
# CONFIG_VEML3235 is not set
# CONFIG_VEML3328 is not set
# CONFIG_VEML6030 is not set
# CONFIG_VEML6040 is not set
# CONFIG_VEML6046X00 is not set
# CONFIG_VEML6070 is not set
# CONFIG_VEML6075 is not set
# CONFIG_VL6180 is not set
# CONFIG_ZOPT2201 is not set
# end of Light sensors

#
# Magnetometer sensors
#
# CONFIG_AF8133J is not set
# CONFIG_AK8974 is not set
# CONFIG_AK8975 is not set
# CONFIG_AK09911 is not set
# CONFIG_ALS31300 is not set
# CONFIG_BMC150_MAGN_I2C is not set
# CONFIG_BMC150_MAGN_SPI is not set
# CONFIG_MAG3110 is not set
CONFIG_HID_SENSOR_MAGNETOMETER_3D=y
# CONFIG_MMC35240 is not set
# CONFIG_MMC5633 is not set
# CONFIG_MMC5983 is not set
# CONFIG_IIO_ST_MAGN_3AXIS is not set
# CONFIG_INFINEON_TLV493D is not set
# CONFIG_SENSORS_HMC5843_I2C is not set
# CONFIG_SENSORS_HMC5843_SPI is not set
# CONFIG_SENSORS_RM3100_I2C is not set
# CONFIG_SENSORS_RM3100_SPI is not set
# CONFIG_SI7210 is not set
# CONFIG_TI_TMAG5273 is not set
# CONFIG_YAMAHA_YAS530 is not set
# end of Magnetometer sensors

#
# Multiplexers
#
# CONFIG_IIO_MUX is not set
# end of Multiplexers

#
# Inclinometer sensors
#
CONFIG_HID_SENSOR_INCLINOMETER_3D=y
CONFIG_HID_SENSOR_DEVICE_ROTATION=y
# end of Inclinometer sensors

#
# Triggers - standalone
#
# CONFIG_IIO_SYSFS_TRIGGER is not set
# end of Triggers - standalone

#
# Linear and angular position sensors
#
CONFIG_HID_SENSOR_CUSTOM_INTEL_HINGE=y
# end of Linear and angular position sensors

#
# Digital potentiometers
#
# CONFIG_AD5110 is not set
# CONFIG_AD5272 is not set
# CONFIG_DS1803 is not set
# CONFIG_MAX5432 is not set
# CONFIG_MAX5481 is not set
# CONFIG_MAX5487 is not set
# CONFIG_MCP4018 is not set
# CONFIG_MCP4131 is not set
# CONFIG_MCP4531 is not set
# CONFIG_MCP41010 is not set
# CONFIG_TPL0102 is not set
# CONFIG_X9250 is not set
# end of Digital potentiometers

#
# Digital potentiostats
#
# CONFIG_LMP91000 is not set
# end of Digital potentiostats

#
# Pressure sensors
#
# CONFIG_ABP060MG is not set
# CONFIG_ABP2030PA_I2C is not set
# CONFIG_ABP2030PA_SPI is not set
# CONFIG_ROHM_BM1390 is not set
# CONFIG_BMP280 is not set
# CONFIG_DLHL60D is not set
# CONFIG_DPS310 is not set
CONFIG_HID_SENSOR_PRESS=y
# CONFIG_HP03 is not set
# CONFIG_HSC030PA is not set
# CONFIG_ICP10100 is not set
# CONFIG_MPL115_I2C is not set
# CONFIG_MPL115_SPI is not set
# CONFIG_MPL3115 is not set
# CONFIG_MPRLS0025PA_I2C is not set
# CONFIG_MPRLS0025PA_SPI is not set
# CONFIG_MS5611 is not set
# CONFIG_MS5637 is not set
# CONFIG_SDP500 is not set
# CONFIG_IIO_ST_PRESS is not set
# CONFIG_T5403 is not set
# CONFIG_HP206C is not set
# CONFIG_ZPA2326 is not set
# CONFIG_ADP810 is not set
# end of Pressure sensors

#
# Lightning sensors
#
# CONFIG_AS3935 is not set
# end of Lightning sensors

#
# Proximity and distance sensors
#
# CONFIG_D3323AA is not set
# CONFIG_HX9023S is not set
# CONFIG_IRSD200 is not set
# CONFIG_ISL29501 is not set
# CONFIG_LIDAR_LITE_V2 is not set
# CONFIG_MB1232 is not set
# CONFIG_PING is not set
# CONFIG_RFD77402 is not set
# CONFIG_SRF04 is not set
# CONFIG_SX9310 is not set
# CONFIG_SX9324 is not set
# CONFIG_SX9360 is not set
# CONFIG_SX9500 is not set
# CONFIG_SRF08 is not set
# CONFIG_VCNL3020 is not set
# CONFIG_VL53L0X_I2C is not set
# CONFIG_VL53L1X_I2C is not set
# CONFIG_AW96103 is not set
# end of Proximity and distance sensors

#
# Resolver to digital converters
#
# CONFIG_AD2S90 is not set
# CONFIG_AD2S1200 is not set
# CONFIG_AD2S1210 is not set
# end of Resolver to digital converters

#
# Temperature sensors
#
# CONFIG_LTC2983 is not set
# CONFIG_MAXIM_THERMOCOUPLE is not set
CONFIG_HID_SENSOR_TEMP=y
# CONFIG_MLX90614 is not set
# CONFIG_MLX90632 is not set
# CONFIG_MLX90635 is not set
# CONFIG_TMP006 is not set
# CONFIG_TMP007 is not set
# CONFIG_TMP117 is not set
# CONFIG_TSYS01 is not set
# CONFIG_TSYS02D is not set
# CONFIG_MAX30208 is not set
# CONFIG_MAX31856 is not set
# CONFIG_MAX31865 is not set
# CONFIG_MCP9600 is not set
# end of Temperature sensors

# CONFIG_NTB is not set
# CONFIG_PWM is not set

#
# IRQ chip support
#
CONFIG_IRQCHIP=y
CONFIG_IRQ_MSI_LIB=y
# CONFIG_AL_FIC is not set
# CONFIG_XILINX_INTC is not set
# end of IRQ chip support

# CONFIG_IPACK_BUS is not set
CONFIG_RESET_CONTROLLER=y
# CONFIG_RESET_GPIO is not set
# CONFIG_RESET_INTEL_GW is not set
# CONFIG_RESET_SIMPLE is not set
# CONFIG_RESET_TI_SYSCON is not set
# CONFIG_RESET_TI_TPS380X is not set

#
# PHY Subsystem
#
CONFIG_GENERIC_PHY=y
# CONFIG_PHY_CAN_TRANSCEIVER is not set
CONFIG_PHY_GOOGLE_USB=y
CONFIG_USB_LGM_PHY=y
# CONFIG_PHY_NXP_PTN3222 is not set
# CONFIG_PHY_NXP_TJA1145 is not set

#
# PHY drivers for Broadcom platforms
#
# CONFIG_BCM_KONA_USB2_PHY is not set
# end of PHY drivers for Broadcom platforms

# CONFIG_PHY_CADENCE_TORRENT is not set
# CONFIG_PHY_CADENCE_DPHY is not set
# CONFIG_PHY_CADENCE_DPHY_RX is not set
# CONFIG_PHY_CADENCE_SIERRA is not set
# CONFIG_PHY_CADENCE_SALVO is not set
# CONFIG_PHY_INTEL_LGM_COMBO is not set
# CONFIG_PHY_INTEL_LGM_EMMC is not set
# CONFIG_PHY_PXA_28NM_HSIC is not set
# CONFIG_PHY_PXA_28NM_USB2 is not set
CONFIG_PHY_CPCAP_USB=y
# CONFIG_PHY_MAPPHONE_MDM6600 is not set
# CONFIG_PHY_OCELOT_SERDES is not set
CONFIG_PHY_QCOM_USB_HS=y
CONFIG_PHY_QCOM_USB_HSIC=y
CONFIG_PHY_SAMSUNG_USB2=y
# CONFIG_PHY_TI_DS125DF111 is not set
CONFIG_PHY_TUSB1210=y
# end of PHY Subsystem

# CONFIG_POWERCAP is not set
# CONFIG_MCB is not set

#
# Performance monitor support
#
# CONFIG_DWC_PCIE_PMU is not set
# end of Performance monitor support

CONFIG_RAS=y
CONFIG_USB4=y
CONFIG_USB4_CONFIGFS=y
# CONFIG_USB4_DEBUGFS_WRITE is not set
# CONFIG_USB4_DMA_TEST is not set
# CONFIG_USB4_STREAM is not set

#
# Android
#
CONFIG_ANDROID_BINDER_IPC=y
CONFIG_ANDROID_BINDERFS=y
CONFIG_ANDROID_BINDER_DEVICES="binder0,binder1"
# end of Android

CONFIG_LIBNVDIMM=y
CONFIG_BLK_DEV_PMEM=y
CONFIG_ND_CLAIM=y
CONFIG_ND_BTT=y
CONFIG_BTT=y
CONFIG_ND_PFN=y
CONFIG_NVDIMM_PFN=y
CONFIG_NVDIMM_DAX=y
CONFIG_OF_PMEM=y
# CONFIG_RAMDAX is not set
CONFIG_NVDIMM_KEYS=y
# CONFIG_NVDIMM_SECURITY_TEST is not set
CONFIG_DAX=y
CONFIG_DEV_DAX=y
# CONFIG_DEV_DAX_PMEM is not set
CONFIG_DEV_DAX_FSDEV=y
# CONFIG_DEV_DAX_KMEM is not set
CONFIG_NVMEM=y
CONFIG_NVMEM_SYSFS=y
CONFIG_NVMEM_LAYOUTS=y

#
# Layout Types
#
# CONFIG_NVMEM_LAYOUT_SL28_VPD is not set
# CONFIG_NVMEM_LAYOUT_ONIE_TLV is not set
# CONFIG_NVMEM_LAYOUT_U_BOOT_ENV is not set
# end of Layout Types

# CONFIG_NVMEM_RMEM is not set
# CONFIG_NVMEM_U_BOOT_ENV is not set

#
# HW tracing support
#
# CONFIG_STM is not set
# CONFIG_INTEL_TH is not set
# end of HW tracing support

# CONFIG_FPGA is not set
# CONFIG_FSI is not set
CONFIG_TEE=y
CONFIG_TEE_DMABUF_HEAPS=y
CONFIG_OPTEE_STATIC_PROTMEM_POOL=y
# CONFIG_MUX_CORE is not set
# CONFIG_SIOX is not set
# CONFIG_SLIMBUS is not set
# CONFIG_INTERCONNECT is not set
CONFIG_COUNTER=y
# CONFIG_INTEL_QEP is not set
# CONFIG_INTERRUPT_CNT is not set
CONFIG_MOST=y
CONFIG_MOST_USB_HDM=y
# CONFIG_MOST_CDEV is not set
# CONFIG_MOST_SND is not set
# CONFIG_PECI is not set
# CONFIG_HTE is not set
# end of Device Drivers

#
# File systems
#
CONFIG_DCACHE_WORD_ACCESS=y
CONFIG_VALIDATE_FS_PARSER=y
CONFIG_FS_IOMAP=y
CONFIG_FS_STACK=y
CONFIG_BUFFER_HEAD=y
CONFIG_LEGACY_DIRECT_IO=y
# CONFIG_EXT2_FS is not set
CONFIG_EXT4_FS=y
CONFIG_EXT4_USE_FOR_EXT2=y
CONFIG_EXT4_FS_POSIX_ACL=y
CONFIG_EXT4_FS_SECURITY=y
# CONFIG_EXT4_DEBUG is not set
CONFIG_JBD2=y
# CONFIG_JBD2_DEBUG is not set
CONFIG_FS_MBCACHE=y
CONFIG_JFS_FS=y
CONFIG_JFS_POSIX_ACL=y
CONFIG_JFS_SECURITY=y
CONFIG_JFS_DEBUG=y
# CONFIG_JFS_STATISTICS is not set
CONFIG_XFS_FS=y
# CONFIG_XFS_SUPPORT_V4 is not set
# CONFIG_XFS_SUPPORT_ASCII_CI is not set
CONFIG_XFS_QUOTA=y
CONFIG_XFS_POSIX_ACL=y
CONFIG_XFS_RT=y
CONFIG_XFS_DRAIN_INTENTS=y
CONFIG_XFS_LIVE_HOOKS=y
CONFIG_XFS_MEMORY_BUFS=y
CONFIG_XFS_BTREE_IN_MEM=y
CONFIG_XFS_ONLINE_SCRUB=y
# CONFIG_XFS_ONLINE_SCRUB_STATS is not set
CONFIG_XFS_ONLINE_REPAIR=y
# CONFIG_XFS_WARN is not set
# CONFIG_XFS_DEBUG is not set
CONFIG_GFS2_FS=y
CONFIG_GFS2_FS_LOCKING_DLM=y
CONFIG_OCFS2_FS=y
CONFIG_OCFS2_FS_O2CB=y
CONFIG_OCFS2_FS_USERSPACE_CLUSTER=y
CONFIG_OCFS2_FS_STATS=y
# CONFIG_OCFS2_DEBUG_MASKLOG is not set
CONFIG_OCFS2_DEBUG_FS=y
CONFIG_BTRFS_FS=y
CONFIG_BTRFS_FS_POSIX_ACL=y
# CONFIG_BTRFS_FS_RUN_SANITY_TESTS is not set
# CONFIG_BTRFS_DEBUG is not set
CONFIG_BTRFS_ASSERT=y
# CONFIG_BTRFS_EXPERIMENTAL is not set
CONFIG_NILFS2_FS=y
CONFIG_F2FS_FS=y
CONFIG_F2FS_STAT_FS=y
CONFIG_F2FS_FS_XATTR=y
CONFIG_F2FS_FS_POSIX_ACL=y
CONFIG_F2FS_FS_SECURITY=y
CONFIG_F2FS_CHECK_FS=y
CONFIG_F2FS_FAULT_INJECTION=y
CONFIG_F2FS_FS_COMPRESSION=y
CONFIG_F2FS_FS_LZO=y
CONFIG_F2FS_FS_LZORLE=y
CONFIG_F2FS_FS_LZ4=y
CONFIG_F2FS_FS_LZ4HC=y
CONFIG_F2FS_FS_ZSTD=y
# CONFIG_F2FS_IOSTAT is not set
# CONFIG_F2FS_UNFAIR_RWSEM is not set
CONFIG_ZONEFS_FS=y
CONFIG_FS_DAX=y
CONFIG_FS_DAX_PMD=y
CONFIG_FS_POSIX_ACL=y
CONFIG_EXPORTFS=y
CONFIG_EXPORTFS_BLOCK_OPS=y
CONFIG_FILE_LOCKING=y
CONFIG_FS_ENCRYPTION=y
CONFIG_FS_ENCRYPTION_ALGS=y
# CONFIG_FS_ENCRYPTION_INLINE_CRYPT is not set
CONFIG_FS_VERITY=y
CONFIG_FS_VERITY_BUILTIN_SIGNATURES=y
CONFIG_FSNOTIFY=y
CONFIG_DNOTIFY=y
CONFIG_INOTIFY_USER=y
CONFIG_FANOTIFY=y
CONFIG_FANOTIFY_ACCESS_PERMISSIONS=y
CONFIG_QUOTA=y
CONFIG_QUOTA_NETLINK_INTERFACE=y
# CONFIG_QUOTA_DEBUG is not set
CONFIG_QUOTA_TREE=y
# CONFIG_QFMT_V1 is not set
CONFIG_QFMT_V2=y
CONFIG_QUOTACTL=y
CONFIG_AUTOFS_FS=y
CONFIG_FUSE_FS=y
CONFIG_CUSE=y
CONFIG_VIRTIO_FS=y
CONFIG_FUSE_DAX=y
# CONFIG_FUSE_PASSTHROUGH is not set
CONFIG_FUSE_IO_URING=y
CONFIG_OVERLAY_FS=y
CONFIG_OVERLAY_FS_REDIRECT_DIR=y
CONFIG_OVERLAY_FS_REDIRECT_ALWAYS_FOLLOW=y
CONFIG_OVERLAY_FS_INDEX=y
# CONFIG_OVERLAY_FS_NFS_EXPORT is not set
# CONFIG_OVERLAY_FS_XINO_AUTO is not set
# CONFIG_OVERLAY_FS_METACOPY is not set
CONFIG_OVERLAY_FS_DEBUG=y

#
# Caches
#
CONFIG_NETFS_SUPPORT=y
# CONFIG_NETFS_STATS is not set
# CONFIG_NETFS_DEBUG is not set
CONFIG_FSCACHE=y
# CONFIG_FSCACHE_STATS is not set
CONFIG_CACHEFILES=y
# CONFIG_CACHEFILES_DEBUG is not set
# CONFIG_CACHEFILES_ERROR_INJECTION is not set
# CONFIG_CACHEFILES_ONDEMAND is not set
# end of Caches

#
# CD-ROM/DVD Filesystems
#
CONFIG_ISO9660_FS=y
CONFIG_JOLIET=y
CONFIG_ZISOFS=y
CONFIG_UDF_FS=y
# end of CD-ROM/DVD Filesystems

#
# DOS/FAT/EXFAT/NT Filesystems
#
CONFIG_FAT_FS=y
CONFIG_MSDOS_FS=y
CONFIG_VFAT_FS=y
CONFIG_FAT_DEFAULT_CODEPAGE=437
CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1"
# CONFIG_FAT_DEFAULT_UTF8 is not set
CONFIG_EXFAT_FS=y
CONFIG_EXFAT_DEFAULT_IOCHARSET="utf8"
# CONFIG_NTFS_FS is not set
CONFIG_NTFS3_FS=y
# CONFIG_NTFS3_64BIT_CLUSTER is not set
CONFIG_NTFS3_LZX_XPRESS=y
CONFIG_NTFS3_FS_POSIX_ACL=y
# end of DOS/FAT/EXFAT/NT Filesystems

#
# Pseudo filesystems
#
CONFIG_PROC_FS=y
CONFIG_PROC_KCORE=y
CONFIG_PROC_VMCORE=y
# CONFIG_PROC_VMCORE_DEVICE_DUMP is not set
CONFIG_PROC_SYSCTL=y
CONFIG_PROC_PAGE_MONITOR=y
CONFIG_PROC_CHILDREN=y
CONFIG_PROC_PID_ARCH_STATUS=y
CONFIG_KERNFS=y
CONFIG_SYSFS=y
CONFIG_TMPFS=y
CONFIG_TMPFS_POSIX_ACL=y
CONFIG_TMPFS_XATTR=y
# CONFIG_TMPFS_INODE64 is not set
CONFIG_TMPFS_QUOTA=y
CONFIG_ARCH_SUPPORTS_HUGETLBFS=y
CONFIG_HUGETLBFS=y
# CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP_DEFAULT_ON is not set
CONFIG_HUGETLB_PAGE=y
CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP=y
CONFIG_HUGETLB_PMD_PAGE_TABLE_SHARING=y
CONFIG_ARCH_HAS_GIGANTIC_PAGE=y
CONFIG_CONFIGFS_FS=y
# end of Pseudo filesystems

CONFIG_MISC_FILESYSTEMS=y
CONFIG_ORANGEFS_FS=y
CONFIG_ADFS_FS=y
# CONFIG_ADFS_FS_RW is not set
CONFIG_AFFS_FS=y
CONFIG_ECRYPT_FS=y
CONFIG_ECRYPT_FS_MESSAGING=y
CONFIG_HFS_FS=y
CONFIG_HFSPLUS_FS=y
CONFIG_BEFS_FS=y
# CONFIG_BEFS_DEBUG is not set
CONFIG_BFS_FS=y
CONFIG_EFS_FS=y
CONFIG_JFFS2_FS=y
CONFIG_JFFS2_FS_DEBUG=0
CONFIG_JFFS2_FS_WRITEBUFFER=y
# CONFIG_JFFS2_FS_WBUF_VERIFY is not set
CONFIG_JFFS2_SUMMARY=y
CONFIG_JFFS2_FS_XATTR=y
CONFIG_JFFS2_FS_POSIX_ACL=y
CONFIG_JFFS2_FS_SECURITY=y
CONFIG_JFFS2_COMPRESSION_OPTIONS=y
CONFIG_JFFS2_ZLIB=y
CONFIG_JFFS2_LZO=y
CONFIG_JFFS2_RTIME=y
CONFIG_JFFS2_RUBIN=y
# CONFIG_JFFS2_CMODE_NONE is not set
CONFIG_JFFS2_CMODE_PRIORITY=y
# CONFIG_JFFS2_CMODE_SIZE is not set
# CONFIG_JFFS2_CMODE_FAVOURLZO is not set
CONFIG_UBIFS_FS=y
CONFIG_UBIFS_FS_ADVANCED_COMPR=y
CONFIG_UBIFS_FS_LZO=y
CONFIG_UBIFS_FS_ZLIB=y
CONFIG_UBIFS_FS_ZSTD=y
CONFIG_UBIFS_ATIME_SUPPORT=y
CONFIG_UBIFS_FS_XATTR=y
CONFIG_UBIFS_FS_SECURITY=y
# CONFIG_UBIFS_FS_AUTHENTICATION is not set
CONFIG_CRAMFS=y
CONFIG_CRAMFS_BLOCKDEV=y
CONFIG_CRAMFS_MTD=y
CONFIG_SQUASHFS=y
# CONFIG_SQUASHFS_FILE_CACHE is not set
CONFIG_SQUASHFS_FILE_DIRECT=y
CONFIG_SQUASHFS_DECOMP_MULTI=y
# CONFIG_SQUASHFS_CHOICE_DECOMP_BY_MOUNT is not set
# CONFIG_SQUASHFS_COMPILE_DECOMP_SINGLE is not set
CONFIG_SQUASHFS_COMPILE_DECOMP_MULTI=y
# CONFIG_SQUASHFS_COMPILE_DECOMP_MULTI_PERCPU is not set
# CONFIG_SQUASHFS_MOUNT_DECOMP_THREADS is not set
CONFIG_SQUASHFS_XATTR=y
# CONFIG_SQUASHFS_COMP_CACHE_FULL is not set
CONFIG_SQUASHFS_ZLIB=y
CONFIG_SQUASHFS_LZ4=y
CONFIG_SQUASHFS_LZO=y
CONFIG_SQUASHFS_XZ=y
CONFIG_SQUASHFS_ZSTD=y
CONFIG_SQUASHFS_4K_DEVBLK_SIZE=y
# CONFIG_SQUASHFS_EMBEDDED is not set
CONFIG_SQUASHFS_FRAGMENT_CACHE_SIZE=3
CONFIG_VXFS_FS=y
CONFIG_MINIX_FS=y
CONFIG_OMFS_FS=y
CONFIG_HPFS_FS=y
CONFIG_QNX4FS_FS=y
CONFIG_QNX6FS_FS=y
# CONFIG_QNX6FS_DEBUG is not set
CONFIG_ROMFS_FS=y
# CONFIG_ROMFS_BACKED_BY_BLOCK is not set
# CONFIG_ROMFS_BACKED_BY_MTD is not set
CONFIG_ROMFS_BACKED_BY_BOTH=y
CONFIG_ROMFS_ON_BLOCK=y
CONFIG_ROMFS_ON_MTD=y
CONFIG_PSTORE=y
CONFIG_PSTORE_DEFAULT_KMSG_BYTES=10240
CONFIG_PSTORE_COMPRESS=y
# CONFIG_PSTORE_CONSOLE is not set
# CONFIG_PSTORE_PMSG is not set
# CONFIG_PSTORE_RAM is not set
# CONFIG_PSTORE_BLK is not set
CONFIG_UFS_FS=y
CONFIG_UFS_FS_WRITE=y
# CONFIG_UFS_DEBUG is not set
CONFIG_EROFS_FS=y
# CONFIG_EROFS_FS_DEBUG is not set
CONFIG_EROFS_FS_XATTR=y
CONFIG_EROFS_FS_POSIX_ACL=y
CONFIG_EROFS_FS_SECURITY=y
# CONFIG_EROFS_FS_BACKED_BY_FILE is not set
CONFIG_EROFS_FS_ZIP=y
# CONFIG_EROFS_FS_ZIP_LZMA is not set
# CONFIG_EROFS_FS_ZIP_DEFLATE is not set
# CONFIG_EROFS_FS_ZIP_ZSTD is not set
# CONFIG_EROFS_FS_ZIP_ACCEL is not set
# CONFIG_EROFS_FS_PCPU_KTHREAD is not set
# CONFIG_EROFS_FS_PAGE_CACHE_SHARE is not set
CONFIG_NETWORK_FILESYSTEMS=y
CONFIG_NFS_FS=y
# CONFIG_NFS_V2 is not set
CONFIG_NFS_V3=y
CONFIG_NFS_V3_ACL=y
CONFIG_NFS_V4=y
# CONFIG_NFS_SWAP is not set
CONFIG_NFS_V4_0=y
CONFIG_NFS_V4_2=y
CONFIG_PNFS_FILE_LAYOUT=y
CONFIG_PNFS_BLOCK=y
CONFIG_PNFS_FLEXFILE_LAYOUT=y
CONFIG_NFS_V4_1_IMPLEMENTATION_ID_DOMAIN="kernel.org"
# CONFIG_NFS_V4_1_MIGRATION is not set
CONFIG_NFS_V4_SECURITY_LABEL=y
CONFIG_ROOT_NFS=y
CONFIG_NFS_FSCACHE=y
# CONFIG_NFS_USE_LEGACY_DNS is not set
CONFIG_NFS_USE_KERNEL_DNS=y
# CONFIG_NFS_DISABLE_UDP_SUPPORT is not set
CONFIG_NFS_V4_2_READ_PLUS=y
CONFIG_NFSD=y
# CONFIG_NFSD_V2 is not set
CONFIG_NFSD_V3_ACL=y
CONFIG_NFSD_V4=y
CONFIG_NFSD_PNFS=y
CONFIG_NFSD_BLOCKLAYOUT=y
CONFIG_NFSD_SCSILAYOUT=y
CONFIG_NFSD_FLEXFILELAYOUT=y
CONFIG_NFSD_V4_2_INTER_SSC=y
CONFIG_NFSD_V4_SECURITY_LABEL=y
# CONFIG_NFSD_LEGACY_CLIENT_TRACKING is not set
# CONFIG_NFSD_V4_POSIX_ACLS is not set
CONFIG_GRACE_PERIOD=y
CONFIG_LOCKD=y
CONFIG_LOCKD_V4=y
CONFIG_NFS_ACL_SUPPORT=y
CONFIG_NFS_COMMON=y
# CONFIG_NFS_LOCALIO is not set
CONFIG_NFS_V4_2_SSC_HELPER=y
CONFIG_SUNRPC=y
CONFIG_SUNRPC_GSS=y
CONFIG_SUNRPC_BACKCHANNEL=y
CONFIG_RPCSEC_GSS_KRB5=y
# CONFIG_SUNRPC_DEBUG is not set
# CONFIG_SUNRPC_XPRT_RDMA is not set
CONFIG_CEPH_FS=y
CONFIG_CEPH_FSCACHE=y
CONFIG_CEPH_FS_POSIX_ACL=y
# CONFIG_CEPH_FS_SECURITY_LABEL is not set
CONFIG_CIFS=y
# CONFIG_CIFS_STATS2 is not set
CONFIG_CIFS_ALLOW_INSECURE_LEGACY=y
CONFIG_CIFS_UPCALL=y
CONFIG_CIFS_XATTR=y
CONFIG_CIFS_POSIX=y
CONFIG_CIFS_DEBUG=y
# CONFIG_CIFS_DEBUG2 is not set
# CONFIG_CIFS_DEBUG_DUMP_KEYS is not set
CONFIG_CIFS_DFS_UPCALL=y
CONFIG_CIFS_SWN_UPCALL=y
CONFIG_CIFS_SMB_DIRECT=y
CONFIG_CIFS_FSCACHE=y
# CONFIG_CIFS_ROOT is not set
# CONFIG_CIFS_COMPRESSION is not set
CONFIG_SMB_SERVER=y
# CONFIG_SMB_SERVER_SMBDIRECT is not set
# CONFIG_SMB_SERVER_CHECK_CAP_NET_ADMIN is not set
# CONFIG_SMB_SERVER_KERBEROS5 is not set
CONFIG_SMBDIRECT=y
CONFIG_SMBFS=y
# CONFIG_CODA_FS is not set
CONFIG_AFS_FS=y
# CONFIG_AFS_DEBUG is not set
CONFIG_AFS_FSCACHE=y
# CONFIG_AFS_DEBUG_CURSOR is not set
CONFIG_9P_FS=y
CONFIG_9P_FSCACHE=y
CONFIG_9P_FS_POSIX_ACL=y
CONFIG_9P_FS_SECURITY=y
CONFIG_NLS=y
CONFIG_NLS_DEFAULT="utf8"
CONFIG_NLS_CODEPAGE_437=y
CONFIG_NLS_CODEPAGE_737=y
CONFIG_NLS_CODEPAGE_775=y
CONFIG_NLS_CODEPAGE_850=y
CONFIG_NLS_CODEPAGE_852=y
CONFIG_NLS_CODEPAGE_855=y
CONFIG_NLS_CODEPAGE_857=y
CONFIG_NLS_CODEPAGE_860=y
CONFIG_NLS_CODEPAGE_861=y
CONFIG_NLS_CODEPAGE_862=y
CONFIG_NLS_CODEPAGE_863=y
CONFIG_NLS_CODEPAGE_864=y
CONFIG_NLS_CODEPAGE_865=y
CONFIG_NLS_CODEPAGE_866=y
CONFIG_NLS_CODEPAGE_869=y
CONFIG_NLS_CODEPAGE_936=y
CONFIG_NLS_CODEPAGE_950=y
CONFIG_NLS_CODEPAGE_932=y
CONFIG_NLS_CODEPAGE_949=y
CONFIG_NLS_CODEPAGE_874=y
CONFIG_NLS_ISO8859_8=y
CONFIG_NLS_CODEPAGE_1250=y
CONFIG_NLS_CODEPAGE_1251=y
CONFIG_NLS_ASCII=y
CONFIG_NLS_ISO8859_1=y
CONFIG_NLS_ISO8859_2=y
CONFIG_NLS_ISO8859_3=y
CONFIG_NLS_ISO8859_4=y
CONFIG_NLS_ISO8859_5=y
CONFIG_NLS_ISO8859_6=y
CONFIG_NLS_ISO8859_7=y
CONFIG_NLS_ISO8859_9=y
CONFIG_NLS_ISO8859_13=y
CONFIG_NLS_ISO8859_14=y
CONFIG_NLS_ISO8859_15=y
CONFIG_NLS_KOI8_R=y
CONFIG_NLS_KOI8_U=y
CONFIG_NLS_MAC_ROMAN=y
CONFIG_NLS_MAC_CELTIC=y
CONFIG_NLS_MAC_CENTEURO=y
CONFIG_NLS_MAC_CROATIAN=y
CONFIG_NLS_MAC_CYRILLIC=y
CONFIG_NLS_MAC_GAELIC=y
CONFIG_NLS_MAC_GREEK=y
CONFIG_NLS_MAC_ICELAND=y
CONFIG_NLS_MAC_INUIT=y
CONFIG_NLS_MAC_ROMANIAN=y
CONFIG_NLS_MAC_TURKISH=y
CONFIG_NLS_UTF8=y
CONFIG_NLS_UCS2_UTILS=y
CONFIG_DLM=y
# CONFIG_DLM_DEBUG is not set
CONFIG_UNICODE=y
CONFIG_IO_WQ=y
# end of File systems

#
# Security options
#
CONFIG_KEYS=y
CONFIG_KEYS_REQUEST_CACHE=y
CONFIG_PERSISTENT_KEYRINGS=y
CONFIG_BIG_KEYS=y
CONFIG_TRUSTED_KEYS=y
# CONFIG_TRUSTED_KEYS_TPM is not set
# CONFIG_TRUSTED_KEYS_TEE is not set

#
# No trust source selected!
#
CONFIG_ENCRYPTED_KEYS=y
# CONFIG_USER_DECRYPTED_DATA is not set
CONFIG_KEY_DH_OPERATIONS=y
CONFIG_KEY_NOTIFICATIONS=y
# CONFIG_SECURITY_DMESG_RESTRICT is not set
# CONFIG_PROC_MEM_ALWAYS_FORCE is not set
CONFIG_PROC_MEM_FORCE_PTRACE=y
# CONFIG_PROC_MEM_NO_FORCE is not set
CONFIG_SECURITY=y
CONFIG_HAS_SECURITY_AUDIT=y
CONFIG_SECURITYFS=y
CONFIG_SECURITY_NETWORK=y
CONFIG_SECURITY_INFINIBAND=y
CONFIG_SECURITY_NETWORK_XFRM=y
CONFIG_SECURITY_PATH=y
# CONFIG_INTEL_TXT is not set
# CONFIG_STATIC_USERMODEHELPER is not set
# CONFIG_SECURITY_SELINUX is not set
# CONFIG_SECURITY_SMACK is not set
CONFIG_SECURITY_TOMOYO=y
CONFIG_SECURITY_TOMOYO_MAX_ACCEPT_ENTRY=64
CONFIG_SECURITY_TOMOYO_MAX_AUDIT_LOG=32
CONFIG_SECURITY_TOMOYO_OMIT_USERSPACE_LOADER=y
CONFIG_SECURITY_TOMOYO_INSECURE_BUILTIN_SETTING=y
CONFIG_SECURITY_APPARMOR=y
CONFIG_SECURITY_APPARMOR_DEBUG=y
CONFIG_SECURITY_APPARMOR_DEBUG_ASSERTS=y
# CONFIG_SECURITY_APPARMOR_DEBUG_MESSAGES is not set
CONFIG_SECURITY_APPARMOR_INTROSPECT_POLICY=y
CONFIG_SECURITY_APPARMOR_HASH=y
CONFIG_SECURITY_APPARMOR_HASH_DEFAULT=y
# CONFIG_SECURITY_APPARMOR_EXPORT_BINARY is not set
# CONFIG_SECURITY_APPARMOR_PARANOID_LOAD is not set
# CONFIG_SECURITY_LOADPIN is not set
CONFIG_SECURITY_YAMA=y
CONFIG_SECURITY_SAFESETID=y
CONFIG_SECURITY_LOCKDOWN_LSM=y
CONFIG_SECURITY_LOCKDOWN_LSM_EARLY=y
CONFIG_LOCK_DOWN_KERNEL_FORCE_NONE=y
# CONFIG_LOCK_DOWN_KERNEL_FORCE_INTEGRITY is not set
# CONFIG_LOCK_DOWN_KERNEL_FORCE_CONFIDENTIALITY is not set
CONFIG_SECURITY_LANDLOCK=y
# CONFIG_SECURITY_IPE is not set
CONFIG_INTEGRITY=y
CONFIG_INTEGRITY_SIGNATURE=y
CONFIG_INTEGRITY_ASYMMETRIC_KEYS=y
CONFIG_INTEGRITY_TRUSTED_KEYRING=y
CONFIG_INTEGRITY_AUDIT=y
CONFIG_IMA=y
CONFIG_IMA_MEASURE_PCR_IDX=10
CONFIG_IMA_LSM_RULES=y
CONFIG_IMA_NG_TEMPLATE=y
# CONFIG_IMA_SIG_TEMPLATE is not set
CONFIG_IMA_DEFAULT_TEMPLATE="ima-ng"
# CONFIG_IMA_DEFAULT_HASH_SHA1 is not set
CONFIG_IMA_DEFAULT_HASH_SHA256=y
# CONFIG_IMA_DEFAULT_HASH_SHA512 is not set
# CONFIG_IMA_DEFAULT_HASH_WP512 is not set
CONFIG_IMA_DEFAULT_HASH="sha256"
CONFIG_IMA_WRITE_POLICY=y
CONFIG_IMA_READ_POLICY=y
CONFIG_IMA_APPRAISE=y
# CONFIG_IMA_ARCH_POLICY is not set
# CONFIG_IMA_APPRAISE_BUILD_POLICY is not set
# CONFIG_IMA_APPRAISE_BOOTPARAM is not set
CONFIG_IMA_APPRAISE_MODSIG=y
# CONFIG_IMA_KEYRINGS_PERMIT_SIGNED_BY_BUILTIN_OR_SECONDARY is not set
# CONFIG_IMA_BLACKLIST_KEYRING is not set
# CONFIG_IMA_LOAD_X509 is not set
CONFIG_IMA_MEASURE_ASYMMETRIC_KEYS=y
CONFIG_IMA_QUEUE_EARLY_BOOT_KEYS=y
# CONFIG_IMA_DISABLE_HTABLE is not set
# CONFIG_IMA_STAGING is not set
CONFIG_EVM=y
CONFIG_EVM_ATTR_FSUUID=y
CONFIG_EVM_ADD_XATTRS=y
# CONFIG_EVM_LOAD_X509 is not set
# CONFIG_DEFAULT_SECURITY_TOMOYO is not set
CONFIG_DEFAULT_SECURITY_APPARMOR=y
# CONFIG_DEFAULT_SECURITY_DAC is not set
CONFIG_LSM="landlock,lockdown,yama,safesetid,integrity,tomoyo,apparmor,bpf"

#
# Kernel hardening options
#

#
# Memory initialization
#
CONFIG_CC_HAS_AUTO_VAR_INIT_PATTERN=y
CONFIG_CC_HAS_AUTO_VAR_INIT_ZERO_BARE=y
CONFIG_CC_HAS_AUTO_VAR_INIT_ZERO=y
# CONFIG_INIT_STACK_NONE is not set
# CONFIG_INIT_STACK_ALL_PATTERN is not set
CONFIG_INIT_STACK_ALL_ZERO=y
CONFIG_CC_HAS_SANCOV_STACK_DEPTH_CALLBACK=y
# CONFIG_KSTACK_ERASE is not set
CONFIG_INIT_ON_ALLOC_DEFAULT_ON=y
# CONFIG_INIT_ON_FREE_DEFAULT_ON is not set
CONFIG_CC_HAS_ZERO_CALL_USED_REGS=y
# CONFIG_ZERO_CALL_USED_REGS is not set
# end of Memory initialization

#
# Bounds checking
#
CONFIG_FORTIFY_SOURCE=y
CONFIG_HARDENED_USERCOPY=y
# CONFIG_HARDENED_USERCOPY_DEFAULT_ON is not set
# end of Bounds checking

#
# Hardening of kernel data structures
#
CONFIG_LIST_HARDENED=y
CONFIG_BUG_ON_DATA_CORRUPTION=y
# end of Hardening of kernel data structures

CONFIG_CC_HAS_RANDSTRUCT=y
CONFIG_RANDSTRUCT_NONE=y
# CONFIG_RANDSTRUCT_FULL is not set
# end of Kernel hardening options
# end of Security options

CONFIG_ASYNC_CORE=y
CONFIG_ASYNC_MEMCPY=y
CONFIG_ASYNC_XOR=y
CONFIG_ASYNC_PQ=y
CONFIG_ASYNC_RAID6_RECOV=y
CONFIG_CRYPTO=y

#
# Crypto core or helper
#
CONFIG_CRYPTO_ALGAPI=y
CONFIG_CRYPTO_ALGAPI2=y
CONFIG_CRYPTO_AEAD=y
CONFIG_CRYPTO_AEAD2=y
CONFIG_CRYPTO_SIG=y
CONFIG_CRYPTO_SIG2=y
CONFIG_CRYPTO_SKCIPHER=y
CONFIG_CRYPTO_SKCIPHER2=y
CONFIG_CRYPTO_HASH=y
CONFIG_CRYPTO_HASH2=y
CONFIG_CRYPTO_RNG=y
CONFIG_CRYPTO_RNG2=y
CONFIG_CRYPTO_AKCIPHER2=y
CONFIG_CRYPTO_AKCIPHER=y
CONFIG_CRYPTO_KPP2=y
CONFIG_CRYPTO_KPP=y
CONFIG_CRYPTO_ACOMP2=y
CONFIG_CRYPTO_ACOMP=y
CONFIG_CRYPTO_MANAGER=y
CONFIG_CRYPTO_MANAGER2=y
CONFIG_CRYPTO_USER=y
# CONFIG_CRYPTO_SELFTESTS is not set
# CONFIG_CRYPTO_NULL is not set
CONFIG_CRYPTO_PCRYPT=y
# CONFIG_CRYPTO_CRYPTD is not set
CONFIG_CRYPTO_AUTHENC=y
CONFIG_CRYPTO_KRB5ENC=y
# CONFIG_CRYPTO_BENCHMARK is not set
CONFIG_CRYPTO_ENGINE=y
# end of Crypto core or helper

#
# Public-key cryptography
#
CONFIG_CRYPTO_RSA=y
CONFIG_CRYPTO_DH=y
# CONFIG_CRYPTO_DH_RFC7919_GROUPS is not set
CONFIG_CRYPTO_ECC=y
CONFIG_CRYPTO_ECDH=y
# CONFIG_CRYPTO_ECDSA is not set
CONFIG_CRYPTO_ECRDSA=y
CONFIG_CRYPTO_MLDSA=y
# end of Public-key cryptography

#
# Block ciphers
#
CONFIG_CRYPTO_AES=y
CONFIG_CRYPTO_ANUBIS=y
CONFIG_CRYPTO_ARIA=y
CONFIG_CRYPTO_BLOWFISH=y
CONFIG_CRYPTO_BLOWFISH_COMMON=y
CONFIG_CRYPTO_CAMELLIA=y
CONFIG_CRYPTO_CAST_COMMON=y
CONFIG_CRYPTO_CAST5=y
CONFIG_CRYPTO_CAST6=y
CONFIG_CRYPTO_DES=y
CONFIG_CRYPTO_KHAZAD=y
CONFIG_CRYPTO_SEED=y
CONFIG_CRYPTO_SERPENT=y
CONFIG_CRYPTO_SM4=y
CONFIG_CRYPTO_SM4_GENERIC=y
CONFIG_CRYPTO_TEA=y
CONFIG_CRYPTO_TWOFISH=y
CONFIG_CRYPTO_TWOFISH_COMMON=y
# end of Block ciphers

#
# Length-preserving ciphers and modes
#
CONFIG_CRYPTO_ADIANTUM=y
CONFIG_CRYPTO_ARC4=y
CONFIG_CRYPTO_CHACHA20=y
CONFIG_CRYPTO_CBC=y
CONFIG_CRYPTO_CTR=y
CONFIG_CRYPTO_CTS=y
CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_HCTR2=y
CONFIG_CRYPTO_LRW=y
CONFIG_CRYPTO_XCTR=y
CONFIG_CRYPTO_XTS=y
# end of Length-preserving ciphers and modes

#
# AEAD (authenticated encryption with associated data) ciphers
#
CONFIG_CRYPTO_AEGIS128=y
CONFIG_CRYPTO_CHACHA20POLY1305=y
CONFIG_CRYPTO_CCM=y
CONFIG_CRYPTO_GCM=y
CONFIG_CRYPTO_GENIV=y
CONFIG_CRYPTO_SEQIV=y
CONFIG_CRYPTO_ECHAINIV=y
CONFIG_CRYPTO_ESSIV=y
# end of AEAD (authenticated encryption with associated data) ciphers

#
# Hashes, digests, and MACs
#
# CONFIG_CRYPTO_BLAKE2B is not set
CONFIG_CRYPTO_CMAC=y
CONFIG_CRYPTO_HMAC=y
# CONFIG_CRYPTO_MD4 is not set
# CONFIG_CRYPTO_MD5 is not set
CONFIG_CRYPTO_RMD160=y
CONFIG_CRYPTO_SHA1=y
CONFIG_CRYPTO_SHA256=y
CONFIG_CRYPTO_SHA512=y
CONFIG_CRYPTO_SHA3=y
# CONFIG_CRYPTO_SM3 is not set
CONFIG_CRYPTO_STREEBOG=y
CONFIG_CRYPTO_WP512=y
CONFIG_CRYPTO_XCBC=y
# CONFIG_CRYPTO_XXHASH is not set
# end of Hashes, digests, and MACs

#
# CRCs (cyclic redundancy checks)
#
# CONFIG_CRYPTO_CRC32C is not set
# CONFIG_CRYPTO_CRC32 is not set
# end of CRCs (cyclic redundancy checks)

#
# Compression
#
CONFIG_CRYPTO_DEFLATE=y
CONFIG_CRYPTO_LZO=y
CONFIG_CRYPTO_842=y
CONFIG_CRYPTO_LZ4=y
CONFIG_CRYPTO_LZ4HC=y
CONFIG_CRYPTO_ZSTD=y
# end of Compression

#
# Random number generation
#
# CONFIG_CRYPTO_DRBG is not set
# CONFIG_CRYPTO_JITTERENTROPY is not set
CONFIG_CRYPTO_KDF800108_CTR=y
# end of Random number generation

#
# Userspace interface (deprecated)
#
CONFIG_CRYPTO_USER_API=y
CONFIG_CRYPTO_USER_API_HASH=y
CONFIG_CRYPTO_USER_API_SKCIPHER=y
CONFIG_CRYPTO_USER_API_RNG=y
CONFIG_CRYPTO_USER_API_AEAD=y
CONFIG_CRYPTO_USER_API_ENABLE_OBSOLETE=y
# end of Userspace interface (deprecated)

#
# Accelerated Cryptographic Algorithms for CPU (x86)
#
CONFIG_CRYPTO_AES_NI_INTEL=y
CONFIG_CRYPTO_BLOWFISH_X86_64=y
CONFIG_CRYPTO_CAMELLIA_X86_64=y
CONFIG_CRYPTO_CAMELLIA_AESNI_AVX_X86_64=y
CONFIG_CRYPTO_CAMELLIA_AESNI_AVX2_X86_64=y
CONFIG_CRYPTO_CAST5_AVX_X86_64=y
CONFIG_CRYPTO_CAST6_AVX_X86_64=y
CONFIG_CRYPTO_SERPENT_SSE2_X86_64=y
CONFIG_CRYPTO_SERPENT_AVX_X86_64=y
CONFIG_CRYPTO_SERPENT_AVX2_X86_64=y
CONFIG_CRYPTO_SM4_AESNI_AVX_X86_64=y
CONFIG_CRYPTO_SM4_AESNI_AVX2_X86_64=y
CONFIG_CRYPTO_TWOFISH_X86_64=y
CONFIG_CRYPTO_TWOFISH_X86_64_3WAY=y
CONFIG_CRYPTO_TWOFISH_AVX_X86_64=y
CONFIG_CRYPTO_ARIA_AESNI_AVX_X86_64=y
# CONFIG_CRYPTO_ARIA_AESNI_AVX2_X86_64 is not set
# CONFIG_CRYPTO_ARIA_GFNI_AVX512_X86_64 is not set
CONFIG_CRYPTO_AEGIS128_AESNI_SSE2=y
# end of Accelerated Cryptographic Algorithms for CPU (x86)

CONFIG_CRYPTO_HW=y
CONFIG_CRYPTO_DEV_PADLOCK=y
CONFIG_CRYPTO_DEV_PADLOCK_AES=y
CONFIG_CRYPTO_DEV_PADLOCK_SHA=y
# CONFIG_CRYPTO_DEV_ATMEL_ECC is not set
# CONFIG_CRYPTO_DEV_ATMEL_SHA204A is not set
CONFIG_CRYPTO_DEV_CCP=y
CONFIG_CRYPTO_DEV_CCP_DD=y
# CONFIG_CRYPTO_DEV_SP_CCP is not set
# CONFIG_CRYPTO_DEV_SP_PSP is not set
# CONFIG_CRYPTO_DEV_NITROX_CNN55XX is not set
CONFIG_CRYPTO_DEV_QAT=y
CONFIG_CRYPTO_DEV_QAT_DH895xCC=y
CONFIG_CRYPTO_DEV_QAT_C3XXX=y
CONFIG_CRYPTO_DEV_QAT_C62X=y
# CONFIG_CRYPTO_DEV_QAT_4XXX is not set
# CONFIG_CRYPTO_DEV_QAT_420XX is not set
# CONFIG_CRYPTO_DEV_QAT_6XXX is not set
CONFIG_CRYPTO_DEV_QAT_DH895xCCVF=y
CONFIG_CRYPTO_DEV_QAT_C3XXXVF=y
CONFIG_CRYPTO_DEV_QAT_C62XVF=y
# CONFIG_CRYPTO_DEV_QAT_ERROR_INJECTION is not set
CONFIG_CRYPTO_DEV_VIRTIO=y
# CONFIG_CRYPTO_DEV_SAFEXCEL is not set
# CONFIG_CRYPTO_DEV_CCREE is not set
# CONFIG_CRYPTO_DEV_AMLOGIC_GXL is not set
CONFIG_ASYMMETRIC_KEY_TYPE=y
CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE=y
CONFIG_X509_CERTIFICATE_PARSER=y
CONFIG_PKCS8_PRIVATE_KEY_PARSER=y
CONFIG_PKCS7_MESSAGE_PARSER=y
# CONFIG_PKCS7_WAIVE_AUTHATTRS_REJECTION_FOR_MLDSA is not set
CONFIG_PKCS7_TEST_KEY=y
CONFIG_SIGNED_PE_FILE_VERIFICATION=y
# CONFIG_FIPS_SIGNATURE_SELFTEST is not set

#
# Certificates for signature checking
#
CONFIG_MODULE_SIG_KEY="certs/signing_key.pem"
# CONFIG_MODULE_SIG_KEY_TYPE_RSA is not set
CONFIG_MODULE_SIG_KEY_TYPE_MLDSA_44=y
# CONFIG_MODULE_SIG_KEY_TYPE_MLDSA_65 is not set
# CONFIG_MODULE_SIG_KEY_TYPE_MLDSA_87 is not set
CONFIG_SYSTEM_TRUSTED_KEYRING=y
CONFIG_SYSTEM_TRUSTED_KEYS=""
# CONFIG_SYSTEM_EXTRA_CERTIFICATE is not set
CONFIG_SECONDARY_TRUSTED_KEYRING=y
# CONFIG_SECONDARY_TRUSTED_KEYRING_SIGNED_BY_BUILTIN is not set
# CONFIG_SYSTEM_BLACKLIST_KEYRING is not set
CONFIG_OPENSSL_SUPPORTS_ML_DSA=y
# end of Certificates for signature checking

CONFIG_CRYPTO_KRB5=y
# CONFIG_CRYPTO_KRB5_SELFTESTS is not set
CONFIG_BINARY_PRINTF=y

#
# Library routines
#
CONFIG_LINEAR_RANGES=y
# CONFIG_PACKING is not set
CONFIG_BITREVERSE=y
CONFIG_GENERIC_BITREVERSE=y
CONFIG_GENERIC_STRNCPY_FROM_USER=y
CONFIG_GENERIC_STRNLEN_USER=y
CONFIG_GENERIC_NET_UTILS=y
# CONFIG_CORDIC is not set
# CONFIG_PRIME_NUMBERS is not set
CONFIG_RATIONAL=y
CONFIG_GENERIC_IOMAP=y
CONFIG_ARCH_USE_CMPXCHG_LOCKREF=y
CONFIG_ARCH_HAS_FAST_MULTIPLIER=y
CONFIG_ARCH_USE_SYM_ANNOTATIONS=y
CONFIG_CRC8=y
CONFIG_CRC16=y
CONFIG_CRC_CCITT=y
CONFIG_CRC_ITU_T=y
CONFIG_CRC_T10DIF=y
CONFIG_CRC_T10DIF_ARCH=y
CONFIG_CRC32=y
CONFIG_CRC32_ARCH=y
CONFIG_CRC64=y
CONFIG_CRC64_ARCH=y
CONFIG_CRC_OPTIMIZATIONS=y
CONFIG_CRYPTO_HASH_INFO=y
CONFIG_CRYPTO_LIB_UTILS=y
CONFIG_CRYPTO_LIB_AES=y
CONFIG_CRYPTO_LIB_AES_ARCH=y
CONFIG_CRYPTO_LIB_AES_CBC_MACS=y
CONFIG_CRYPTO_LIB_ARC4=y
CONFIG_CRYPTO_LIB_GF128MUL=y
CONFIG_CRYPTO_LIB_BLAKE2B=y
CONFIG_CRYPTO_LIB_BLAKE2S_ARCH=y
CONFIG_CRYPTO_LIB_CHACHA=y
CONFIG_CRYPTO_LIB_CHACHA_ARCH=y
CONFIG_CRYPTO_LIB_CURVE25519=y
CONFIG_CRYPTO_LIB_CURVE25519_ARCH=y
CONFIG_CRYPTO_LIB_CURVE25519_GENERIC=y
CONFIG_CRYPTO_LIB_DES=y
CONFIG_CRYPTO_LIB_GF128HASH=y
CONFIG_CRYPTO_LIB_GF128HASH_ARCH=y
CONFIG_CRYPTO_LIB_MD5=y
CONFIG_CRYPTO_LIB_MLDSA=y
CONFIG_CRYPTO_LIB_NH=y
CONFIG_CRYPTO_LIB_NH_ARCH=y
CONFIG_CRYPTO_LIB_POLY1305=y
CONFIG_CRYPTO_LIB_POLY1305_ARCH=y
CONFIG_CRYPTO_LIB_POLY1305_GENERIC=y
CONFIG_CRYPTO_LIB_POLY1305_RSIZE=11
CONFIG_CRYPTO_LIB_CHACHA20POLY1305=y
CONFIG_CRYPTO_LIB_SHA1=y
CONFIG_CRYPTO_LIB_SHA1_ARCH=y
CONFIG_CRYPTO_LIB_SHA256=y
CONFIG_CRYPTO_LIB_SHA256_ARCH=y
CONFIG_CRYPTO_LIB_SHA512=y
CONFIG_CRYPTO_LIB_SHA512_ARCH=y
CONFIG_CRYPTO_LIB_SHA3=y
CONFIG_XOR_BLOCKS=y
CONFIG_XOR_BLOCKS_ARCH=y
CONFIG_RAID6_PQ=y
CONFIG_RAID6_PQ_ARCH=y
# CONFIG_RAID6_PQ_BENCHMARK is not set
CONFIG_XXHASH=y
# CONFIG_RANDOM32_SELFTEST is not set
CONFIG_842_COMPRESS=y
CONFIG_842_DECOMPRESS=y
CONFIG_ZLIB_INFLATE=y
CONFIG_ZLIB_DEFLATE=y
CONFIG_LZO_COMPRESS=y
CONFIG_LZO_DECOMPRESS=y
CONFIG_LZ4_COMPRESS=y
CONFIG_LZ4HC_COMPRESS=y
CONFIG_LZ4_DECOMPRESS=y
CONFIG_ZSTD_COMMON=y
CONFIG_ZSTD_COMPRESS=y
CONFIG_ZSTD_DECOMPRESS=y
CONFIG_XZ_DEC=y
CONFIG_XZ_DEC_X86=y
CONFIG_XZ_DEC_POWERPC=y
CONFIG_XZ_DEC_ARM=y
CONFIG_XZ_DEC_ARMTHUMB=y
CONFIG_XZ_DEC_ARM64=y
CONFIG_XZ_DEC_SPARC=y
CONFIG_XZ_DEC_RISCV=y
# CONFIG_XZ_DEC_MICROLZMA is not set
CONFIG_XZ_DEC_BCJ=y
# CONFIG_XZ_DEC_TEST is not set
CONFIG_DECOMPRESS_GZIP=y
CONFIG_DECOMPRESS_BZIP2=y
CONFIG_DECOMPRESS_LZMA=y
CONFIG_DECOMPRESS_XZ=y
CONFIG_DECOMPRESS_LZO=y
CONFIG_DECOMPRESS_LZ4=y
CONFIG_DECOMPRESS_ZSTD=y
CONFIG_GENERIC_ALLOCATOR=y
CONFIG_REED_SOLOMON=y
CONFIG_REED_SOLOMON_DEC8=y
CONFIG_TEXTSEARCH=y
CONFIG_TEXTSEARCH_KMP=y
CONFIG_TEXTSEARCH_BM=y
CONFIG_TEXTSEARCH_FSM=y
CONFIG_INTERVAL_TREE=y
CONFIG_INTERVAL_TREE_SPAN_ITER=y
CONFIG_XARRAY_MULTI=y
CONFIG_ASSOCIATIVE_ARRAY=y
CONFIG_CLOSURES=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_IOPORT_MAP=y
CONFIG_HAS_DMA=y
CONFIG_DMA_OPS_HELPERS=y
CONFIG_NEED_SG_DMA_FLAGS=y
CONFIG_NEED_SG_DMA_LENGTH=y
CONFIG_NEED_DMA_MAP_STATE=y
CONFIG_ARCH_DMA_ADDR_T_64BIT=y
CONFIG_DMA_DECLARE_COHERENT=y
CONFIG_SWIOTLB=y
# CONFIG_SWIOTLB_DYNAMIC is not set
CONFIG_DMA_NEED_SYNC=y
# CONFIG_DMA_RESTRICTED_POOL is not set
CONFIG_DMA_CMA=y
# CONFIG_DMA_NUMA_CMA is not set

#
# Default contiguous memory area size:
#
CONFIG_CMA_SIZE_MBYTES=0
CONFIG_CMA_SIZE_PERCENTAGE=0
# CONFIG_CMA_SIZE_SEL_MBYTES is not set
# CONFIG_CMA_SIZE_SEL_PERCENTAGE is not set
# CONFIG_CMA_SIZE_SEL_MIN is not set
CONFIG_CMA_SIZE_SEL_MAX=y
CONFIG_CMA_ALIGNMENT=8
# CONFIG_DMA_API_DEBUG is not set
# CONFIG_DMA_MAP_BENCHMARK is not set
CONFIG_SGL_ALLOC=y
CONFIG_CHECK_SIGNATURE=y
# CONFIG_CPUMASK_OFFSTACK is not set
CONFIG_CPU_RMAP=y
CONFIG_DQL=y
CONFIG_GLOB=y
CONFIG_NLATTR=y
CONFIG_CLZ_TAB=y
CONFIG_IRQ_POLL=y
CONFIG_MPILIB=y
CONFIG_SIGNATURE=y
CONFIG_DIMLIB=y
CONFIG_LIBFDT=y
CONFIG_OID_REGISTRY=y
CONFIG_HAVE_GENERIC_VDSO=y
CONFIG_GENERIC_GETTIMEOFDAY=y
CONFIG_GENERIC_VDSO_OVERFLOW_PROTECT=y
CONFIG_VDSO_GETRANDOM=y
CONFIG_FONT_SUPPORT=y
# CONFIG_FONTS is not set
CONFIG_FONT_8x8=y
CONFIG_FONT_8x16=y
CONFIG_SG_POOL=y
CONFIG_ARCH_HAS_PMEM_API=y
CONFIG_MEMREGION=y
CONFIG_ARCH_HAS_CPU_CACHE_INVALIDATE_MEMREGION=y
CONFIG_ARCH_HAS_UACCESS_FLUSHCACHE=y
CONFIG_ARCH_HAS_COPY_MC=y
CONFIG_ARCH_STACKWALK=y
CONFIG_STACKDEPOT=y
CONFIG_STACKDEPOT_ALWAYS_INIT=y
CONFIG_STACKDEPOT_MAX_FRAMES=64
CONFIG_REF_TRACKER=y
CONFIG_SBITMAP=y
# CONFIG_LWQ_TEST is not set
# end of Library routines

CONFIG_FIRMWARE_TABLE=y
CONFIG_UNION_FIND=y

#
# Kernel hacking
#

#
# printk and dmesg options
#
CONFIG_PRINTK_TIME=y
CONFIG_PRINTK_CALLER=y
# CONFIG_STACKTRACE_BUILD_ID is not set
CONFIG_CONSOLE_LOGLEVEL_DEFAULT=7
CONFIG_CONSOLE_LOGLEVEL_QUIET=4
CONFIG_MESSAGE_LOGLEVEL_DEFAULT=4
# CONFIG_BOOT_PRINTK_DELAY is not set
CONFIG_DYNAMIC_DEBUG=y
CONFIG_DYNAMIC_DEBUG_CORE=y
CONFIG_SYMBOLIC_ERRNAME=y
CONFIG_DEBUG_BUGVERBOSE=y
CONFIG_DEBUG_BUGVERBOSE_DETAILED=y
# end of printk and dmesg options

CONFIG_DEBUG_KERNEL=y
CONFIG_DEBUG_MISC=y

#
# Compile-time checks and compiler options
#
CONFIG_DEBUG_INFO=y
CONFIG_AS_HAS_NON_CONST_ULEB128=y
# CONFIG_DEBUG_INFO_NONE is not set
# CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT is not set
CONFIG_DEBUG_INFO_DWARF4=y
# CONFIG_DEBUG_INFO_DWARF5 is not set
# CONFIG_DEBUG_INFO_REDUCED is not set
CONFIG_DEBUG_INFO_COMPRESSED_NONE=y
# CONFIG_DEBUG_INFO_COMPRESSED_ZLIB is not set
# CONFIG_DEBUG_INFO_COMPRESSED_ZSTD is not set
# CONFIG_DEBUG_INFO_SPLIT is not set
# CONFIG_DEBUG_INFO_BTF is not set
CONFIG_PAHOLE_HAS_BTF_TAG=y
CONFIG_PAHOLE_HAS_LANG_EXCLUDE=y
# CONFIG_GDB_SCRIPTS is not set
CONFIG_FRAME_WARN=2048
# CONFIG_STRIP_ASM_SYMS is not set
# CONFIG_HEADERS_INSTALL is not set
CONFIG_SECTION_MISMATCH_WARN_ONLY=y
# CONFIG_DEBUG_FORCE_FUNCTION_ALIGN_64B is not set
CONFIG_OBJTOOL=y
# CONFIG_OBJTOOL_WERROR is not set
CONFIG_NOINSTR_VALIDATION=y
# CONFIG_VMLINUX_MAP is not set
# CONFIG_DEBUG_FORCE_WEAK_PER_CPU is not set
# end of Compile-time checks and compiler options

#
# Generic Kernel Debugging Instruments
#
# CONFIG_MAGIC_SYSRQ is not set
CONFIG_DEBUG_FS=y
CONFIG_DEBUG_FS_ALLOW_ALL=y
# CONFIG_DEBUG_FS_ALLOW_NONE is not set
CONFIG_HAVE_ARCH_KGDB=y
# CONFIG_KGDB is not set
CONFIG_ARCH_HAS_UBSAN=y
CONFIG_UBSAN=y
# CONFIG_UBSAN_TRAP is not set
CONFIG_CC_HAS_UBSAN_ARRAY_BOUNDS=y
CONFIG_UBSAN_BOUNDS=y
CONFIG_UBSAN_ARRAY_BOUNDS=y
CONFIG_UBSAN_SHIFT=y
# CONFIG_UBSAN_BOOL is not set
# CONFIG_UBSAN_ENUM is not set
# CONFIG_UBSAN_ALIGNMENT is not set
# CONFIG_TEST_UBSAN is not set
CONFIG_HAVE_ARCH_KCSAN=y
CONFIG_HAVE_KCSAN_COMPILER=y
# end of Generic Kernel Debugging Instruments

#
# Networking Debugging
#
CONFIG_NET_DEV_REFCNT_TRACKER=y
CONFIG_NET_NS_REFCNT_TRACKER=y
CONFIG_DEBUG_NET=y
# CONFIG_DEBUG_NET_SMALL_RTNL is not set
# end of Networking Debugging

#
# Memory Debugging
#
CONFIG_PAGE_EXTENSION=y
# CONFIG_DEBUG_PAGEALLOC is not set
CONFIG_SLUB_DEBUG=y
# CONFIG_SLUB_DEBUG_ON is not set
CONFIG_SLUB_RCU_DEBUG=y
CONFIG_PAGE_OWNER=y
CONFIG_PAGE_TABLE_CHECK=y
CONFIG_PAGE_TABLE_CHECK_ENFORCED=y
CONFIG_PAGE_POISONING=y
# CONFIG_DEBUG_PAGE_REF is not set
# CONFIG_DEBUG_RODATA_TEST is not set
CONFIG_ARCH_HAS_DEBUG_WX=y
CONFIG_DEBUG_WX=y
CONFIG_ARCH_HAS_PTDUMP=y
CONFIG_PTDUMP=y
CONFIG_PTDUMP_DEBUGFS=y
CONFIG_HAVE_DEBUG_KMEMLEAK=y
# CONFIG_DEBUG_KMEMLEAK is not set
# CONFIG_PER_VMA_LOCK_STATS is not set
CONFIG_DEBUG_OBJECTS=y
# CONFIG_DEBUG_OBJECTS_SELFTEST is not set
CONFIG_DEBUG_OBJECTS_FREE=y
CONFIG_DEBUG_OBJECTS_TIMERS=y
CONFIG_DEBUG_OBJECTS_WORK=y
CONFIG_DEBUG_OBJECTS_RCU_HEAD=y
CONFIG_DEBUG_OBJECTS_PERCPU_COUNTER=y
CONFIG_DEBUG_OBJECTS_ENABLE_DEFAULT=1
# CONFIG_SHRINKER_DEBUG is not set
CONFIG_DEBUG_STACK_USAGE=y
CONFIG_SCHED_STACK_END_CHECK=y
CONFIG_ARCH_HAS_DEBUG_VM_PGTABLE=y
CONFIG_DEBUG_VFS=y
CONFIG_DEBUG_VM_IRQSOFF=y
CONFIG_DEBUG_VM=y
CONFIG_DEBUG_VM_MAPLE_TREE=y
CONFIG_DEBUG_VM_RB=y
CONFIG_DEBUG_VM_PGFLAGS=y
CONFIG_DEBUG_VM_PGTABLE=y
CONFIG_ARCH_HAS_DEBUG_VIRTUAL=y
CONFIG_DEBUG_VIRTUAL=y
CONFIG_DEBUG_MEMORY_INIT=y
CONFIG_DEBUG_PER_CPU_MAPS=y
CONFIG_DEBUG_KMAP_LOCAL=y
CONFIG_ARCH_SUPPORTS_KMAP_LOCAL_FORCE_MAP=y
CONFIG_DEBUG_KMAP_LOCAL_FORCE_MAP=y
# CONFIG_MEM_ALLOC_PROFILING is not set
CONFIG_HAVE_ARCH_KASAN=y
CONFIG_HAVE_ARCH_KASAN_VMALLOC=y
CONFIG_CC_HAS_KASAN_GENERIC=y
CONFIG_CC_HAS_KASAN_SW_TAGS=y
CONFIG_CC_HAS_WORKING_NOSANITIZE_ADDRESS=y
CONFIG_KASAN=y
CONFIG_CC_HAS_KASAN_MEMINTRINSIC_PREFIX=y
CONFIG_KASAN_GENERIC=y
# CONFIG_KASAN_OUTLINE is not set
CONFIG_KASAN_INLINE=y
CONFIG_KASAN_STACK=y
CONFIG_KASAN_VMALLOC=y
# CONFIG_KASAN_EXTRA_INFO is not set
CONFIG_HAVE_ARCH_KFENCE=y
CONFIG_KFENCE=y
CONFIG_KFENCE_SAMPLE_INTERVAL=100
CONFIG_KFENCE_NUM_OBJECTS=255
# CONFIG_KFENCE_DEFERRABLE is not set
CONFIG_KFENCE_STATIC_KEYS=y
CONFIG_KFENCE_STRESS_TEST_FAULTS=0
CONFIG_HAVE_ARCH_KMSAN=y
CONFIG_HAVE_KMSAN_COMPILER=y
# end of Memory Debugging

# CONFIG_DEBUG_SHIRQ is not set

#
# Debug Oops, Lockups and Hangs
#
CONFIG_PANIC_ON_OOPS=y
CONFIG_PANIC_TIMEOUT=86400
CONFIG_LOCKUP_DETECTOR=y
CONFIG_SOFTLOCKUP_DETECTOR=y
# CONFIG_SOFTLOCKUP_DETECTOR_INTR_STORM is not set
CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC=1
CONFIG_HAVE_HARDLOCKUP_DETECTOR_BUDDY=y
CONFIG_HARDLOCKUP_DETECTOR=y
# CONFIG_HARDLOCKUP_DETECTOR_PREFER_BUDDY is not set
CONFIG_HARDLOCKUP_DETECTOR_PERF=y
# CONFIG_HARDLOCKUP_DETECTOR_BUDDY is not set
# CONFIG_HARDLOCKUP_DETECTOR_ARCH is not set
CONFIG_HARDLOCKUP_DETECTOR_COUNTS_HRTIMER=y
CONFIG_HARDLOCKUP_CHECK_TIMESTAMP=y
CONFIG_BOOTPARAM_HARDLOCKUP_PANIC=y
CONFIG_DETECT_HUNG_TASK=y
CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=140
CONFIG_BOOTPARAM_HUNG_TASK_PANIC=1
# CONFIG_DETECT_HUNG_TASK_BLOCKER is not set
CONFIG_WQ_WATCHDOG=y
CONFIG_BOOTPARAM_WQ_STALL_PANIC=0
# CONFIG_WQ_CPU_INTENSIVE_REPORT is not set
# CONFIG_TEST_LOCKUP is not set
# end of Debug Oops, Lockups and Hangs

#
# Scheduler Debugging
#
CONFIG_SCHED_INFO=y
CONFIG_SCHEDSTATS=y
# end of Scheduler Debugging

CONFIG_DEBUG_PREEMPT=y
# CONFIG_DEBUG_ATOMIC is not set

#
# Lock Debugging (spinlocks, mutexes, etc...)
#
CONFIG_LOCK_DEBUGGING_SUPPORT=y
CONFIG_PROVE_LOCKING=y
CONFIG_PROVE_RAW_LOCK_NESTING=y
# CONFIG_LOCK_STAT is not set
CONFIG_DEBUG_RT_MUTEXES=y
CONFIG_DEBUG_SPINLOCK=y
CONFIG_DEBUG_MUTEXES=y
CONFIG_DEBUG_WW_MUTEX_SLOWPATH=y
CONFIG_DEBUG_RWSEMS=y
CONFIG_DEBUG_LOCK_ALLOC=y
CONFIG_LOCKDEP=y
CONFIG_LOCKDEP_BITS=20
CONFIG_LOCKDEP_CHAINS_BITS=20
CONFIG_LOCKDEP_STACK_TRACE_BITS=20
CONFIG_LOCKDEP_STACK_TRACE_HASH_BITS=14
CONFIG_LOCKDEP_CIRCULAR_QUEUE_BITS=12
# CONFIG_DEBUG_LOCKDEP is not set
CONFIG_DEBUG_ATOMIC_SLEEP=y
# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set
# CONFIG_LOCK_TORTURE_TEST is not set
# CONFIG_WW_MUTEX_SELFTEST is not set
# CONFIG_SCF_TORTURE_TEST is not set
CONFIG_CSD_LOCK_WAIT_DEBUG=y
# CONFIG_CSD_LOCK_WAIT_DEBUG_DEFAULT is not set
# end of Lock Debugging (spinlocks, mutexes, etc...)

CONFIG_TRACE_IRQFLAGS=y
CONFIG_TRACE_IRQFLAGS_NMI=y
CONFIG_NMI_CHECK_CPU=y
CONFIG_DEBUG_IRQFLAGS=y
CONFIG_STACKTRACE=y
# CONFIG_DEBUG_KOBJECT is not set
# CONFIG_DEBUG_KOBJECT_RELEASE is not set

#
# Debug kernel data structures
#
CONFIG_DEBUG_LIST=y
CONFIG_DEBUG_PLIST=y
CONFIG_DEBUG_SG=y
CONFIG_DEBUG_NOTIFIERS=y
# CONFIG_DEBUG_CLOSURES is not set
CONFIG_DEBUG_MAPLE_TREE=y
# end of Debug kernel data structures

#
# RCU Debugging
#
CONFIG_PROVE_RCU=y
# CONFIG_RCU_SCALE_TEST is not set
# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_RCU_REF_SCALE_TEST is not set
CONFIG_RCU_CPU_STALL_TIMEOUT=100
CONFIG_RCU_EXP_CPU_STALL_TIMEOUT=0
# CONFIG_RCU_CPU_STALL_CPUTIME is not set
# CONFIG_RCU_TRACE is not set
CONFIG_RCU_EQS_DEBUG=y
# end of RCU Debugging

# CONFIG_DEBUG_WQ_FORCE_RR_CPU is not set
# CONFIG_CPU_HOTPLUG_STATE_CONTROL is not set
# CONFIG_LATENCYTOP is not set
CONFIG_USER_STACKTRACE_SUPPORT=y
CONFIG_NOP_TRACER=y
CONFIG_HAVE_RETHOOK=y
CONFIG_HAVE_FUNCTION_TRACER=y
CONFIG_HAVE_DYNAMIC_FTRACE=y
CONFIG_HAVE_DYNAMIC_FTRACE_WITH_REGS=y
CONFIG_HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS=y
CONFIG_HAVE_DYNAMIC_FTRACE_WITH_ARGS=y
CONFIG_HAVE_FTRACE_REGS_HAVING_PT_REGS=y
CONFIG_HAVE_DYNAMIC_FTRACE_NO_PATCHABLE=y
CONFIG_HAVE_DYNAMIC_FTRACE_WITH_JMP=y
CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
CONFIG_HAVE_FENTRY=y
CONFIG_HAVE_OBJTOOL_MCOUNT=y
CONFIG_HAVE_OBJTOOL_NOP_MCOUNT=y
CONFIG_HAVE_C_RECORDMCOUNT=y
CONFIG_HAVE_BUILDTIME_MCOUNT_SORT=y
CONFIG_TRACE_CLOCK=y
CONFIG_RING_BUFFER=y
CONFIG_EVENT_TRACING=y
CONFIG_CONTEXT_SWITCH_TRACER=y
CONFIG_PREEMPTIRQ_TRACEPOINTS=y
CONFIG_TRACING=y
CONFIG_GENERIC_TRACER=y
CONFIG_TRACING_SUPPORT=y
CONFIG_FTRACE=y
CONFIG_TRACEFS_AUTOMOUNT_DEPRECATED=y
# CONFIG_BOOTTIME_TRACING is not set
# CONFIG_FUNCTION_TRACER is not set
# CONFIG_STACK_TRACER is not set
# CONFIG_IRQSOFF_TRACER is not set
# CONFIG_PREEMPT_TRACER is not set
# CONFIG_SCHED_TRACER is not set
# CONFIG_HWLAT_TRACER is not set
# CONFIG_OSNOISE_TRACER is not set
# CONFIG_TIMERLAT_TRACER is not set
# CONFIG_MMIOTRACE is not set
# CONFIG_FTRACE_SYSCALLS is not set
# CONFIG_TRACER_SNAPSHOT is not set
CONFIG_BRANCH_PROFILE_NONE=y
# CONFIG_PROFILE_ANNOTATED_BRANCHES is not set
CONFIG_BLK_DEV_IO_TRACE=y
CONFIG_UPROBE_EVENTS=y
CONFIG_EPROBE_EVENTS=y
CONFIG_BPF_EVENTS=y
CONFIG_DYNAMIC_EVENTS=y
CONFIG_PROBE_EVENTS=y
# CONFIG_SYNTH_EVENTS is not set
# CONFIG_USER_EVENTS is not set
# CONFIG_HIST_TRIGGERS is not set
CONFIG_TRACE_EVENT_INJECT=y
# CONFIG_TRACEPOINT_BENCHMARK is not set
# CONFIG_RING_BUFFER_BENCHMARK is not set
# CONFIG_TRACE_EVAL_MAP_FILE is not set
# CONFIG_FTRACE_STARTUP_TEST is not set
# CONFIG_RING_BUFFER_STARTUP_TEST is not set
CONFIG_RING_BUFFER_VALIDATE_TIME_DELTAS=y
# CONFIG_RING_BUFFER_PERSISTENT_INJECT is not set
# CONFIG_PREEMPTIRQ_DELAY_TEST is not set
# CONFIG_RV is not set
# CONFIG_TRACE_REMOTE_TEST is not set
CONFIG_PROVIDE_OHCI1394_DMA_INIT=y
# CONFIG_SAMPLES is not set
CONFIG_HAVE_SAMPLE_FTRACE_DIRECT=y
CONFIG_HAVE_SAMPLE_FTRACE_DIRECT_MULTI=y
CONFIG_ARCH_HAS_DEVMEM_IS_ALLOWED=y
# CONFIG_STRICT_DEVMEM is not set

#
# x86 Debugging
#
CONFIG_EARLY_PRINTK_USB=y
CONFIG_X86_VERBOSE_BOOTUP=y
CONFIG_EARLY_PRINTK=y
CONFIG_EARLY_PRINTK_DBGP=y
# CONFIG_EARLY_PRINTK_USB_XDBC is not set
# CONFIG_DEBUG_TLBFLUSH is not set
CONFIG_HAVE_MMIOTRACE_SUPPORT=y
# CONFIG_X86_DECODER_SELFTEST is not set
CONFIG_IO_DELAY_0X80=y
# CONFIG_IO_DELAY_0XED is not set
# CONFIG_IO_DELAY_UDELAY is not set
# CONFIG_IO_DELAY_NONE is not set
CONFIG_DEBUG_BOOT_PARAMS=y
# CONFIG_CPA_DEBUG is not set
CONFIG_DEBUG_ENTRY=y
# CONFIG_DEBUG_NMI_SELFTEST is not set
CONFIG_X86_DEBUG_FPU=y
# CONFIG_PUNIT_ATOM_DEBUG is not set
CONFIG_UNWINDER_ORC=y
# CONFIG_UNWINDER_FRAME_POINTER is not set
# end of x86 Debugging

#
# Kernel Testing and Coverage
#
# CONFIG_KUNIT is not set
# CONFIG_NOTIFIER_ERROR_INJECTION is not set
CONFIG_FAULT_INJECTION=y
CONFIG_FAILSLAB=y
CONFIG_FAIL_PAGE_ALLOC=y
CONFIG_FAULT_INJECTION_USERCOPY=y
CONFIG_FAIL_MAKE_REQUEST=y
CONFIG_FAIL_IO_TIMEOUT=y
CONFIG_FAIL_FUTEX=y
CONFIG_FAULT_INJECTION_DEBUG_FS=y
# CONFIG_FAIL_MMC_REQUEST is not set
# CONFIG_FAIL_SKB_REALLOC is not set
CONFIG_FAULT_INJECTION_CONFIGFS=y
# CONFIG_FAULT_INJECTION_STACKTRACE_FILTER is not set
CONFIG_ARCH_HAS_KCOV=y
CONFIG_KCOV=y
CONFIG_KCOV_ENABLE_COMPARISONS=y
CONFIG_KCOV_INSTRUMENT_ALL=y
CONFIG_KCOV_IRQ_AREA_SIZE=0x40000
# CONFIG_KCOV_SELFTEST is not set
CONFIG_RUNTIME_TESTING_MENU=y
# CONFIG_TEST_DHRY is not set
# CONFIG_LKDTM is not set
# CONFIG_TEST_DIV64 is not set
# CONFIG_TEST_MULDIV64 is not set
# CONFIG_BACKTRACE_SELF_TEST is not set
# CONFIG_TEST_REF_TRACKER is not set
# CONFIG_RBTREE_TEST is not set
# CONFIG_REED_SOLOMON_TEST is not set
# CONFIG_INTERVAL_TREE_TEST is not set
# CONFIG_PERCPU_TEST is not set
# CONFIG_ATOMIC64_SELFTEST is not set
# CONFIG_ASYNC_RAID6_TEST is not set
# CONFIG_TEST_HEXDUMP is not set
# CONFIG_TEST_KSTRTOX is not set
# CONFIG_TEST_BITMAP is not set
# CONFIG_TEST_XARRAY is not set
# CONFIG_TEST_MAPLE_TREE is not set
# CONFIG_TEST_RHASHTABLE is not set
# CONFIG_TEST_IDA is not set
# CONFIG_TEST_LKM is not set
# CONFIG_TEST_BITOPS is not set
# CONFIG_TEST_VMALLOC is not set
# CONFIG_TEST_WORKQUEUE is not set
# CONFIG_TEST_BPF is not set
# CONFIG_FIND_BIT_BENCHMARK is not set
# CONFIG_TEST_FIRMWARE is not set
# CONFIG_TEST_SYSCTL is not set
# CONFIG_CONTEXT_ANALYSIS_TEST is not set
# CONFIG_TEST_UDELAY is not set
# CONFIG_TEST_STATIC_KEYS is not set
# CONFIG_TEST_DYNAMIC_DEBUG is not set
# CONFIG_TEST_KMOD is not set
# CONFIG_TEST_KALLSYMS is not set
# CONFIG_TEST_DEBUG_VIRTUAL is not set
# CONFIG_TEST_MEMCAT_P is not set
# CONFIG_TEST_MEMINIT is not set
# CONFIG_TEST_HMM is not set
# CONFIG_TEST_FREE_PAGES is not set
# CONFIG_TEST_CLOCKSOURCE_WATCHDOG is not set
# CONFIG_TEST_OBJPOOL is not set
CONFIG_ARCH_USE_MEMTEST=y
# CONFIG_MEMTEST is not set
# end of Kernel Testing and Coverage

#
# Rust hacking
#
# end of Rust hacking
# end of Kernel hacking

CONFIG_IO_URING_ZCRX=y
CONFIG_IO_URING_BPF=y
KernelRepo git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
ReproCID 0
ReproOpts
ReproSyzID 0
SyzkallerCommit 3c5eaa21b0dde97af48b7218aaad155b57ae3941
TargetArch amd64
TargetOS linux

Outputs:
Reproduced ✅
EquivalenceAnalysis
The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash.
OtherCrashReports
ReproC
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
ReproducedBugTitle
BUG: unable to handle kernel paging request in ioread32
ReproducedCrashReport
thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb

Crash report:
thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

Trajectory: (Expand/Collapse All)
Seq Timestamp Type Name Duration
0/0 2026/08/10 08:20 flow repro-c
27m Results:
map[EquivalenceAnalysis:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. OtherCrashReports:<nil> ReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
 Reproduced:true ReproducedBugTitle:BUG: unable to handle kernel paging request in ioread32 ReproducedCrashReport:thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb
]

1/1 2026/08/10 08:20 action kernel-checkouter
0m Results:
map[KernelSrc:/app/workdir/cache/src/23f34877926e4a8386855e646fda4dd9dccd99b9]

2/1 2026/08/10 08:20 action kernel-builder
0m Results:
map[KernelObj:/app/workdir/cache/build/a336c7a8629bc3d6298fba432a30764450022c13]

3/1 2026/08/10 08:20 action codesearch-prepare
0m Results:
map[Index:codesearch-index]

4/1 2026/08/10 08:20 agent initial-researcher
16m Model:
best-expensive

Instruction:
You are a security researcher with deep Linux kernel background.
Your goal is to analyze a Linux kernel bug description and propose a strategy to reproduce it
with a minimal, standalone C program for the strictly defensive purpose of verifying a bugfix.

=== TOOL SELECTION GUIDELINES ===
- When looking up C function or struct definitions, prefer codesearch-definition-source
  and codesearch-struct-layout first.
- Fall back to read-file or grepper only if symbol lookup fails or when inspecting macros,
  headers, or non-C files.

=== CRITICAL PROHIBITIONS ===
- Do NOT propose an exploit. Focus solely on minimal technical reproduction of the bug state.
- Do NOT write long explanations. Keep your analysis and strategy proposal concise.
- Do NOT assume that the target bug has already been fixed just because a git commit title
  or description mentions a similar bug or fix. Commit messages often reference related issues
  or partial fixes. Proceed with proposing a reproduction strategy regardless of historical fix commits.
Prefer calling several tools at the same time to save round-trips.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

Reply:
An analysis of the bug report and the kernel source code reveals that the crash is caused by an out-of-bounds memory access during the PCI probe of the Thunderbolt Native Host Interface (NHI) driver.

### Root Cause Analysis

1. **Missing BAR Size Validation**: 
   In `nhi_pci_probe()` (`drivers/thunderbolt/pci.c`), the driver maps the device's PCI BAR 0 using `pcim_iomap_region(pdev, 0, "thunderbolt")`. However, it never checks if the size of BAR 0 is large enough to cover the MMIO registers it expects to access.

2. **Out-of-Bounds Access**:
   The NHI driver expects a BAR size of at least `0x39948` bytes (to cover registers up to `REG_FW_STS` at `0x39944`). If a device with a small BAR 0 (e.g., 4KB) is bound to the driver, `ioremap` will only map that small region.
   When `nhi_probe()` is subsequently called, it attempts to read `REG_CAPS` at offset `0x39640`:
   ```c
   nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
   ```
   Because `0x39640` is far beyond the mapped 4KB region, this constitutes an out-of-bounds access.

3. **Crash Context**:
   In the syzkaller report, the initial OOB read at `0x39640` likely fell into another coincidentally mapped vmalloc page, returning garbage data. This garbage data allowed the driver to proceed to `nhi_reset()` (which timed out, printing `"timeout resetting host router"`) and then to `nhi_disable_interrupts()`. 
   `nhi_disable_interrupts()` then attempted to write to `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at offset `0x38208`. This offset fell into an unmapped vmalloc page, triggering the `#PF: supervisor write access in kernel mode` page fault in `iowrite32()`.

### Reproduction Strategy

To reproduce this bug, we need to trick the `thunderbolt` driver into probing a PCI device that has a memory BAR 0 smaller than `0x3a000`. We can achieve this from a standalone C program by abusing the sysfs `new_id` and `bind` interfaces to force the driver to bind to an existing, non-Thunderbolt PCI device with a small BAR.

1. **Scan PCI Devices**: Iterate through `/sys/bus/pci/devices/` to find a candidate PCI device.
2. **Filter Candidates**: 
   - Skip critical devices like Host/ISA bridges (Class `0x06xxxx`) and Mass Storage controllers (Class `0x01xxxx`) to prevent freezing the system or unmounting the rootfs.
   - Read the `resource` file to ensure BAR 0 is a memory BAR (`flags & IORESOURCE_MEM`) and its size is greater than 0 but strictly less than `0x39640`.
3. **Force Bind**:
   - Write the candidate device's name to its current driver's `unbind` file.
   - Write the candidate's Vendor and Device ID to `/sys/bus/pci/drivers/thunderbolt/new_id`.
   - Write the candidate's device name to `/sys/bus/pci/drivers/thunderbolt/bind`.
4. **Trigger**: The `thunderbolt` driver will probe the device, map its small BAR 0, and immediately perform an out-of-bounds MMIO access when reading/writing high-offset registers, reproducing the crash.

### Minimal C Reproducer Outline

```c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>

int main() {
    // Ensure the thunderbolt module is loaded
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) return 1;

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        fscanf(f, "%x", &class_code);
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start, end, flags;
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        if (size > 0 && size < 0x39640) {
            unsigned int vendor, device;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &vendor); fclose(f);

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &device); fclose(f);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            f = fopen(path, "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }

            // 2. Add ID to thunderbolt driver
            f = fopen("/sys/bus/pci/drivers/thunderbolt/new_id", "w");
            if (f) { fprintf(f, "%x %x", vendor, device); fclose(f); }

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            f = fopen("/sys/bus/pci/drivers/thunderbolt/bind", "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }
            
            // The kernel should panic here.
            break;
        }
    }
    closedir(dir);
    return 0;
}
```

5/2 2026/08/10 08:20 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 5635
							output: 37
							thoughts: 428
						

Thoughts:
**My Thought Process on the Thunderbolt Driver Kernel Crash**

Alright, I've got a kernel bug report in front of me: "BUG: unable to handle kernel paging request in iowrite32". This immediately flags a memory access issue within the kernel, specifically during an I/O write operation. The call trace points to the Thunderbolt (`nhi`) driver, and the crash occurs deep within the interrupt handling and probing functions (`nhi_mask_interrupt`, `nhi_disable_interrupts`, `nhi_probe`) and its PCI-specific probe function (`nhi_pci_probe`).

My first step is to dive into the relevant source files, `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/pci.c`. Given that this is a PCI driver probe, I'm looking at the sequence of events when the kernel attempts to initialize a Thunderbolt PCI device.

The bug report provides a crucial piece of context: the crash is triggered by a write to a sysfs `bind` file. This tells me that a user-space operation – specifically, a user trying to bind the Thunderbolt driver to a PCI device by writing to `/sys/bus/pci/drivers/.../bind` – is the catalyst. The target device is identified as a Thunderbolt host router.

The specific address causing the page fault is `ffffc90000f70208`. Initially, I might think of this as a Memory-Mapped I/O (MMIO) address, as `iowrite32` implies. However, a quick check reveals that this address range is actually characteristic of `vmalloc` or `ioremap` allocations. This raises a red flag: why would a properly `ioremap`ped or `vmalloc`ed address cause a page fault? Possible explanations immediately come to mind:
*   The PCI device might not have been correctly initialized before this memory region was accessed.
*   The `ioremap` call itself might have failed, leading to an invalid or unmapped address.
*   The PCI device might have been removed or become inaccessible *after* its memory region was mapped but *before* it was accessed by `iowrite32`.

Then, I see the preceding kernel log message: `thunderbolt 0000:00:07.0: timeout resetting host router`. This is a critical clue. It indicates that before the page fault occurred, the Thunderbolt host router was in a state where it timed out during a reset operation. This timeout strongly suggests a problem with the device itself or its communication.

Putting it all together, the sequence is likely this: a user attempts to bind the Thunderbolt driver to a device. During the driver's probe (`nhi_probe`), it tries to interact with the Thunderbolt host router. This interaction, likely involving a reset or some critical initialization step, fails with a timeout. Because of this failure, the device might be in an unstable state, or the memory mapping associated with it might have become invalid or unmapped. When `nhi_disable_interrupts` (called from `nhi_probe`) then attempts to perform an `iowrite32` to this (now problematic) address, the kernel triggers a page fault because the underlying memory is no longer valid or accessible, leading to the observed crash. My next step would be to meticulously examine the `nhi_probe` function to understand exactly how it handles device initialization, error conditions, and memory mapping in the face of such a timeout.


6/2 2026/08/10 08:20 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_probe]

Results:
map[SourceCode:1186:	int nhi_probe(struct tb_nhi *nhi)
1187:	{
1188:		struct device *dev = nhi->dev;
1189:		struct tb *tb;
1190:		int res;
1191:	
1192:		if (!nhi->ops)
1193:			return dev_err_probe(dev, -EINVAL, "NHI ops not set\n");
1194:	
1195:		if (!nhi->ops->init_interrupts)
1196:			return dev_err_probe(dev, -EINVAL, "missing required NHI ops\n");
1197:	
1198:		nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
1199:		dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
1200:	
1201:		nhi->tx_rings = devm_kcalloc(dev, nhi->hop_count,
1202:					     sizeof(*nhi->tx_rings), GFP_KERNEL);
1203:		nhi->rx_rings = devm_kcalloc(dev, nhi->hop_count,
1204:					     sizeof(*nhi->rx_rings), GFP_KERNEL);
1205:		if (!nhi->tx_rings || !nhi->rx_rings)
1206:			return -ENOMEM;
1207:	
1208:		nhi_reset(nhi);
1209:	
1210:		/* In case someone left them on. */
1211:		nhi_disable_interrupts(nhi);
1212:	
1213:		res = nhi->ops->init_interrupts(nhi);
1214:		if (res)
1215:			return dev_err_probe(dev, res, "cannot enable interrupts, aborting\n");
1216:	
1217:		spin_lock_init(&nhi->lock);
1218:	
1219:		res = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64));
1220:		if (res)
1221:			return dev_err_probe(dev, res, "failed to set DMA mask\n");
1222:	
1223:		if (nhi->ops->init) {
1224:			res = nhi->ops->init(nhi);
1225:			if (res)
1226:				return dev_err_probe(dev, res, "NHI specific init failed\n");
1227:		}
1228:	
1229:		tb = nhi_select_cm(nhi);
1230:		if (!tb)
1231:			return dev_err_probe(dev, -ENODEV,
1232:				"failed to determine connection manager, aborting\n");
1233:	
1234:		dev_dbg(dev, "NHI initialized, starting thunderbolt\n");
1235:	
1236:		init_completion(&nhi->domain_released);
1237:	
1238:		res = tb_domain_add(tb, host_reset);
1239:		if (res) {
1240:			/*
1241:			 * At this point the RX/TX rings might already have been
1242:			 * activated. Do a proper shutdown.
1243:			 */
1244:			tb_domain_put(tb);
1245:			wait_for_completion(&nhi->domain_released);
1246:			nhi_shutdown(nhi);
1247:			return dev_err_probe(dev, res, "failed to add domain\n");
1248:		}
1249:		dev_set_drvdata(dev, tb);
1250:	
1251:		device_wakeup_enable(dev);
1252:	
1253:		pm_runtime_allow(dev);
1254:		pm_runtime_set_autosuspend_delay(dev, TB_AUTOSUSPEND_DELAY);
1255:		pm_runtime_use_autosuspend(dev);
1256:		pm_runtime_put_autosuspend(dev);
1257:	
1258:		return 0;
1259:	}
 SourceFile:drivers/thunderbolt/nhi.c]

7/2 2026/08/10 08:20 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7283
							output: 37
							thoughts: 77
						

Thoughts:
**My Diagnostic Journey**

I've been wrestling with this crash, and I think I've pinpointed its origin. My initial dive into the logs pointed me towards `nhi_disable_interrupts(nhi);` at line 1211 as the immediate culprit, where the system finally gave up. However, I'm not convinced that's the root cause. My gut, and the specific timeout message – `thunderbolt 0000:00:07.0: timeout resetting host router` – are strongly suggesting that the actual problem begins a few lines earlier, likely within the `nhi_reset(nhi);` function at line 1208. It seems the attempt to reset the host router is what's failing, and the subsequent disabling of interrupts is just a downstream consequence of that initial failure. This leads me to believe I need to focus my debugging efforts on the logic within `nhi_reset`.


8/2 2026/08/10 08:20 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_reset]

Results:
map[SourceCode:1132:	static void nhi_reset(struct tb_nhi *nhi)
1133:	{
1134:		ktime_t timeout;
1135:		u32 val;
1136:	
1137:		val = ioread32(nhi->iobase + REG_CAPS);
1138:		/* Reset only v2 and later routers */
1139:		if (FIELD_GET(REG_CAPS_VERSION_MASK, val) < REG_CAPS_VERSION_2)
1140:			return;
1141:	
1142:		if (!host_reset) {
1143:			dev_dbg(nhi->dev, "skipping host router reset\n");
1144:			return;
1145:		}
1146:	
1147:		iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
1148:		msleep(100);
1149:	
1150:		timeout = ktime_add_ms(ktime_get(), 500);
1151:		do {
1152:			val = ioread32(nhi->iobase + REG_RESET);
1153:			if (!(val & REG_RESET_HRR)) {
1154:				dev_warn(nhi->dev, "host router reset successful\n");
1155:				return;
1156:			}
1157:			usleep_range(10, 20);
1158:		} while (ktime_before(ktime_get(), timeout));
1159:	
1160:		dev_warn(nhi->dev, "timeout resetting host router\n");
1161:	}
 SourceFile:drivers/thunderbolt/nhi.c]

9/2 2026/08/10 08:20 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7876
							output: 40
							thoughts: 59
						

Thoughts:
**My Thought Process Regarding `nhi_reset` and Subsequent Interrupt Handling**

It's quite perplexing, really. I've noticed that when the `nhi_reset` function encounters a timeout while attempting to reset the host router, it simply outputs a message stating "timeout resetting host router." What's particularly concerning is that this timeout condition doesn't translate into an actual error return value from the function. Instead, it appears to proceed as if everything is fine, merely issuing a warning and continuing its execution flow. This lack of explicit error signaling is a significant point of concern for me, as it masks a critical failure.

Following this, I've observed that the `nhi_probe` function then proceeds to call `nhi_disable_interrupts(nhi);`. Given that `nhi_reset` might have failed silently due to a timeout, the subsequent disabling of interrupts feels like a potentially dangerous assumption. If the host router wasn't properly reset, disabling its interrupts could lead to an unstable or unpredictable system state. I need to understand the downstream implications of this. Is there an expectation that `nhi_reset` will *always* succeed, or is there a robust error-handling path that is being missed when the timeout occurs? The current behavior seems to imply a trust in the reset that might not be warranted, and this has significant implications for the overall reliability of the system's interrupt management.


10/2 2026/08/10 08:21 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_disable_interrupts]

Results:
map[SourceCode: 152:	/*
 153:	 * nhi_disable_interrupts() - disable interrupts for all rings
 154:	 *
 155:	 * Use only during init and shutdown.
 156:	 */
 157:	void nhi_disable_interrupts(struct tb_nhi *nhi)
 158:	{
 159:		int i = 0;
 160:		/* disable interrupts */
 161:		for (i = 0; i < RING_INTERRUPT_REG_COUNT(nhi); i++)
 162:			nhi_mask_interrupt(nhi, ~0, 4 * i);
 163:	
 164:		/* clear interrupt status bits */
 165:		for (i = 0; i < RING_NOTIFY_REG_COUNT(nhi); i++)
 166:			nhi_clear_interrupt(nhi, 4 * i);
 167:	}
 SourceFile:drivers/thunderbolt/nhi.c]

11/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 8239
							output: 39
							thoughts: 12
						

Thoughts:
**My Thought Process on `nhi_mask_interrupt`**

Right, so the immediate impulse is to dive into the `nhi_mask_interrupt` function. I need to get a clear understanding of exactly *what* it's doing and *how* it's achieving it. This isn't just about a surface-level glance; as an expert, I'm looking for the nuances, the underlying mechanisms, and potential implications. I'll be dissecting its purpose – is it purely for disabling interrupts from a specific source (the "nhi" part)? Or does it involve more complex interrupt management, like acknowledging, clearing, or prioritizing?

My next step will be to scrutinize the implementation details. I'll be paying close attention to any bit manipulation, register accesses, or calls to other kernel functions. Are there any flags being set or cleared? Is there a specific interrupt controller being interacted with? I'll also be looking for any concurrency considerations – is this function designed to be called from multiple contexts simultaneously? If so, how is it ensuring atomicity and preventing race conditions?

Beyond the mechanics, I'll be considering the broader context. Where is `nhi_mask_interrupt` being invoked? What are the conditions under which it's called? Understanding its callers and the scenarios that trigger it is crucial for assessing its impact on system behavior. Is it part of error handling, normal operation, or a specific optimization path?

Finally, and this is where the "expert" lens really comes into play, I'll be thinking about potential side effects and optimizations. Could this function be inadvertently masking other, unrelated interrupts? Are there more efficient ways to achieve the same masking behavior, perhaps by leveraging hardware capabilities more directly or by using more generalized interrupt handling primitives? I'll also be considering its performance implications – how much overhead does this function introduce, and is that overhead acceptable given its purpose?


12/2 2026/08/10 08:21 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_mask_interrupt]

Results:
map[SourceCode:  51:	static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
  52:	{
  53:		if (nhi->quirks & QUIRK_AUTO_CLEAR_INT) {
  54:			u32 val;
  55:	
  56:			val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  57:			iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  58:		} else {
  59:			iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
  60:		}
  61:	}
 SourceFile:drivers/thunderbolt/nhi.c]

13/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 8504
							output: 40
							thoughts: 208
						

Thoughts:
**My Investigation into the `iowrite32` Crash**

Alright, so I've narrowed down the crash. It's happening specifically within the `iowrite32` function, and more precisely, within the `nhi_mask_interrupt` routine. My first question is, why is `iowrite32` even crashing? This function is supposed to be a straightforward memory-mapped I/O write.

I'm looking at the address it's trying to write to: `ffffc90000f70208`. Now, I can see how this address is derived. It's either `nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring` or `nhi->iobase + REG_RING_INTERRUPT_BASE + ring`. This immediately suggests that the problem might lie with `nhi->iobase` itself, or the underlying hardware region it represents.

My next thought is about the context. The crash occurred after `nhi_reset` timed out. This timeout is a significant clue. Could it be that the device was removed from the PCI bus *during* the reset process? Or, perhaps more critically, was the Memory-Mapped I/O (MMIO) region associated with `nhi->iobase` unmapped before this write attempt?

Then, a key realization hits me: this is likely a syzkaller-induced bug. Syzkaller is known for its ability to inject and manipulate devices. If syzkaller is *injecting* a PCI device, it has the capability to remove that device concurrently, or even manipulate its resources in ways that would lead to an invalid `nhi->iobase`.

So, the core issue seems to be that `nhi->iobase` is no longer valid, likely because the underlying MMIO region was unmapped or the device itself was removed. To confirm this, I need to dive into where `nhi->iobase` is actually mapped in the first place. My next step is to examine the `nhi_pci_probe` function, as that's where the initial mapping and setup should occur. I need to understand the lifecycle of that mapping and how it could become invalid, especially in the context of a race condition with device removal.


14/2 2026/08/10 08:21 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

15/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 9369
							output: 42
							thoughts: 240
						

Thoughts:
**My Investigation into the Thunderbolt NHI Crash**

I'm currently trying to understand why my system is crashing with a page fault, specifically at `ffffc90000f70208`, indicating a supervisor write access to a non-present page. My initial thoughts led me to the `nhi->iobase` mapping, which is established via `pcim_iomap_region(pdev, 0, "thunderbolt");`. If this function call succeeds, `nhi->iobase` should indeed be a valid, remapped I/O address. So, the question is, how can such a seemingly valid address become unmapped, leading to this fault?

My first hypothesis was whether the PCI device itself might have been removed or detached *after* `pcim_iomap_region` was called but *before* the fault occurred. This could potentially lead to the region being unmapped. However, this seems unlikely given that the crash is occurring during the `nhi_pci_probe` function, suggesting the device should still be considered present and actively being probed.

Then, I reconsidered the `pcim_iomap_region` function's role. It's responsible for mapping the I/O region. If that mapping is valid, the problem must lie elsewhere. My attention then turned to potential access issues within the code that *uses* `nhi->iobase`. I'm specifically wondering if it's possible that `RING_INTERRUPT_REG_COUNT(nhi)` could be returning an unexpectedly large value. If this value is indeed excessively large, it could cause a `ring` access to go out of bounds of the *actually mapped* region, even if `nhi->iobase` itself points to a valid starting address. Therefore, my next step is to thoroughly examine the `RING_INTERRUPT_REG_COUNT` macro and its behavior in this context.


16/2 2026/08/10 08:21 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:RING_INTERRUPT_REG_COUNT]

Results:
map[SourceCode: SourceFile:]

17/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 9656
							output: 25
							thoughts: 15
						

Thoughts:
**My Thought Process:**

My immediate reaction upon encountering this piece of code or data is recognition: "Ah, it's a macro." This tells me I'm likely dealing with a predefined set of instructions or a template that will be expanded or interpreted by a specific system or language. The next logical step, born from this initial identification, is to investigate further. My immediate inclination is to "search for it." This means I need to understand its context, its definition, and its purpose. This search will likely involve looking for its declaration, its usage elsewhere in the codebase or system, and any associated documentation or comments that can shed light on what this macro *does*. Essentially, I'm initiating a diagnostic and investigative process to fully comprehend this macro's role and impact.


18/2 2026/08/10 08:21 tool grepper
0m Args:
map[Expression:#define RING_INTERRUPT_REG_COUNT]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-99-#define REG_RING_INTERRUPT_BASE	0x38200
drivers/thunderbolt/nhi_regs.h:100:#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
drivers/thunderbolt/nhi_regs.h-101-
]

19/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 9819
							output: 29
							thoughts: 306
						

Thoughts:
**My Thought Process Regarding Interrupt Register Configuration**

Okay, let me trace through my thinking here about these interrupt registers. I'm looking at this macro, `RING_INTERRUPT_REG_COUNT(nhi)`, and it's defined as `((31 + 2 * nhi->hop_count) / 32)`. The critical piece here is `nhi->hop_count`, which I know is derived from reading the `REG_CAPS` register: `nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;`.

Now, a key piece of information I've ascertained is that `REG_CAPS` has an offset of `0x00`. This is important because it tells me where to look in the memory-mapped I/O space. The `& 0x3ff` mask means `nhi->hop_count` can range from 0 up to 1023 (0x3ff).

So, if `nhi->hop_count` reaches its maximum of 1023, plugging that into the `RING_INTERRUPT_REG_COUNT` macro gives me `(31 + 2 * 1023) / 32`. That simplifies to `(31 + 2046) / 32`, which results in `2077 / 32`. Performing that division, I get a value very close to 65, and since it's integer division, it rounds down to `64`. This means `RING_INTERRUPT_REG_COUNT` will be at most 64.

This number, 64, is significant because it dictates the number of iterations in a loop within the `nhi_disable_interrupts` function. That loop looks like this: `for (i = 0; i < RING_INTERRUPT_REG_COUNT(nhi); i++) { nhi_mask_interrupt(nhi, ~0, 4 * i); }`.

Inside this loop, the `nhi_mask_interrupt` function is called. It performs a write operation to `nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`. The `ring` part here is derived from `4 * i`, meaning it's an offset that increments in steps of 4 bytes. My initial estimate, based on common register layouts, is that `REG_RING_INTERRUPT_MASK_CLEAR_BASE` is likely located somewhere around the `0x38200` mark. My next logical step is to verify the exact offset of `REG_RING_INTERRUPT_MASK_CLEAR_BASE` to confirm the memory addresses being written to.


20/2 2026/08/10 08:21 tool grepper
0m Args:
map[Expression:#define REG_RING_INTERRUPT_MASK_CLEAR_BASE]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-101-
drivers/thunderbolt/nhi_regs.h:102:#define REG_RING_INTERRUPT_MASK_CLEAR_BASE	0x38208
drivers/thunderbolt/nhi_regs.h-103-
]

21/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 10250
							output: 40
							thoughts: 347
						

Thoughts:
**My Thought Process Regarding the Potential Out-of-Bounds Access**

Here's how I've been dissecting this issue:

I started by analyzing the core access pattern: the offset calculation is `0x38208 + 4 * i`. My immediate thought was to consider the maximum value `i` can reach. Given that `i` can go up to 64, the highest offset I calculated was `0x38208 + 256`, which equates to `0x38308`.

This raised a critical question in my mind: what is the actual size of PCI BAR 0? My concern was that if this BAR is smaller than `0x38308`, then the `ioremap` operation, which is responsible for mapping this I/O region into the kernel's address space, would only map the actual size of the BAR.

The implication of this is significant. If the mapped region is smaller than the maximum potential offset, then when the `nhi_mask_interrupt` function attempts to access `nhi->iobase + 0x38208`, it could very well be performing an access *outside* the bounds of the memory that was successfully mapped. This is a classic recipe for a crash or, worse, a security vulnerability.

To address this, I immediately looked at how the BAR is being mapped. I noted the call to `pcim_iomap_region(pdev, 0, "thunderbolt");`. My understanding is that this function, when called without a specific size argument, is intended to map the *entire* BAR 0.

However, my concern resurfaced when considering the context of syzkaller. I realized that syzkaller could be instrumental in creating a virtual PCI device where the BAR 0 is deliberately configured to be small, for example, just 4KB. In such a scenario, `ioremap` would indeed only map that 4KB region.

Then, I traced the execution flow. The `nhi_probe` function, in this hypothetical small BAR scenario, would first read `nhi->hop_count` from offset 0, which is safely within the 4KB mapping. But the critical failure point occurs immediately after, when it attempts to write to offset `0x38208`. This offset, at 229 KB, is *vastly* out of bounds for a 4KB mapping.

This led me to a deeper dive into `pcimim_iomap_region` itself. I re-checked its behavior, and my understanding is that it actually maps `pci_resource_len(pdev, 0)`. This confirms my fear: if `pci_resource_len` reports a small size, then `ioremap` will indeed map a small region.

My final, pressing question then became: is there any explicit check within `nhi_pci_probe` to validate the size of the BAR *before* attempting these potentially out-of-bounds accesses? This is the crucial piece of information I need to ascertain whether this potential vulnerability is indeed present in the code.


22/2 2026/08/10 08:21 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

23/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 11254
							output: 18
							thoughts: 390
						

Thoughts:
**BAR Size Oversight and Necessary Checks**

I've just realized a critical oversight in my current implementation: there's no validation for the size of the BAR (Base Address Register). This is problematic because if `pci_resource_len(pdev, 0)`, which represents the actual BAR size, is smaller than the maximum register offset my driver attempts to access (which I've identified as `0x39000`), I'm going to end up with an out-of-bounds access. That's a recipe for disaster.

My immediate thought is to determine the *minimum* required BAR size for the Thunderbolt NHI (Network Host Interface). I need to ensure all potential register accesses are covered. I've been looking at specific register definitions. `REG_RING_INTERRUPT_MASK_CLEAR_BASE` is located at `0x38208`, and `REG_RING_NOTIFY_BASE` is at `0x37800`. This suggests that the BAR must be at least large enough to accommodate these, with some buffer. Specifically, `0x38208 + 4 * 64 = 0x38308` seems like a necessary minimum size.

However, I need to be more precise. The maximum offset isn't a fixed value; it's dynamic and depends on `nhi->hop_count`. Let's break this down. The formula for `RING_INTERRUPT_REG_COUNT` seems to be `(31 + 2 * nhi->hop_count) / 32`.
If `nhi->hop_count` is 0, this results in `(31 + 0) / 32 = 0`.
If `nhi->hop_count` is 1, it's `(31 + 2) / 32 = 1`.
And if `nhi->hop_count` reaches its maximum of `0x3ff` (1023), then `(31 + 2 * 1023) / 32 = (31 + 2046) / 32 = 2077 / 32`, which rounds down to 64.
Therefore, the *absolute maximum* register offset I might access is `0x38208 + 4 * 64 = 0x38308`.

This analysis of `nhi->hop_count` is crucial. I need to make sure that the BAR size is validated against this calculated maximum offset. I should also double-check the `nhi_regs.h` header file to confirm there are no other registers or structures that I might be accessing beyond this calculated maximum, as that would necessitate an even larger minimum BAR size. This is a critical security and stability concern that needs immediate attention.


24/2 2026/08/10 08:21 tool grepper
0m Args:
map[Expression:#define REG_]

Results:
map[Output:
Full output is too long, showing 500 out of 22435 lines.
Use more precise expression if possible.

arch/alpha/kernel/pc873xx.h-8- */
arch/alpha/kernel/pc873xx.h:9:#define REG_FER	0x00
arch/alpha/kernel/pc873xx.h:10:#define REG_FAR	0x01
arch/alpha/kernel/pc873xx.h:11:#define REG_PTR	0x02
arch/alpha/kernel/pc873xx.h:12:#define REG_FCR	0x03
arch/alpha/kernel/pc873xx.h:13:#define REG_PCR	0x04
arch/alpha/kernel/pc873xx.h:14:#define REG_KRR	0x05
arch/alpha/kernel/pc873xx.h:15:#define REG_PMC	0x06
arch/alpha/kernel/pc873xx.h:16:#define REG_TUP	0x07
arch/alpha/kernel/pc873xx.h:17:#define REG_SID	0x08
arch/alpha/kernel/pc873xx.h:18:#define REG_ASC	0x09
arch/alpha/kernel/pc873xx.h:19:#define REG_IRC	0x0e
arch/alpha/kernel/pc873xx.h-20-
--
arch/arc/include/asm/disasm.h=22=enum flow {
--
arch/arc/include/asm/disasm.h-71-#define STATUS32_L		0x00000100
arch/arc/include/asm/disasm.h:72:#define REG_LIMM		62
arch/arc/include/asm/disasm.h-73-
--
arch/arc/kernel/ptrace.c=15=struct pt_regs_offset {
--
arch/arc/kernel/ptrace.c-19-
arch/arc/kernel/ptrace.c:20:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/arc/kernel/ptrace.c:21:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arc/kernel/ptrace.c-22-
--
arch/arc/kernel/ptrace.c=161=static int genregs_set(struct task_struct *target,
--
arch/arc/kernel/ptrace.c-169-
arch/arc/kernel/ptrace.c:170:#define REG_IN_CHUNK(FIRST, NEXT, PTR)	\
arch/arc/kernel/ptrace.c-171-	if (!ret)			\
--
arch/arc/kernel/ptrace.c-176-
arch/arc/kernel/ptrace.c:177:#define REG_IN_ONE(LOC, PTR)		\
arch/arc/kernel/ptrace.c-178-	if (!ret)			\
--
arch/arc/kernel/ptrace.c-183-
arch/arc/kernel/ptrace.c:184:#define REG_IGNORE_ONE(LOC)		\
arch/arc/kernel/ptrace.c-185-	if (!ret)			\
--
arch/arc/kernel/unwind.c=56=UNW_REGISTER_INFO};
--
arch/arc/kernel/unwind.c-61-#ifndef REG_INVALID
arch/arc/kernel/unwind.c:62:#define REG_INVALID(r) (reg_info[r].width == 0)
arch/arc/kernel/unwind.c-63-#endif
--
arch/arc/net/bpf_jit_arcv2.c=65=static const u8 bpf2arc[][2] = {
--
arch/arc/net/bpf_jit_arcv2.c-90-
arch/arc/net/bpf_jit_arcv2.c:91:#define REG_LO(r) (bpf2arc[(r)][0])
arch/arc/net/bpf_jit_arcv2.c:92:#define REG_HI(r) (bpf2arc[(r)][1])
arch/arc/net/bpf_jit_arcv2.c-93-
--
arch/arm/include/debug/brcmstb.S-6-/* Physical register offset and virtual register offset */
arch/arm/include/debug/brcmstb.S:7:#define REG_PHYS_BASE		0xf0000000
arch/arm/include/debug/brcmstb.S:8:#define REG_PHYS_BASE_V7	0x08000000
arch/arm/include/debug/brcmstb.S:9:#define REG_VIRT_BASE		0xfc000000
arch/arm/include/debug/brcmstb.S:10:#define REG_PHYS_ADDR(x)	((x) + REG_PHYS_BASE)
arch/arm/include/debug/brcmstb.S:11:#define REG_PHYS_ADDR_V7(x)	((x) + REG_PHYS_BASE_V7)
arch/arm/include/debug/brcmstb.S-12-
--
arch/arm/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/arm/kernel/perf_regs.c-18-
arch/arm/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_ARM_MAX) - 1))
arch/arm/kernel/perf_regs.c-20-
--
arch/arm/kernel/ptrace.c-32-
arch/arm/kernel/ptrace.c:33:#define REG_PC	15
arch/arm/kernel/ptrace.c:34:#define REG_PSR	16
arch/arm/kernel/ptrace.c-35-/*
--
arch/arm/kernel/ptrace.c=59=struct pt_regs_offset {
--
arch/arm/kernel/ptrace.c-63-
arch/arm/kernel/ptrace.c:64:#define REG_OFFSET_NAME(r) \
arch/arm/kernel/ptrace.c-65-	{.name = #r, .offset = offsetof(struct pt_regs, ARM_##r)}
arch/arm/kernel/ptrace.c:66:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arm/kernel/ptrace.c-67-
--
arch/arm/mach-exynos/firmware.c=216=void __init exynos_firmware_init(void)
--
arch/arm/mach-exynos/firmware.c-237-
arch/arm/mach-exynos/firmware.c:238:#define REG_CPU_STATE_ADDR	(sysram_ns_base_addr + 0x28)
arch/arm/mach-exynos/firmware.c-239-#define BOOT_MODE_MASK		0x1f
--
arch/arm/mach-exynos/suspend.c-35-
arch/arm/mach-exynos/suspend.c:36:#define REG_TABLE_END (-1U)
arch/arm/mach-exynos/suspend.c-37-
--
arch/arm/mach-hisi/platsmp.c=129=static const struct smp_operations hix5hd2_smp_ops __initconst = {
--
arch/arm/mach-hisi/platsmp.c-139-#define HIP01_BOOT_ADDRESS     0x80000000
arch/arm/mach-hisi/platsmp.c:140:#define REG_SC_CTRL            0x000
arch/arm/mach-hisi/platsmp.c-141-
--
arch/arm/mach-imx/anatop.c-15-
arch/arm/mach-imx/anatop.c:16:#define REG_SET		0x4
arch/arm/mach-imx/anatop.c:17:#define REG_CLR		0x8
arch/arm/mach-imx/anatop.c-18-
--
arch/arm/mach-omap2/omap_twl.c=40=static u8 smps_offset;
arch/arm/mach-omap2/omap_twl.c-41-
arch/arm/mach-omap2/omap_twl.c:42:#define REG_SMPS_OFFSET         0xE0
arch/arm/mach-omap2/omap_twl.c-43-
--
arch/arm/nwfpe/fpmodule.h-14-
arch/arm/nwfpe/fpmodule.h:15:#define REG_ORIG_R0	17
arch/arm/nwfpe/fpmodule.h:16:#define REG_CPSR	16
arch/arm/nwfpe/fpmodule.h:17:#define REG_PC		15
arch/arm/nwfpe/fpmodule.h:18:#define REG_LR		14
arch/arm/nwfpe/fpmodule.h:19:#define REG_SP		13
arch/arm/nwfpe/fpmodule.h:20:#define REG_IP		12
arch/arm/nwfpe/fpmodule.h:21:#define REG_FP		11
arch/arm/nwfpe/fpmodule.h:22:#define REG_R10		10
arch/arm/nwfpe/fpmodule.h:23:#define REG_R9		9
arch/arm/nwfpe/fpmodule.h:24:#define REG_R9		9
arch/arm/nwfpe/fpmodule.h:25:#define REG_R8		8
arch/arm/nwfpe/fpmodule.h:26:#define REG_R7		7
arch/arm/nwfpe/fpmodule.h:27:#define REG_R6		6
arch/arm/nwfpe/fpmodule.h:28:#define REG_R5		5
arch/arm/nwfpe/fpmodule.h:29:#define REG_R4		4
arch/arm/nwfpe/fpmodule.h:30:#define REG_R3		3
arch/arm/nwfpe/fpmodule.h:31:#define REG_R2		2
arch/arm/nwfpe/fpmodule.h:32:#define REG_R1		1
arch/arm/nwfpe/fpmodule.h:33:#define REG_R0		0
arch/arm/nwfpe/fpmodule.h-34-
--
arch/arm64/kernel/perf_regs.c=30=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/arm64/kernel/perf_regs.c-77-
arch/arm64/kernel/perf_regs.c:78:#define REG_RESERVED (~((1ULL << PERF_REG_ARM64_MAX) - 1))
arch/arm64/kernel/perf_regs.c-79-
--
arch/arm64/kernel/ptrace.c=48=struct pt_regs_offset {
--
arch/arm64/kernel/ptrace.c-52-
arch/arm64/kernel/ptrace.c:53:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/arm64/kernel/ptrace.c:54:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arm64/kernel/ptrace.c-55-#define GPR_OFFSET_NAME(r) \
--
arch/arm64/kvm/sys_regs.h=62=struct sys_reg_desc {
--
arch/arm64/kvm/sys_regs.h-106-
arch/arm64/kvm/sys_regs.h:107:#define REG_HIDDEN		(1 << 0) /* hidden from userspace and guest */
arch/arm64/kvm/sys_regs.h:108:#define REG_RAZ			(1 << 1) /* RAZ from userspace and guest */
arch/arm64/kvm/sys_regs.h:109:#define REG_USER_WI		(1 << 2) /* WI from userspace only */
arch/arm64/kvm/sys_regs.h-110-
--
arch/csky/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/csky/kernel/perf_regs.c-18-
arch/csky/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_CSKY_MAX) - 1))
arch/csky/kernel/perf_regs.c-20-
--
arch/csky/kernel/ptrace.c=198=struct pt_regs_offset {
--
arch/csky/kernel/ptrace.c-202-
arch/csky/kernel/ptrace.c:203:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/csky/kernel/ptrace.c:204:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/csky/kernel/ptrace.c-205-
--
arch/loongarch/include/asm/asm.h-54-#if (SZREG == 4)
arch/loongarch/include/asm/asm.h:55:#define REG_L		ld.w
arch/loongarch/include/asm/asm.h:56:#define REG_S		st.w
arch/loongarch/include/asm/asm.h:57:#define REG_ADD		add.w
arch/loongarch/include/asm/asm.h:58:#define REG_SUB		sub.w
arch/loongarch/include/asm/asm.h-59-#else /* SZREG == 8 */
arch/loongarch/include/asm/asm.h:60:#define REG_L		ld.d
arch/loongarch/include/asm/asm.h:61:#define REG_S		st.d
arch/loongarch/include/asm/asm.h:62:#define REG_ADD		add.d
arch/loongarch/include/asm/asm.h:63:#define REG_SUB		sub.d
arch/loongarch/include/asm/asm.h-64-#endif
--
arch/loongarch/include/asm/loongarch.h-22-/* LoongArch Registers */
arch/loongarch/include/asm/loongarch.h:23:#define REG_ZERO	0x0
arch/loongarch/include/asm/loongarch.h:24:#define REG_RA		0x1
arch/loongarch/include/asm/loongarch.h:25:#define REG_TP		0x2
arch/loongarch/include/asm/loongarch.h:26:#define REG_SP		0x3
arch/loongarch/include/asm/loongarch.h:27:#define REG_A0		0x4 /* Reused as V0 for return value */
arch/loongarch/include/asm/loongarch.h:28:#define REG_A1		0x5 /* Reused as V1 for return value */
arch/loongarch/include/asm/loongarch.h:29:#define REG_A2		0x6
arch/loongarch/include/asm/loongarch.h:30:#define REG_A3		0x7
arch/loongarch/include/asm/loongarch.h:31:#define REG_A4		0x8
arch/loongarch/include/asm/loongarch.h:32:#define REG_A5		0x9
arch/loongarch/include/asm/loongarch.h:33:#define REG_A6		0xa
arch/loongarch/include/asm/loongarch.h:34:#define REG_A7		0xb
arch/loongarch/include/asm/loongarch.h:35:#define REG_T0		0xc
arch/loongarch/include/asm/loongarch.h:36:#define REG_T1		0xd
arch/loongarch/include/asm/loongarch.h:37:#define REG_T2		0xe
arch/loongarch/include/asm/loongarch.h:38:#define REG_T3		0xf
arch/loongarch/include/asm/loongarch.h:39:#define REG_T4		0x10
arch/loongarch/include/asm/loongarch.h:40:#define REG_T5		0x11
arch/loongarch/include/asm/loongarch.h:41:#define REG_T6		0x12
arch/loongarch/include/asm/loongarch.h:42:#define REG_T7		0x13
arch/loongarch/include/asm/loongarch.h:43:#define REG_T8		0x14
arch/loongarch/include/asm/loongarch.h:44:#define REG_U0		0x15 /* Kernel uses it as percpu base */
arch/loongarch/include/asm/loongarch.h:45:#define REG_FP		0x16
arch/loongarch/include/asm/loongarch.h:46:#define REG_S0		0x17
arch/loongarch/include/asm/loongarch.h:47:#define REG_S1		0x18
arch/loongarch/include/asm/loongarch.h:48:#define REG_S2		0x19
arch/loongarch/include/asm/loongarch.h:49:#define REG_S3		0x1a
arch/loongarch/include/asm/loongarch.h:50:#define REG_S4		0x1b
arch/loongarch/include/asm/loongarch.h:51:#define REG_S5		0x1c
arch/loongarch/include/asm/loongarch.h:52:#define REG_S6		0x1d
arch/loongarch/include/asm/loongarch.h:53:#define REG_S7		0x1e
arch/loongarch/include/asm/loongarch.h:54:#define REG_S8		0x1f
arch/loongarch/include/asm/loongarch.h-55-
--
arch/loongarch/kernel/ptrace.c=782=struct pt_regs_offset {
--
arch/loongarch/kernel/ptrace.c-786-
arch/loongarch/kernel/ptrace.c:787:#define REG_OFFSET_NAME(n, r) {.name = #n, .offset = offsetof(struct pt_regs, r)}
arch/loongarch/kernel/ptrace.c:788:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/loongarch/kernel/ptrace.c-789-
--
arch/loongarch/net/bpf_jit.c-25-
arch/loongarch/net/bpf_jit.c:26:#define REG_TCC		LOONGARCH_GPR_A6
arch/loongarch/net/bpf_jit.c:27:#define REG_ARENA	LOONGARCH_GPR_S6 /* For storing arena_vm_start */
arch/loongarch/net/bpf_jit.c-28-#define BPF_TAIL_CALL_CNT_PTR_STACK_OFF(stack) (round_up(stack, 16) - 80)
--
arch/loongarch/net/bpf_jit.c=629=static bool is_signed_bpf_cond(u8 cond)
--
arch/loongarch/net/bpf_jit.c-636-#define BPF_FIXUP_OFFSET_MASK	GENMASK(26, 0)
arch/loongarch/net/bpf_jit.c:637:#define REG_DONT_CLEAR_MARKER	0
arch/loongarch/net/bpf_jit.c-638-
--
arch/mips/bmips/setup.c-33-
arch/mips/bmips/setup.c:34:#define REG_BCM6328_OTP		((void __iomem *)CKSEG1ADDR(0x1000062c))
arch/mips/bmips/setup.c-35-#define BCM6328_TP1_DISABLED	BIT(9)
--
arch/mips/include/asm/asm.h=95=symbol		=	value
--
arch/mips/include/asm/asm.h-157-#if (_MIPS_SIM == _MIPS_SIM_ABI32)
arch/mips/include/asm/asm.h:158:#define REG_S		sw
arch/mips/include/asm/asm.h:159:#define REG_L		lw
arch/mips/include/asm/asm.h:160:#define REG_SUBU	subu
arch/mips/include/asm/asm.h:161:#define REG_ADDU	addu
arch/mips/include/asm/asm.h-162-#endif
arch/mips/include/asm/asm.h-163-#if (_MIPS_SIM == _MIPS_SIM_NABI32) || (_MIPS_SIM == _MIPS_SIM_ABI64)
arch/mips/include/asm/asm.h:164:#define REG_S		sd
arch/mips/include/asm/asm.h:165:#define REG_L		ld
arch/mips/include/asm/asm.h:166:#define REG_SUBU	dsubu
arch/mips/include/asm/asm.h:167:#define REG_ADDU	daddu
arch/mips/include/asm/asm.h-168-#endif
--
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h-1131-#define BCMPCI_REG_TIMERS		0x40
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1132:#define REG_TIMER_TRDY_SHIFT		0
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1133:#define REG_TIMER_TRDY_MASK		(0xff << REG_TIMER_TRDY_SHIFT)
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1134:#define REG_TIMER_RETRY_SHIFT		8
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1135:#define REG_TIMER_RETRY_MASK		(0xff << REG_TIMER_RETRY_SHIFT)
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h-1136-
--
arch/mips/kernel/ptrace.c=848=struct pt_regs_offset {
--
arch/mips/kernel/ptrace.c-852-
arch/mips/kernel/ptrace.c:853:#define REG_OFFSET_NAME(reg, r) {					\
arch/mips/kernel/ptrace.c-854-	.name = #reg,							\
--
arch/mips/kernel/ptrace.c-857-
arch/mips/kernel/ptrace.c:858:#define REG_OFFSET_END {						\
arch/mips/kernel/ptrace.c-859-	.name = NULL,							\
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h=19=extern sci_handler yeeloong_report_lid_status;
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-52-/* temperature & fan registers */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:53:#define REG_TEMPERATURE_VALUE	0xF458
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:54:#define REG_FAN_AUTO_MAN_SWITCH 0xF459
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-55-#define BIT_FAN_AUTO		0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-56-#define BIT_FAN_MANUAL		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:57:#define REG_FAN_CONTROL		0xF4D2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-58-#define BIT_FAN_CONTROL_ON	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-59-#define BIT_FAN_CONTROL_OFF	(0 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:60:#define REG_FAN_STATUS		0xF4DA
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-61-#define BIT_FAN_STATUS_ON	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-62-#define BIT_FAN_STATUS_OFF	(0 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:63:#define REG_FAN_SPEED_HIGH	0xFE22
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:64:#define REG_FAN_SPEED_LOW	0xFE23
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:65:#define REG_FAN_SPEED_LEVEL	0xF4CC
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-66-/* fan speed divider */
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-69-/* battery registers */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:70:#define REG_BAT_DESIGN_CAP_HIGH		0xF77D
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:71:#define REG_BAT_DESIGN_CAP_LOW		0xF77E
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:72:#define REG_BAT_FULLCHG_CAP_HIGH	0xF780
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:73:#define REG_BAT_FULLCHG_CAP_LOW		0xF781
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:74:#define REG_BAT_DESIGN_VOL_HIGH		0xF782
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:75:#define REG_BAT_DESIGN_VOL_LOW		0xF783
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:76:#define REG_BAT_CURRENT_HIGH		0xF784
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:77:#define REG_BAT_CURRENT_LOW		0xF785
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:78:#define REG_BAT_VOLTAGE_HIGH		0xF786
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:79:#define REG_BAT_VOLTAGE_LOW		0xF787
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:80:#define REG_BAT_TEMPERATURE_HIGH	0xF788
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:81:#define REG_BAT_TEMPERATURE_LOW		0xF789
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:82:#define REG_BAT_RELATIVE_CAP_HIGH	0xF492
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:83:#define REG_BAT_RELATIVE_CAP_LOW	0xF493
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:84:#define REG_BAT_VENDOR			0xF4C4
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-85-#define FLAG_BAT_VENDOR_SANYO		0x01
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-86-#define FLAG_BAT_VENDOR_SIMPLO		0x02
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:87:#define REG_BAT_CELL_COUNT		0xF4C6
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-88-#define FLAG_BAT_CELL_3S1P		0x03
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-89-#define FLAG_BAT_CELL_3S2P		0x06
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:90:#define REG_BAT_CHARGE			0xF4A2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-91-#define FLAG_BAT_CHARGE_DISCHARGE	0x01
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-93-#define FLAG_BAT_CHARGE_ACPOWER		0x00
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:94:#define REG_BAT_STATUS			0xF4B0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-95-#define BIT_BAT_STATUS_LOW		(1 << 5)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-98-#define BIT_BAT_STATUS_IN		(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:99:#define REG_BAT_CHARGE_STATUS		0xF4B1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-100-#define BIT_BAT_CHARGE_STATUS_OVERTEMP	(1 << 2)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-101-#define BIT_BAT_CHARGE_STATUS_PRECHG	(1 << 1)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:102:#define REG_BAT_STATE			0xF482
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-103-#define BIT_BAT_STATE_CHARGING		(1 << 1)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-104-#define BIT_BAT_STATE_DISCHARGING	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:105:#define REG_BAT_POWER			0xF440
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-106-#define BIT_BAT_POWER_S3		(1 << 2)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-111-/* Audio: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:112:#define REG_AUDIO_VOLUME	0xF46C
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:113:#define REG_AUDIO_MUTE		0xF4E7
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:114:#define REG_AUDIO_BEEP		0xF4D0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-115-/* USB port power or not: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:116:#define REG_USB0_FLAG		0xF461
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:117:#define REG_USB1_FLAG		0xF462
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:118:#define REG_USB2_FLAG		0xF463
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-119-#define BIT_USB_FLAG_ON		1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-121-/* LID */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:122:#define REG_LID_DETECT		0xF4BD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-123-#define BIT_LID_DETECT_ON	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-125-/* CRT */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:126:#define REG_CRT_DETECT		0xF4AD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-127-#define BIT_CRT_DETECT_PLUG	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-129-/* LCD backlight brightness adjust: 9 levels */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:130:#define REG_DISPLAY_BRIGHTNESS	0xF4F5
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-131-/* Black screen Status */
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-134-/* LCD backlight control: off/restore */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:135:#define REG_BACKLIGHT_CTRL	0xF7BD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-136-#define BIT_BACKLIGHT_ON	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-138-/* Reset the machine auto-clear: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:139:#define REG_RESET		0xF4EC
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-140-#define BIT_RESET_ON		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-141-/* Light the led: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:142:#define REG_LED			0xF4C8
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-143-#define BIT_LED_RED_POWER	(1 << 0)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-148-/* Test led mode, all led on/off */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:149:#define REG_LED_TEST		0xF4C2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-150-#define BIT_LED_TEST_IN		1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-152-/* Camera on/off */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:153:#define REG_CAMERA_STATUS	0xF46A
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-154-#define BIT_CAMERA_STATUS_ON	1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-155-#define BIT_CAMERA_STATUS_OFF	0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:156:#define REG_CAMERA_CONTROL	0xF7B7
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-157-#define BIT_CAMERA_CONTROL_OFF	0
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-159-/* Wlan Status */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:160:#define REG_WLAN		0xF4FA
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-161-#define BIT_WLAN_ON		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-162-#define BIT_WLAN_OFF		0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:163:#define REG_DISPLAY_LCD		0xF79F
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-164-
--
arch/mips/loongson2ef/lemote-2f/reset.c=75=static void ml2f_reboot(void)
--
arch/mips/loongson2ef/lemote-2f/reset.c-88-#define EC_SHUTDOWN_IO_PORT_DATA 0xff2f
arch/mips/loongson2ef/lemote-2f/reset.c:89:#define REG_SHUTDOWN_HIGH	 0xFC
arch/mips/loongson2ef/lemote-2f/reset.c:90:#define REG_SHUTDOWN_LOW	 0x29
arch/mips/loongson2ef/lemote-2f/reset.c-91-#define BIT_SHUTDOWN_ON		 (1 << 1)
--
arch/mips/n64/init.c=46=void __init prom_init(void)
--
arch/mips/n64/init.c-52-#define H 240
arch/mips/n64/init.c:53:#define REG_BASE ((u32 __iomem *) CKSEG1ADDR(0x4400000))
arch/mips/n64/init.c-54-
--
arch/mips/ralink/ill_acc.c-14-
arch/mips/ralink/ill_acc.c:15:#define REG_ILL_ACC_ADDR	0x10
arch/mips/ralink/ill_acc.c:16:#define REG_ILL_ACC_TYPE	0x14
arch/mips/ralink/ill_acc.c-17-
--
arch/nios2/kernel/ptrace.c=46=static int genregs_set(struct task_struct *target,
--
arch/nios2/kernel/ptrace.c-54-
arch/nios2/kernel/ptrace.c:55:#define REG_IGNORE_RANGE(START, END)		\
arch/nios2/kernel/ptrace.c-56-	if (!ret)					\
--
arch/nios2/kernel/ptrace.c-59-
arch/nios2/kernel/ptrace.c:60:#define REG_IN_ONE(PTR, LOC)	\
arch/nios2/kernel/ptrace.c-61-	if (!ret)			\
--
arch/nios2/kernel/ptrace.c-64-
arch/nios2/kernel/ptrace.c:65:#define REG_IN_RANGE(PTR, START, END)	\
arch/nios2/kernel/ptrace.c-66-	if (!ret)				\
--
arch/openrisc/kernel/ptrace.c=163=struct pt_regs_offset {
--
arch/openrisc/kernel/ptrace.c-167-
arch/openrisc/kernel/ptrace.c:168:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/openrisc/kernel/ptrace.c:169:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/openrisc/kernel/ptrace.c-170-
--
arch/parisc/include/asm/assembly.h-15-#define CALLEE_REG_FRAME_SIZE	144
arch/parisc/include/asm/assembly.h:16:#define REG_SZ		8
arch/parisc/include/asm/assembly.h-17-#define ASM_ULONG_INSN	.dword
--
arch/parisc/include/asm/assembly.h-21-#define CALLEE_REG_FRAME_SIZE	128
arch/parisc/include/asm/assembly.h:22:#define REG_SZ		4
arch/parisc/include/asm/assembly.h-23-#define ASM_ULONG_INSN	.word
--
arch/parisc/kernel/perf_regs.c=9=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/parisc/kernel/perf_regs.c-34-
arch/parisc/kernel/perf_regs.c:35:#define REG_RESERVED (~((1ULL << PERF_REG_PARISC_MAX) - 1))
arch/parisc/kernel/perf_regs.c-36-
--
arch/parisc/kernel/ptrace.c=663=struct pt_regs_offset {
--
arch/parisc/kernel/ptrace.c-667-
arch/parisc/kernel/ptrace.c:668:#define REG_OFFSET_NAME(r)    {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/parisc/kernel/ptrace.c:669:#define REG_OFFSET_INDEX(r,i) {.name = #r#i, .offset = offsetof(struct pt_regs, r[i])}
arch/parisc/kernel/ptrace.c:670:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/parisc/kernel/ptrace.c-671-
--
arch/parisc/net/bpf_jit.h=65=struct hppa_jit_context {
--
arch/parisc/net/bpf_jit.h-76-
arch/parisc/net/bpf_jit.h:77:#define REG_SET_SEEN(ctx, nr)	{ if (ctx->reg_seen_collect) ctx->reg_seen |= BIT(nr); }
arch/parisc/net/bpf_jit.h:78:#define REG_SET_SEEN_ALL(ctx)	{ if (ctx->reg_seen_collect) ctx->reg_seen = -1; }
arch/parisc/net/bpf_jit.h:79:#define REG_FORCE_SEEN(ctx, nr)	{ ctx->reg_seen |= BIT(nr); }
arch/parisc/net/bpf_jit.h:80:#define REG_WAS_SEEN(ctx, nr)	(ctx->reg_seen & BIT(nr))
arch/parisc/net/bpf_jit.h:81:#define REG_ALL_SEEN(ctx)	(ctx->reg_seen == -1)
arch/parisc/net/bpf_jit.h-82-
arch/parisc/net/bpf_jit.h-83-#define HPPA_INSN_SIZE		4	/* bytes per HPPA asm instruction */
arch/parisc/net/bpf_jit.h:84:#define REG_SIZE		REG_SZ	/* bytes per native "long" word */
arch/parisc/net/bpf_jit.h-85-
--
arch/powerpc/kernel/ptrace/ptrace-view.c=10=struct pt_regs_offset {
--
arch/powerpc/kernel/ptrace/ptrace-view.c-15-#define STR(s)	#s			/* convert to string */
arch/powerpc/kernel/ptrace/ptrace-view.c:16:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/powerpc/kernel/ptrace/ptrace-view.c-17-#define GPR_OFFSET_NAME(num)	\
--
arch/powerpc/kernel/ptrace/ptrace-view.c-19-	{.name = STR(gpr##num), .offset = offsetof(struct pt_regs, gpr[num])}
arch/powerpc/kernel/ptrace/ptrace-view.c:20:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/powerpc/kernel/ptrace/ptrace-view.c-21-
--
arch/powerpc/perf/perf_regs.c=16=u64 PERF_REG_EXTENDED_MASK;
--
arch/powerpc/perf/perf_regs.c-19-
arch/powerpc/perf/perf_regs.c:20:#define REG_RESERVED (~(PERF_REG_EXTENDED_MASK | PERF_REG_PMU_MASK))
arch/powerpc/perf/perf_regs.c-21-
--
arch/riscv/include/asm/asm.h-28-
arch/riscv/include/asm/asm.h:29:#define REG_L		__REG_SEL(ld, lw)
arch/riscv/include/asm/asm.h:30:#define REG_S		__REG_SEL(sd, sw)
arch/riscv/include/asm/asm.h:31:#define REG_SC		__REG_SEL(sc.d, sc.w)
arch/riscv/include/asm/asm.h:32:#define REG_AMOSWAP_AQ	__REG_SEL(amoswap.d.aq, amoswap.w.aq)
arch/riscv/include/asm/asm.h:33:#define REG_ASM		__REG_SEL(.dword, .word)
arch/riscv/include/asm/asm.h-34-#define SZREG		__REG_SEL(8, 4)
--
arch/riscv/include/asm/insn.h=284=static __always_inline bool riscv_insn_is_c_jalr(u32 code)
--
arch/riscv/include/asm/insn.h-396-
arch/riscv/include/asm/insn.h:397:#define REG_MASK			\
arch/riscv/include/asm/insn.h-398-	((1 << (5 + LOG_REGBYTES)) - (1 << LOG_REGBYTES))
arch/riscv/include/asm/insn.h-399-
arch/riscv/include/asm/insn.h:400:#define REG_OFFSET(insn, pos)		\
arch/riscv/include/asm/insn.h-401-	(SHIFT_RIGHT((insn), (pos) - LOG_REGBYTES) & REG_MASK)
arch/riscv/include/asm/insn.h-402-
arch/riscv/include/asm/insn.h:403:#define REG_PTR(insn, pos, regs)	\
arch/riscv/include/asm/insn.h-404-	((ulong *)((ulong)(regs) + REG_OFFSET(insn, pos)))
--
arch/riscv/include/asm/module.h=48=struct plt_entry {
--
arch/riscv/include/asm/module.h-60-#define OPC_JALR   0x0067
arch/riscv/include/asm/module.h:61:#define REG_T0     0x5
arch/riscv/include/asm/module.h:62:#define REG_T1     0x6
arch/riscv/include/asm/module.h-63-
--
arch/riscv/include/asm/ptrace.h=15=struct pt_regs {
--
arch/riscv/include/asm/ptrace.h-61-#ifdef CONFIG_64BIT
arch/riscv/include/asm/ptrace.h:62:#define REG_FMT "%016lx"
arch/riscv/include/asm/ptrace.h-63-#else
arch/riscv/include/asm/ptrace.h:64:#define REG_FMT "%08lx"
arch/riscv/include/asm/ptrace.h-65-#endif
--
arch/riscv/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/riscv/kernel/perf_regs.c-18-
arch/riscv/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_RISCV_MAX) - 1))

]

25/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 24834
							output: 25
							thoughts: 29
						

Thoughts:
**A Deep Dive into Thunderbolt Interrupt Handling**

My immediate thought process, when faced with the task of understanding or modifying Thunderbolt interrupt handling, is to ground myself in the foundational definitions. Where are these interrupts defined? What are their base addresses? This leads me directly to the kernel header file `drivers/thunderbolt/nhi_regs.h`. It's my go-to for low-level hardware register definitions, and specifically, I'm looking for the symbol `REG_RING_INTERRUPT_BASE`. This macro, or constant, is crucial because it will likely tell me the starting point in the memory-mapped I/O space where the ring buffer interrupts are mapped. From this base, I can then deduce the offsets for individual interrupt sources within that ring. Knowing this base address is fundamental to correctly configuring interrupt handlers, masking or unmasking specific interrupts, and ultimately, to efficiently processing the events that the Thunderbolt controller signals. It’s a critical piece of the puzzle for any advanced work on this subsystem.


26/2 2026/08/10 08:21 tool grepper
0m Args:
map[Expression:#define REG_RING_INTERRUPT_BASE]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-98- */
drivers/thunderbolt/nhi_regs.h:99:#define REG_RING_INTERRUPT_BASE	0x38200
drivers/thunderbolt/nhi_regs.h-100-#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
]

27/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 25011
							output: 24
							thoughts: 28
						

Thoughts:
**My Thought Process:**

My initial step is to orient myself within the codebase. I'm looking to understand the specifics of how Thunderbolt interrupts are managed, particularly the "ring notification" mechanism. To do this, I know I need to examine the header files that define the hardware registers associated with the Thunderbolt Network Interface Host (NHI) controller. My hypothesis is that the base address for these ring notification registers will be defined in a configuration-related header file. Therefore, I've decided to navigate to `drivers/thunderbolt/nhi_regs.h`. My specific intention is to locate the macro or definition for `REG_RING_NOTIFY_BASE` within that file. This will give me the foundational address from which all other ring notification-related register offsets can be calculated, which is crucial for implementing the interrupt handling logic.


28/2 2026/08/10 08:21 tool grepper
0m Args:
map[Expression:#define REG_RING_NOTIFY_BASE]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-89- */
drivers/thunderbolt/nhi_regs.h:90:#define REG_RING_NOTIFY_BASE	0x37800
drivers/thunderbolt/nhi_regs.h-91-#define RING_NOTIFY_REG_COUNT(nhi) ((31 + 3 * nhi->hop_count) / 32)
]

29/2 2026/08/10 08:21 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 25183
							output: 40
							thoughts: 176
						

Thoughts:
**My Thought Process Regarding the PCI Device and Potential Out-of-Bounds Access**

Okay, so I've been looking at this PCI device and its memory-mapped regions, and I'm trying to piece together a potential vulnerability. My current understanding is that the maximum offset I'm concerned about is around `0x38308`.

Now, let's consider the scenario where `syzkaller`, our fuzzing tool, presents a PCI device to the system. Specifically, I'm focusing on BAR 0, which is the primary memory-mapped region for many devices. If `syzkaller` configures this BAR 0 to be a mere 4KB in size (that's `0x1000` in hexadecimal), then the `ioremap` operation, which is responsible for mapping this physical device memory into the kernel's virtual address space, will consequently only map that same 4KB.

The problem arises in the `nhi_probe` function. This function, as I understand it, reads a value called `nhi->hop_count` from a register located at offset `0` within the mapped region, which is designated as `REG_CAPS`. If this `hop_count` value happens to be exceptionally large, say `1023` as an example, the code then attempts to access an offset of `0x38208`.

And here's the critical point: if the `ioremap` only established a 4KB mapping, then an access to `0x38208` is significantly *out of bounds* of that allocated 4KB region. This is precisely the kind of condition that would lead to a page fault – the kernel trying to access memory it hasn't mapped or doesn't have permission to access.

However, I just had a thought, and it's causing me to re-evaluate. I need to confirm how this region is actually mapped. I recall that `pcim_iomap_region` is the function responsible for this mapping. My immediate question is: does `pcim_iomap_region` perform any checks to ensure that the requested BAR size is at least a certain minimum? If there's a safeguard there that prevents mapping a BAR that's too small for the expected register accesses, then my current line of reasoning might be flawed. I need to go back and scrutinize the implementation of `nhi_pci_probe` again to see if any such checks are in place. This is crucial for understanding if this specific out-of-bounds access scenario is actually achievable.


30/2 2026/08/10 08:22 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

31/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 26016
							output: 37
							thoughts: 171
						

Thoughts:
**My Thought Process Regarding Thunderbolt NHI BAR Size**

Okay, so as I'm looking through this code, the first thing that jumps out at me is that there isn't any explicit check for the *minimum* size of the Base Address Register (BAR) being requested for the Thunderbolt Network Interface Host (NHI) device. This feels like a potential oversight.

My mind immediately goes to the implications of this. I'm thinking, "What if `pci_resource_len(pdev, 0)` – which represents the length of the first PCI resource, presumably the BAR we're interested in – comes back as smaller than some expected maximum offset?" If that happens, the system might end up mapping only a tiny region.

But then I pause and correct myself. The *actual* maximum offset we need to worry about isn't a fixed constant. It's dependent on `nhi->hop_count`. This `hop_count` value itself is read from `REG_CAPS`, which is located at offset 0. And `REG_CAPS` can potentially yield a `hop_count` value as high as 1023.

So, the real question then becomes: what happens if the BAR size itself is *smaller* than what's required to accommodate all the necessary registers, specifically up to the maximum offset dictated by `REG_CAPS`? If the BAR is too small, we might not even be able to read `REG_CAPS` properly, let alone anything else.

Therefore, the critical unknown I need to resolve is: what is the absolute *minimum* BAR size that's absolutely required for a functional Thunderbolt NHI device? To get to the bottom of this, I'm going to have to dive into the `nhi_probe` function and examine how the BAR is handled and what assumptions it makes about its size.


32/2 2026/08/10 08:22 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_probe]

Results:
map[SourceCode:1186:	int nhi_probe(struct tb_nhi *nhi)
1187:	{
1188:		struct device *dev = nhi->dev;
1189:		struct tb *tb;
1190:		int res;
1191:	
1192:		if (!nhi->ops)
1193:			return dev_err_probe(dev, -EINVAL, "NHI ops not set\n");
1194:	
1195:		if (!nhi->ops->init_interrupts)
1196:			return dev_err_probe(dev, -EINVAL, "missing required NHI ops\n");
1197:	
1198:		nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
1199:		dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
1200:	
1201:		nhi->tx_rings = devm_kcalloc(dev, nhi->hop_count,
1202:					     sizeof(*nhi->tx_rings), GFP_KERNEL);
1203:		nhi->rx_rings = devm_kcalloc(dev, nhi->hop_count,
1204:					     sizeof(*nhi->rx_rings), GFP_KERNEL);
1205:		if (!nhi->tx_rings || !nhi->rx_rings)
1206:			return -ENOMEM;
1207:	
1208:		nhi_reset(nhi);
1209:	
1210:		/* In case someone left them on. */
1211:		nhi_disable_interrupts(nhi);
1212:	
1213:		res = nhi->ops->init_interrupts(nhi);
1214:		if (res)
1215:			return dev_err_probe(dev, res, "cannot enable interrupts, aborting\n");
1216:	
1217:		spin_lock_init(&nhi->lock);
1218:	
1219:		res = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64));
1220:		if (res)
1221:			return dev_err_probe(dev, res, "failed to set DMA mask\n");
1222:	
1223:		if (nhi->ops->init) {
1224:			res = nhi->ops->init(nhi);
1225:			if (res)
1226:				return dev_err_probe(dev, res, "NHI specific init failed\n");
1227:		}
1228:	
1229:		tb = nhi_select_cm(nhi);
1230:		if (!tb)
1231:			return dev_err_probe(dev, -ENODEV,
1232:				"failed to determine connection manager, aborting\n");
1233:	
1234:		dev_dbg(dev, "NHI initialized, starting thunderbolt\n");
1235:	
1236:		init_completion(&nhi->domain_released);
1237:	
1238:		res = tb_domain_add(tb, host_reset);
1239:		if (res) {
1240:			/*
1241:			 * At this point the RX/TX rings might already have been
1242:			 * activated. Do a proper shutdown.
1243:			 */
1244:			tb_domain_put(tb);
1245:			wait_for_completion(&nhi->domain_released);
1246:			nhi_shutdown(nhi);
1247:			return dev_err_probe(dev, res, "failed to add domain\n");
1248:		}
1249:		dev_set_drvdata(dev, tb);
1250:	
1251:		device_wakeup_enable(dev);
1252:	
1253:		pm_runtime_allow(dev);
1254:		pm_runtime_set_autosuspend_delay(dev, TB_AUTOSUSPEND_DELAY);
1255:		pm_runtime_use_autosuspend(dev);
1256:		pm_runtime_put_autosuspend(dev);
1257:	
1258:		return 0;
1259:	}
 SourceFile:drivers/thunderbolt/nhi.c]

33/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 27407
							output: 37
							thoughts: 385
						

Thoughts:
**The Unexpected Journey to a BAR Out-of-Bounds Access**

My investigation began with a seemingly innocuous observation about interrupt counts. I noticed that if `nhi->hop_count` was zero, the calculation for `RING_INTERRUPT_REG_COUNT` yielded zero, specifically `31 / 32 = 0`. I double-checked this with the full formula, `(31 + 2 * 0) / 32`, which indeed still resulted in zero. This led me to a crucial insight: when `nhi->hop_count` is zero, the `nhi_disable_interrupts` function essentially becomes a no-op; it doesn't actually do anything.

However, my attention was immediately drawn to how `nhi->hop_count` itself is determined. It's read from `REG_CAPS`, which is located at offset 0. The critical constraint here is the BAR size. If the BAR size is a meager 4KB, then `REG_CAPS` is certainly within that mapped region. The plot thickened when I considered a specific value for `REG_CAPS`: 1023. If `REG_CAPS` read 1023, it would imply that `RING_INTERRUPT_REG_COUNT` should be 64.

This is where the problem really started to surface. If `RING_INTERRUPT_REG_COUNT` is 64, then the `nhi_disable_interrupts` function would attempt to access memory up to address `0x38308`. But, as established, the BAR size is only 4KB, meaning the valid memory region is far smaller. This discrepancy immediately pointed to an out-of-bounds access, precisely what the bug report indicated. The driver was attempting to read beyond the confines of its mapped memory space.

So, how would one go about reproducing this? The key would be to simulate the conditions. This would involve creating a virtual PCI device. Tools like `syzkaller` with its `syz_pci_device` functionality come to mind. The crucial aspects would be to configure this virtual device with a very small BAR 0, specifically 4KB. Furthermore, when the driver probes and reads from offset 0 – the location of `REG_CAPS` – it needs to receive a value that forces the subsequent interrupt calculation to be large. A value like 1023, as I identified, would serve this purpose perfectly.

Upon reviewing the bug report further, I noticed a specific call stack entry: `bind_store+0x1d0/0x220 drivers/base/bus.c:267`. This told me that the actual trigger was a user attempting to bind the driver to a specific device. Specifically, it was a write operation to `/sys/bus/pci/drivers/thunderbolt/bind`, indicating the driver in question is the Thunderbolt host router driver. To perfectly replicate this, I would also need to identify and use the correct PCI ID for this Thunderbolt host router device.


34/2 2026/08/10 08:22 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_ids]

Results:
map[SourceCode: 496:	static struct pci_device_id nhi_ids[] = {
 497:		/*
 498:		 * We have to specify class, the TB bridges use the same device and
 499:		 * vendor (sub)id on gen 1 and gen 2 controllers.
 500:		 */
 501:		{
 502:			.class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
 503:			.vendor = PCI_VENDOR_ID_INTEL,
 504:			.device = PCI_DEVICE_ID_INTEL_LIGHT_RIDGE,
 505:			.subvendor = 0x2222, .subdevice = 0x1111,
 506:		},
 507:		{
 508:			.class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
 509:			.vendor = PCI_VENDOR_ID_INTEL,
 510:			.device = PCI_DEVICE_ID_INTEL_CACTUS_RIDGE_4C,
 511:			.subvendor = 0x2222, .subdevice = 0x1111,
 512:		},
 513:		{
 514:			.class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
 515:			.vendor = PCI_VENDOR_ID_INTEL,
 516:			.device = PCI_DEVICE_ID_INTEL_FALCON_RIDGE_2C_NHI,
 517:			.subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID,
 518:		},
 519:		{
 520:			.class = PCI_CLASS_SYSTEM_OTHER << 8, .class_mask = ~0,
 521:			.vendor = PCI_VENDOR_ID_INTEL,
 522:			.device = PCI_DEVICE_ID_INTEL_FALCON_RIDGE_4C_NHI,
 523:			.subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID,
 524:		},
 525:	
 526:		/* Thunderbolt 3 */
 527:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_2C_NHI) },
 528:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_4C_NHI) },
 529:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_USBONLY_NHI) },
 530:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_NHI) },
 531:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_USBONLY_NHI) },
 532:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_2C_NHI) },
 533:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_4C_NHI) },
 534:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_USBONLY_NHI) },
 535:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TITAN_RIDGE_2C_NHI) },
 536:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TITAN_RIDGE_4C_NHI) },
 537:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ICL_NHI0),
 538:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 539:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ICL_NHI1),
 540:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 541:		/* Thunderbolt 4 */
 542:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TGL_NHI0),
 543:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 544:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TGL_NHI1),
 545:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 546:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TGL_H_NHI0),
 547:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 548:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_TGL_H_NHI1),
 549:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 550:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ADL_NHI0),
 551:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 552:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_ADL_NHI1),
 553:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 554:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_RPL_NHI0),
 555:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 556:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_RPL_NHI1),
 557:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 558:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_MTL_M_NHI0),
 559:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 560:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_MTL_P_NHI0),
 561:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 562:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_MTL_P_NHI1),
 563:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 564:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_LNL_NHI0),
 565:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 566:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_LNL_NHI1),
 567:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 568:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_PTL_M_NHI0),
 569:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 570:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_PTL_M_NHI1),
 571:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 572:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_PTL_P_NHI0),
 573:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 574:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_PTL_P_NHI1),
 575:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 576:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_WCL_NHI0),
 577:		  .driver_data = (kernel_ulong_t)&icl_nhi_ops },
 578:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_80G_NHI) },
 579:		{ PCI_VDEVICE(INTEL, PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_40G_NHI) },
 580:	
 581:		/* Any USB4 compliant host */
 582:		{ PCI_DEVICE_CLASS(PCI_CLASS_SERIAL_USB_USB4, ~0) },
 583:	
 584:		{ 0,}
 585:	};
 SourceFile:drivers/thunderbolt/pci.c]

35/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 30186
							output: 29
							thoughts: 21
						

Thoughts:
**My Thought Process**

My immediate objective is to ascertain the specific numerical identifier associated with the `PCI_DEVICE_ID_INTEL_LIGHT_RIDGE` constant. This is a critical piece of information for me because I need to understand exactly which hardware device this symbol represents within the context of PCI device enumeration. Knowing this value will allow me to perform precise lookups, confirm device compatibility, and potentially debug or integrate with this particular Intel Light Ridge device. Without this concrete numerical representation, the symbolic name is insufficient for direct system interaction or low-level hardware analysis. Therefore, I'm focused on retrieving this precise `PCI_DEVICE_ID_INTEL_LIGHT_RIDGE` value.


36/2 2026/08/10 08:22 tool grepper
0m Args:
map[Expression:#define PCI_DEVICE_ID_INTEL_LIGHT_RIDGE]

Results:
map[Output:include/linux/pci_ids.h-2745-#define PCI_DEVICE_ID_INTEL_82439	0x1250
include/linux/pci_ids.h:2746:#define PCI_DEVICE_ID_INTEL_LIGHT_RIDGE             0x1513 /* Tbt 1 Gen 1 */
include/linux/pci_ids.h-2747-#define PCI_DEVICE_ID_INTEL_EAGLE_RIDGE             0x151a
]

37/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 30362
							output: 19
							thoughts: 398
						

Thoughts:
**My Thought Process Regarding the Thunderbolt Driver Vulnerability**

Right, let's break down this Thunderbolt driver issue from my perspective. I've got this specific device in my sights: it's a PCI device with the Vendor ID `0x8086` (which immediately tells me it's Intel) and the Device ID `0x1513`. This particular device ID is crucial, as it seems to be the entry point for this bug.

The core of the problem, as I see it, is a combination of how the virtual PCI device is configured and how the `thunderbolt` driver interacts with it. The conditions that trigger the vulnerability are quite specific:

First, I need to set up a *virtual* PCI device. This isn't about a physical card, but rather a simulated one. For this virtual device, I'll configure it with that Intel Vendor ID (`0x8086`) and the problematic Device ID (`0x1513`).

Second, a key component is its Base Address Register 0 (BAR 0). The size of this BAR is critical; it needs to be 4KB or, more generally, anything less than `0x39000`. This constraint on the BAR size is a strong indicator that the driver might be making assumptions about memory layout or access ranges that aren't always met.

Third, and this is where things get really interesting, when the system tries to read from BAR 0 at offset `0x0` (which is labeled as `REG_CAPS` in the driver context), the device needs to return a *large value*. Specifically, something like `0xffffffff` is mentioned. This inflated capability value is likely misleading the driver into believing certain features or configurations are present when they aren't, or are much more extensive than they actually are.

Once these conditions are met, the attacker, or in this case, the user setting up the test environment, can then trigger the driver's attention. This is done by writing the PCI device's address string (like `0000:00:07.0`) to the `/sys/bus/pci/drivers/thunderbolt/bind` interface. This action tells the `thunderbolt` driver to probe and bind to this specific PCI device.

Now, the driver's `probe` function kicks in. It reads `nhi->hop_count` from that `REG_CAPS` location. Because of the fake large value (like `0xffffffff`) we've arranged, `nhi->hop_count` gets a value of 1023. This is a significantly large number, far exceeding what's probably a realistic hop count for any Thunderbolt device.

The driver then proceeds to call `nhi_disable_interrupts`. This function, in its current implementation, has a loop that iterates up to 64 times. Inside this loop, it attempts to write to memory locations calculated as `nhi->iobase + 0x38208 + 4 * i`. The `iobase` here refers to the memory-mapped I/O region of the device.

The problem is that the `0x38208` offset, when combined with the loop and the `4 * i` increment, leads to an out-of-bounds access *beyond* the allocated ioremapped region for the device. This transgression from the expected memory boundaries is what ultimately triggers a page fault, indicating an attempt to access memory that the process isn't allowed to touch. This is a classic out-of-bounds write scenario.

However, I've also noted a crucial detail from the bug report: the specific error message is `thunderbolt 0000:00:07.0: timeout resetting host router`. This immediately makes me pause and re-evaluate. This particular message suggests that the `nhi_reset` function is timing out. This implies that the vulnerability might not be directly in `nhi_disable_interrupts`'s out-of-bounds write, but rather in the preceding `nhi_reset` function itself, which is likely called before `nhi_disable_interrupts` in the probe sequence.

Looking into `nhi_reset`, I see it starts by reading `REG_CAPS` (at offset 0) to check the version. If the version is detected as 2 or greater, it then proceeds to write to `REG_RESET`. The offset for `REG_RESET` is something I need to confirm precisely. The mention of `REG_RING_INTERRUPT_BASE` at `0x38200` makes me wonder if `REG_RESET` is relative to that, or perhaps at `0x38200` itself. Regardless, the timeout in `nhi_reset` points to a potential issue with how it handles the reset operation, possibly due to the same misleading `REG_CAPS` value, or some other condition within that reset logic that leads to an infinite loop or an unresponsively slow operation. This timeout is the more immediate symptom, suggesting the bug might manifest earlier in the probe process than initially thought.


38/2 2026/08/10 08:22 tool grepper
0m Args:
map[Expression:#define REG_RESET]

Results:
map[Output:arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h=19=extern sci_handler yeeloong_report_lid_status;
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-138-/* Reset the machine auto-clear: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:139:#define REG_RESET		0xF4EC
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-140-#define BIT_RESET_ON		1
--
drivers/clk/berlin/bg2.c-42-#define REG_CLKSWITCH1		0x0168
drivers/clk/berlin/bg2.c:43:#define REG_RESET_TRIGGER	0x0178
drivers/clk/berlin/bg2.c:44:#define REG_RESET_STATUS0	0x017c
drivers/clk/berlin/bg2.c:45:#define REG_RESET_STATUS1	0x0180
drivers/clk/berlin/bg2.c-46-#define REG_SW_GENERIC0		0x0184
--
drivers/clk/clk-en7523.c-32-#define REG_CRYPTO_CLKSRC		0x200
drivers/clk/clk-en7523.c:33:#define REG_RESET_CONTROL2		0x830
drivers/clk/clk-en7523.c-34-#define   REG_RESET2_CONTROL_PCIE2	BIT(27)
drivers/clk/clk-en7523.c:35:#define REG_RESET_CONTROL1		0x834
drivers/clk/clk-en7523.c-36-#define   REG_RESET_CONTROL_PCIEHB	BIT(29)
--
drivers/gpu/drm/bridge/ite-it6505.c-38-
drivers/gpu/drm/bridge/ite-it6505.c:39:#define REG_RESET_CTRL 0x05
drivers/gpu/drm/bridge/ite-it6505.c-40-#define VIDEO_RESET BIT(0)
--
drivers/hwmon/sg2042-mcu.c-25-#define REG_UPTIME				0x0b
drivers/hwmon/sg2042-mcu.c:26:#define REG_RESET_REASON			0x0d
drivers/hwmon/sg2042-mcu.c-27-#define REG_MCU_TYPE				0x18
--
drivers/media/dvb-frontends/lgs8gl5.c-19-
drivers/media/dvb-frontends/lgs8gl5.c:20:#define REG_RESET		0x02
drivers/media/dvb-frontends/lgs8gl5.c:21:#define REG_RESET_OFF			0x01
drivers/media/dvb-frontends/lgs8gl5.c-22-#define REG_03			0x03
--
drivers/media/usb/gspca/touptek.c=19=MODULE_LICENSE("GPL");
--
drivers/media/usb/gspca/touptek.c-122-#define REG_RED_GAIN			0x305A
drivers/media/usb/gspca/touptek.c:123:#define REG_RESET_REGISTER		0x301A
drivers/media/usb/gspca/touptek.c-124-#define REG_SCALE_M			0x0404
--
drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-121-
drivers/thunderbolt/nhi_regs.h:122:#define REG_RESET			0x39898
drivers/thunderbolt/nhi_regs.h:123:#define REG_RESET_HRR			BIT(0)
drivers/thunderbolt/nhi_regs.h-124-
]

39/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 31827
							output: 37
							thoughts: 195
						

Thoughts:
**My Debugging Journey: Tracing a Potential Memory Access Issue**

Alright, so I've been digging into this behavior, and it seems there's a discrepancy I need to resolve. My initial observation is that the `REG_RESET` register is defined with the hexadecimal value `0x39898`. This immediately flags a concern because it implies that the `nhi_reset` function is attempting to access this specific memory address.

The crux of the problem arises when I consider the BAR (Base Address Register) size. If this BAR is only 4KB, then an offset of `0x39898` is clearly far beyond its allocated boundaries. This should, in theory, lead to an immediate access violation – a crash.

However, this is where things get puzzling. The system *isn't* crashing at the point where `nhi_reset` attempts to access `0x39898`. This leads me to question my initial assumption or to suspect that there's some underlying mechanism I'm not fully accounting for.

To get to the bottom of this, I'm now meticulously examining the crash stack trace. I've noticed that `nhi_reset` is actually invoked *before* `nhi_disable_interrupts` is called, as clearly shown in the code snippet:

```c
	nhi_reset(nhi);

	/* In case someone left them on. */
	nhi_disable_interrupts(nhi);
```

This ordering is important. Given the potential out-of-bounds access I've identified, the fact that the crash *doesn't* occur within `nhi_reset` itself is the primary puzzle. My next step is to revisit the `nhi_reset` function's implementation in detail. I need to understand *why* it can seemingly access an address that appears to be out of bounds without immediately triggering an error. There must be a subtle aspect of its operation, or perhaps some prior state or hardware behavior, that is preventing the expected crash.


40/2 2026/08/10 08:22 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_reset]

Results:
map[SourceCode:1132:	static void nhi_reset(struct tb_nhi *nhi)
1133:	{
1134:		ktime_t timeout;
1135:		u32 val;
1136:	
1137:		val = ioread32(nhi->iobase + REG_CAPS);
1138:		/* Reset only v2 and later routers */
1139:		if (FIELD_GET(REG_CAPS_VERSION_MASK, val) < REG_CAPS_VERSION_2)
1140:			return;
1141:	
1142:		if (!host_reset) {
1143:			dev_dbg(nhi->dev, "skipping host router reset\n");
1144:			return;
1145:		}
1146:	
1147:		iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
1148:		msleep(100);
1149:	
1150:		timeout = ktime_add_ms(ktime_get(), 500);
1151:		do {
1152:			val = ioread32(nhi->iobase + REG_RESET);
1153:			if (!(val & REG_RESET_HRR)) {
1154:				dev_warn(nhi->dev, "host router reset successful\n");
1155:				return;
1156:			}
1157:			usleep_range(10, 20);
1158:		} while (ktime_before(ktime_get(), timeout));
1159:	
1160:		dev_warn(nhi->dev, "timeout resetting host router\n");
1161:	}
 SourceFile:drivers/thunderbolt/nhi.c]

41/2 2026/08/10 08:22 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 32538
							output: 24
							thoughts: 986
						

Thoughts:
**My Thought Process Unraveling the Crash**

Initially, I was tracking a potential crash point related to `nhi_reset` accessing address `0x39898`. My expectation was that if the Base Address Register (BAR) size was a mere 4KB, such an access would certainly lead to a crash. However, the actual crash manifested elsewhere, specifically within `nhi_disable_interrupts` at `0x38208`. This discrepancy immediately piqued my interest.

My next step was to compare these addresses. I noted that `0x39898` is indeed larger than `0x38208`. I then considered a BAR size of, let's say, `0x39000`. Under this assumption, `0x39898` would be out of bounds. But if it's out of bounds, why did the crash occur at `0x38208` instead? This led me to a moment of clarification: `0x38208 + 4 * 64 = 0x38308`. This calculation seemed to be a tangent, but I kept it in mind.

I returned to the BAR size of `0x39000`. Again, `0x39898` is out of bounds, and `nhi_reset` accesses it. So why no crash there? The crucial piece of information was the actual crash address: `ffffc90000f70208`. I deduced that this address must be a result of adding `nhi->iobase` to some offset.

By working backward, I found that if `nhi->iobase` was `ffffc90000f38000`, then `ffffc90000f38000 + 0x38208` perfectly yielded the crash address `ffffc90000f70208`. This confirmed `nhi->iobase` as the base. Consequently, `nhi->iobase + REG_RESET` (which is `0x39898`) would be `ffffc90000f71898`. The burning question then became: why didn't the system crash at *this* address (`ffffc90000f71898`) if it crashed at `ffffc90000f70208`?

My initial thought was that perhaps `ffffc90000f71898` was mapped while `ffffc90000f70208` was not. However, I quickly dismissed this, as `ioremap` typically maps a contiguous range of pages. If a range is mapped, all addresses within it should be accessible.

I then considered a BAR size of `0x40000` (256KB). With this size, both `0x38208` and `0x39898` would comfortably fall within the mapped region. This brought me back to the same puzzle: if `0x38208` is within the mapped region, why the page fault there?

The key to understanding the page fault at `ffffc90000f70208` lay in the error code: `0x0002` – a not-present page with supervisor write access. This unequivocally signifies that the page was *not* mapped. This directly contradicted my assumption of a `0x40000` BAR size.

The only logical conclusion was that the BAR size must be smaller than `0x38208`. I hypothesized a BAR size of `0x38000` (224KB). If this were the case, then `0x38208` would indeed be out of bounds, explaining the crash. But, if the BAR size is `0x38000`, then `0x39898` would *also* be out of bounds! So why did `nhi_reset` not crash?

This led me to re-examine `nhi_reset` itself. I saw the crucial `if` condition:
```c
	val = ioread32(nhi->iobase + REG_CAPS);
	/* Reset only v2 and later routers */
	if (FIELD_GET(REG_CAPS_VERSION_MASK, val) < REG_CAPS_VERSION_2)
		return;
```
This revealed that `nhi_reset` could simply return early if the router version (read from `REG_CAPS`) was less than version 2. This conditional return would explain why `nhi_reset` didn't trigger a crash, even if `0x39898` was out of bounds, by preventing the out-of-bounds access in the first place. The next critical step was to understand the role of `REG_CAPS_VERSION_MASK`.


42/2 2026/08/10 08:23 tool grepper
0m Args:
map[Expression:#define REG_CAPS_VERSION_MASK]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-114-#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h:115:#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
drivers/thunderbolt/nhi_regs.h-116-#define REG_CAPS_VERSION_2		0x40
]

43/2 2026/08/10 08:23 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 33669
							output: 40
							thoughts: 1166
						

Thoughts:
**My Thought Process on the Crash and Register Mapping**

This is quite the puzzle regarding the PCI device's memory-mapped I/O (MMIO) region. My initial understanding was that `REG_CAPS` held a value of `0`, but it's actually `0x39640`. This immediately raised a flag because the `nhi_probe` function accesses `nhi->iobase + REG_CAPS`. If `REG_CAPS` is indeed `0x39640`, then the probe function is trying to read from that specific offset.

The real concern here is the BAR size. If the BAR is small, say only 4KB, then an attempt to access `0x39640` would certainly cause a crash. However, the system *didn't* crash at `0x39640`. It crashed at `0x38208`. This suggests something is amiss with how these addresses are being mapped or accessed.

My first thought was that perhaps `0x39640` was mapped but `0x38208` was not. But that doesn't make sense with how `ioremap` works. `ioremap` maps a contiguous range of physical memory into the kernel's virtual address space. If `0x39640` is accessible, and it's within the same `ioremap`'d region as `0x38208`, then `0x38208` *must* also be accessible, unless the BAR is incredibly large and `ioremap` somehow failed to map a portion of it, which is unlikely. `ioremap` typically succeeds or fails entirely.

Could it be a permissions issue? Maybe `0x38208` was mapped as read-only? Again, this contradicts how `ioremap` functions; it generally maps memory as read-write.

Then I questioned my assumption about `nhi->iobase` being the *actual* start of the BAR. But `nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");` clearly indicates it's mapping BAR 0. If `pcim_iomap_region` successfully maps the BAR, it should map the *entire* BAR.

What if the BAR size is much larger, say `0x40000` (256KB)? In that scenario, both `0x38208` and `0x39640` would fall within the BAR. So, why the crash at `0x38208`?

I re-examined the crash address, `ffffc90000f70208`, and the instruction `mov %ebp,(%rbx)`, where `%rbx` points to the crash address. This instruction is a write operation. This led me to look at the `nhi_mask_interrupt` function. This function performs writes to `nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`.

Crucially, `REG_RING_INTERRUPT_MASK_CLEAR_BASE` is `0x38208`. The `ring` offset is calculated as `4 * i`. If `i` is sufficiently large, this offset could push the access beyond the BAR. However, my calculation showed that even with a large `hop_count` from `REG_CAPS` (`0x39640`), the calculated `ring` offset for `i=64` (resulting in `0x38308`) is still *less* than the `REG_CAPS` address. If `0x39640` was accessible, then `0x38308` should be too.

This brings me back to the crash at `0x38208` itself. If `0x39640` was mapped and readable, and the BAR is large enough to contain both, why would a write operation to `0x38208` cause a fault?

Then I noticed a specific quirk in `nhi_mask_interrupt`:
```c
	if (nhi->quirks & QUIRK_AUTO_CLEAR_INT) {
		// ... read-modify-write to REG_RING_INTERRUPT_BASE + ring
	} else {
		iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
	}
```
The problematic write to `REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring` (which is `0x38208` when `ring` is 0) occurs when `QUIRK_AUTO_CLEAR_INT` is *not* set. This is the branch that's being taken.

This makes me wonder if the issue isn't so much about an unmapped region, but rather a region that is *expected* to be writable and is being written to, but is somehow protected or invalid in a way that triggers a fault. The fact that it happens at `0x38208` precisely when the function attempts to write there, and this write is part of the non-quirky path, is highly suspicious. I need to delve deeper into `nhi_pci_probe` to understand the exact conditions under which `QUIRK_AUTO_CLEAR_INT` is set and what the implications are for this specific MMIO region.


44/2 2026/08/10 08:23 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

45/2 2026/08/10 08:23 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 34996
							output: 35
							thoughts: 279
						

Thoughts:
**My Thought Process Regarding PCI Resource Handling and Potential Out-of-Bounds Access**

Okay, so I've just come across the `nhi_pci_probe` function, and my mind immediately jumps to potential failure scenarios. I see that `pcim_iomap_region` is being used to map the PCI device's I/O region, and this function, as I know, can return an error pointer if it fails. The code correctly checks for this with `PTR_ERR_OR_ZERO` and returns a `dev_err_probe` if an error occurs. That part seems robust enough.

However, my attention is then drawn to the success path. If `pcim_iomap_region` *does* succeed, it returns a valid pointer. This is where my concern starts to bloom. I'm thinking, what happens if the size of the Base Address Register (BAR) that was mapped is exactly `0x38000`? My immediate thought is that if the BAR size is indeed `0x38000`, then accessing an offset like `0x38208` would clearly be out of bounds.

But then, I recall that `REG_CAPS` is defined as `0x39640`. This immediately triggers another alarm in my mind: if the BAR size is only `0x38000`, then accessing `REG_CAPS` at `0x39640` would *also* be out of bounds! This is a critical observation.

The crucial question then becomes: why didn't the system crash when `REG_CAPS` was being read? This implies there's a subtle detail I might be overlooking or that the underlying hardware/software interaction is more forgiving than I initially assume, or perhaps there's a prior check that prevents this specific read from happening in the problematic scenario.

To understand this, I need to delve deeper into how `ioread32` actually functions. I know that on x86 architectures, `ioread32` is implemented within `lib/iomap.c`. My next step would be to examine that implementation closely to see if there are any built-in checks, assumptions, or mechanisms that could explain why an out-of-bounds read in this context might not immediately result in a crash, especially if the BAR mapping itself was successful up to `0x38000`. I suspect there might be some underlying PCI bus handling or memory management behavior that's masking this potential issue, or perhaps the BAR size is not as rigidly enforced as I'm initially thinking in this specific scenario.


46/2 2026/08/10 08:23 tool codesearch-definition-source
0m Args:
map[ContextFile:lib/iomap.c Name:ioread32]

Results:
map[SourceCode:  97:	unsigned int ioread32(const void __iomem *addr)
  98:	{
  99:		IO_COND(addr, return inl(port), return readl(addr));
 100:		return 0xffffffff;
 101:	}
 SourceFile:lib/iomap.c]

47/2 2026/08/10 08:23 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 35394
							output: 41
							thoughts: 2896
						

Thoughts:
**The Curious Case of the Unmapped MMIO Region**

I've been trying to get to the bottom of this rather perplexing crash, and I think I'm starting to piece together a clearer picture of what's going on, or rather, *not* going on, in this MMIO access.

Initially, I was focused on the `IO_COND` check, thinking it might be related to whether the `addr` was a PIO address or not. If it's a memory address, the code calls `readl(addr)`. My immediate concern, as any kernel developer would have, was that if `addr` falls outside the range of the memory region that was `ioremap`ped, `readl` would certainly trigger a page fault.

Then I started considering the `nhi->iobase`. I know that if it's an `ioremap`ped address, it resides within the `vmalloc` area, typically starting with `0xffffc900...`. The size of the BAR is crucial here. If the BAR size is, say, `0x40000`, `ioremap` will map that many bytes. Similarly, a `0x38000` BAR size maps `0x38000` bytes.

My reasoning then led me to believe that `ioremap` maps memory in PAGE_SIZE chunks. For a BAR size of `0x38000`, which is a multiple of 4KB, `ioremap` would map exactly `0x38000` bytes. This implies that an access to `0x38208` (which is `0x38000 + 0x208`) would land in the *next* page, a page that, according to this logic, should be unmapped, thus causing a page fault. The same logic applied to `0x39640` – it also seemed to fall into an unmapped page.

This is where the confusion really set in: if `0x38208` and `0x39640` are in unmapped pages, why didn't `ioread32(nhi->iobase + REG_CAPS)` – an access to `0x39640` – crash?

I re-examined the crash trace carefully. It clearly shows the fault occurring in `iowrite32` which is called by `nhi_mask_interrupt`. Looking at the call trace, `nhi_probe` calls `nhi_reset` *before* `nhi_disable_interrupts`. The relevant snippet in `nhi_probe` looks like this:

```c
	nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
	// ... allocation of tx_rings and rx_rings ...
	nhi_reset(nhi);
	nhi_disable_interrupts(nhi);
```

This sequence is critical. If `ioread32(nhi->iobase + REG_CAPS)` did *not* crash, it strongly suggests that the address `nhi->iobase + 0x39640` *was* mapped. If that address was mapped, and `ioremap` creates a contiguous virtual address range, then `nhi->iobase + 0x38208` *must* also be mapped, especially if the BAR size exceeds `0x39640`. So, why the page fault at `0x38208`?

I then focused on the crash address itself: `ffffc90000f70208`. The initial thought was that `nhi->iobase` was `ffffc90000f38000`. If that were the case, then `nhi->iobase + 0x38208` would indeed be `ffffc90000f70208`, and `nhi->iobase + 0x39640` would be `ffffc90000f71640`. The core of my confusion was how `ffffc90000f71640` could be mapped if `ffffc90000f70208` was not. This contradicts the contiguous mapping behavior of `ioremap`.

I started to question my assumption about `nhi->iobase`. What if `nhi->iobase` wasn't `ffffc90000f38000`? If the fault address is `ffffc90000f70208`, and this is `nhi->iobase + 0x38208` (assuming `ring=0` and offset `0x38208`), then `nhi->iobase` must be `ffffc90000f38000`. This seems to circle back.

I also considered if `nhi->iobase` could be a PIO address. However, `pcim_iomap_region` returns a memory address, and the fault address is clearly a `vmalloc` address, not a PIO address (which would start around `0x10000`).

Then I thought about the loop in `nhi_mask_interrupt` which iterates up to `RING_INTERRUPT_REG_COUNT(nhi)`. Even with a large `nhi->hop_count`, the offsets `0x38208` and `0x38304` (for `i=63`) are still well within the `0x39640` boundary. And if `nhi->hop_count` were 0, the loop wouldn't execute at all, but the crash indicates it did.

My key realization finally came when I considered the possibility that `nhi->iobase` itself is the base address of the mapped region, and the crash address `ffffc90000f70208` is the *actual offending memory location*. If `nhi->iobase + 0x38208` is the address that triggered the page fault, and this address is `ffffc90000f70208`, then it logically implies that `nhi->iobase` must have been `ffffc90000f38000`. However, if `nhi->iobase` is indeed `ffffc90000f38000`, then `REG_CAPS` (at `0x39640` offset) would be at `ffffc90000f71640`. The puzzling part remains: why was `ffffc90000f71640` accessible but `ffffc90000f70208` not?

The breakthrough came from re-evaluating the assumption that `nhi->iobase` is `ffffc90000f38000`. What if `nhi->iobase` is simply the base pointer provided by `ioremap`, and the crash occurs *at* that pointer plus an offset? The crash address is `ffffc90000f70208`. If this is the address being accessed, and it's within the `ioremap`ped region, then `nhi->iobase` *must* be at or before this address, and the offset `0x38208` must be added to `nhi->iobase` to reach the faulting address. This implies that the `nhi->iobase` itself is actually `ffffc90000f38000` if the offset is `0x38208`. The critical insight is that the *actual* `ioremap` base might be different from the calculated `nhi->iobase`.

Ultimately, the fact that the crash occurs at `ffffc90000f70208` within the `iowrite32` call, and we know this is `nhi->iobase + offset`, means that the `nhi->iobase` must be `ffffc90000f38000` if the offset is `0x38208`. The paradox lies in `REG_CAPS` being readable at `0x39640` relative to this same `nhi->iobase`, while an offset of `0x38208` leads to a page fault. This suggests that the `ioremap`ped region itself might be unexpectedly fragmented or that there's a fundamental misunderstanding of the base address and the mapping boundaries.


48/2 2026/08/10 08:24 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/pci/devres.c Name:pcim_iomap_region]

Results:
map[SourceCode: 593:	/**
 594:	 * pcim_iomap_region - Request and iomap a PCI BAR
 595:	 * @pdev: PCI device to map IO resources for
 596:	 * @bar: Index of a BAR to map
 597:	 * @name: Name of the driver requesting the resource
 598:	 *
 599:	 * Returns: __iomem pointer on success, an IOMEM_ERR_PTR on failure.
 600:	 *
 601:	 * Mapping and region will get automatically released on driver detach. If
 602:	 * desired, release manually only with pcim_iounmap_region().
 603:	 */
 604:	void __iomem *pcim_iomap_region(struct pci_dev *pdev, int bar,
 605:					       const char *name)
 606:	{
 607:		int ret;
 608:		struct pcim_addr_devres *res;
 609:	
 610:		if (!pci_bar_index_is_valid(bar))
 611:			return IOMEM_ERR_PTR(-EINVAL);
 612:	
 613:		res = pcim_addr_devres_alloc(pdev);
 614:		if (!res)
 615:			return IOMEM_ERR_PTR(-ENOMEM);
 616:	
 617:		res->type = PCIM_ADDR_DEVRES_TYPE_REGION_MAPPING;
 618:		res->bar = bar;
 619:	
 620:		ret = pci_request_region(pdev, bar, name);
 621:		if (ret != 0)
 622:			goto err_region;
 623:	
 624:		res->baseaddr = pci_iomap(pdev, bar, 0);
 625:		if (!res->baseaddr) {
 626:			ret = -EINVAL;
 627:			goto err_iomap;
 628:		}
 629:	
 630:		devres_add(&pdev->dev, res);
 631:		return res->baseaddr;
 632:	
 633:	err_iomap:
 634:		pci_release_region(pdev, bar);
 635:	err_region:
 636:		pcim_addr_devres_free(res);
 637:	
 638:		return IOMEM_ERR_PTR(ret);
 639:	}
 SourceFile:drivers/pci/devres.c]

49/2 2026/08/10 08:24 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 39044
							output: 39
							thoughts: 803
						

Thoughts:
**My Thought Process on the Potential PCI BAR Out-of-Bounds Issue**

Okay, let me try to retrace my steps and articulate my current line of thinking here. It seems I was initially focused on a potential out-of-bounds access related to PCI BAR mapping and then I'm veering into a loop iteration issue. Let me break it down:

My first thought was that `pci_iomap` would map a region of memory corresponding to a PCI BAR, and the size of that mapped region would be dictated by `pci_resource_len(pdev, bar)`. So, if a BAR was only 4KB, `nhi->iobase` would point to a 4KB mapped region. Then, when I saw `ioread32(nhi->iobase + 0x39640)`, my immediate alarm bell went off: `0x39640` is significantly larger than 4KB, meaning this access would *have* to be out of bounds. This naturally led me to question why such an access didn't immediately cause a crash.

This is where I started digging into the crash trace. The trace explicitly states the crash happened in `iowrite32`, not `ioread32`, which was a critical distinction. This made me reconsider my initial assumption. If `ioread32` *didn't* crash, perhaps the problem wasn't that the BAR was too small for the `0x39640` offset.

This led me to an alternative hypothesis: what if the BAR size was actually much larger than I initially assumed? Specifically, if the BAR size was `0x40000` (256KB), then `0x39640` would be a perfectly valid offset within the mapped region. Similarly, `0x38208` would also be within bounds.

But then the core of the problem resurfaced: why *did* `iowrite32` crash at `0x38208` if the BAR was `0x40000` and the offset was within bounds? This is when I looked closer at the `nhi_disable_interrupts` function, specifically the loop:

```c
	for (i = 0; i < RING_INTERRUPT_REG_COUNT(nhi); i++)
		nhi_mask_interrupt(nhi, ~0, 4 * i);
```

My attention was drawn to `RING_INTERRUPT_REG_COUNT(nhi)`, which is defined as `((31 + 2 * nhi->hop_count) / 32)`. I then considered the scenario where `nhi->hop_count` could be large, for instance, `0x3ff` (1023). In this case, `RING_INTERRUPT_REG_COUNT` would evaluate to 64. This means the loop variable `i` would iterate from 0 to 63.

Consequently, the value `ring`, calculated as `4 * i`, would go up to `4 * 63 = 252`.
Adding this to `REG_RING_INTERRUPT_MASK_CLEAR_BASE` (which is `0x38208`), the maximum access would be `0x38208 + 252 = 0x38304`.

Even with this maximum offset, my analysis indicated that `0x38304` is still well within the bounds of a `0x40000` BAR. So, if the BAR size is indeed `0x40000`, I'm still struggling to understand why `iowrite32` would crash.

This brings me back to the initial assumption about the BAR size. The key question is: what if `nhi->hop_count` is *not* derived from a value that would result in `RING_INTERRUPT_REG_COUNT` being 64 or less, or more importantly, what if `nhi->hop_count` itself isn't what I'm expecting, or that the value used to calculate the loop count is somehow larger than anticipated?

My current unresolved thought is whether `nhi->hop_count` is being read correctly, or if the value it's based on, perhaps `REG_CAPS`, isn't at the offset I'm assuming it is (`0x39640`), or if there's another mechanism at play that's making `nhi->hop_count` arbitrarily large, thus increasing the loop iterations to a point where the final calculated address *does* exceed the BAR size, even if the BAR size itself is `0x40000`. I need to re-verify where `nhi->hop_count` is sourced from and how it influences the loop termination condition.


50/2 2026/08/10 08:24 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/nhi_regs.h Name:REG_CAPS]

Results:
map[SourceCode: SourceFile:]

51/2 2026/08/10 08:24 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 39891
							output: 20
							thoughts: 122
						

Thoughts:
**My Thought Process Unfolding**

Alright, so I'm looking at this piece of code, and my first instinct, based on the context, is that I'm dealing with a macro. I've already run a `grep` on it, and it initially surfaced this:

```c
#define REG_CAPS			0x00
```

That's... not what I expected. My internal radar is pinging because I distinctly recall a different value for `REG_CAPS` from a prior search. Let me backtrack and check my previous `grep` output again. Ah, yes, here it is:

```
drivers/thunderbolt/nhi_regs.h-114-#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h:115:#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
```

Okay, so I have a discrepancy. One `grep` is showing `0x00`, and the other, more recent one, clearly indicates `0x39640` within the `drivers/thunderbolt/nhi_regs.h` file. This is a critical detail. To be absolutely certain and to eliminate any ambiguity from potential partial matches or incorrect assumptions during my initial grep, I need to perform a very specific search. I'll grep for `REG_CAPS` precisely, ensuring that I'm only getting results where that exact token is used as the macro name. This will help me pinpoint the definitive definition and resolve this apparent conflict in my recorded findings.


52/2 2026/08/10 08:24 tool grepper
0m Args:
map[Expression:#define REG_CAPS]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-113-/* The last 11 bits contain the number of hops supported by the NHI port. */
drivers/thunderbolt/nhi_regs.h:114:#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h:115:#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
drivers/thunderbolt/nhi_regs.h:116:#define REG_CAPS_VERSION_2		0x40
drivers/thunderbolt/nhi_regs.h-117-
]

53/2 2026/08/10 08:24 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 40208
							output: 22
							thoughts: 106
						

Thoughts:
**My Thought Process Regarding `REG_CAPS`**

My initial understanding was that `REG_CAPS` held a value of `0`. However, upon re-examining the code, specifically within the `nhi_probe` function where I see `nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;`, I've encountered a discrepancy. This line clearly indicates that `REG_CAPS` is being read from hardware and is expected to have a non-zero value, specifically `0x39640` as I've now ascertained. This brings up a crucial question for me: could there be another instance or definition of `REG_CAPS` that I'm overlooking, or was my initial assumption about its value simply incorrect? I need to thoroughly investigate the context and any other definitions to resolve this apparent contradiction.


54/2 2026/08/10 08:25 tool grepper
0m Args:
map[Expression:#define REG_CAPS\b]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-113-/* The last 11 bits contain the number of hops supported by the NHI port. */
drivers/thunderbolt/nhi_regs.h:114:#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h-115-#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
]

55/2 2026/08/10 08:25 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 40463
							output: 42
							thoughts: 95
						

Thoughts:
**My Thought Process**

Okay, so I'm looking at the `nhi_probe` function, specifically this line:

```c
nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
```

My immediate reaction is to question what `REG_CAPS` actually resolves to. I recall, or am about to verify, that `REG_CAPS` is defined as `0x00` within `drivers/thunderbolt/nhi_regs.h`. This seems a bit… direct. Reading from offset `0x00` of `nhi->iobase` and then masking with `0x3ff`. It makes me pause and think, "Is this the intended way to get the hop count, or am I missing something subtle?" I'm now going to go directly to `drivers/thunderbolt/nhi_regs.h` to confirm this value and see the context surrounding its definition. This is a crucial step for understanding the hardware interaction and the driver's logic.


56/2 2026/08/10 08:25 tool read-file
0m Error:
log-in to see details

Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:1 LineCount:100]

57/2 2026/08/10 08:25 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 40607
							output: 38
							thoughts: 11
						

Thoughts:
**My Thought Process on `FirstLine`**

Alright, so I'm looking at this piece of code or data structure, and the variable name `FirstLine` immediately catches my eye. Given the context I'm operating within – and I'm assuming a typical programming or data analysis scenario where variable naming conventions are somewhat sensible – the most logical interpretation that springs to mind is that `FirstLine` represents a numerical value, specifically an integer. My internal reasoning is based on a few key assumptions:

*   **Naming Convention:** Variable names like "FirstLine" often imply a position, an index, or a count. When these kinds of positional or quantitative concepts are represented programmatically, they are overwhelmingly handled using integer data types. It's rare, bordering on an anti-pattern, to see a "line number" or "first occurrence" represented as a floating-point number or a string unless there's a very specific, unusual reason.

*   **Practical Use Cases:** What would I *do* with `FirstLine`? I'd likely use it to access an element in a collection (like an array or list), to iterate a certain number of times, or to perform some calculation where a whole number is required. Imagine `my_list[FirstLine]` or `for i in range(FirstLine):`. These operations intrinsically demand integer values.

*   **Absence of Counter-Indicators:** There's nothing in the name itself or in any surrounding information I might have access to that suggests otherwise. There's no hint of decimal places (like `FirstLineValue` might imply, though even then integer is common) or textual data (like `FirstLineText`).

Therefore, my immediate, strong inference is that `FirstLine` is intended to hold and be treated as an integer. This is the most parsimonious and practical assumption, forming the bedrock of my understanding for how to interact with or interpret this particular piece of information.


58/2 2026/08/10 08:25 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:1 LineCount:100]

Results:
map[Contents:   1:	/* SPDX-License-Identifier: GPL-2.0 */
   2:	/*
   3:	 * Thunderbolt driver - NHI registers
   4:	 *
   5:	 * Copyright (c) 2014 Andreas Noever <andreas.noever@gmail.com>
   6:	 * Copyright (C) 2018, Intel Corporation
   7:	 */
   8:	
   9:	#ifndef NHI_REGS_H_
  10:	#define NHI_REGS_H_
  11:	
  12:	#include <linux/types.h>
  13:	
  14:	enum ring_flags {
  15:		RING_FLAG_ISOCH_ENABLE = 1 << 27, /* TX only? */
  16:		RING_FLAG_E2E_FLOW_CONTROL = 1 << 28,
  17:		RING_FLAG_PCI_NO_SNOOP = 1 << 29,
  18:		RING_FLAG_RAW = 1 << 30, /* ignore EOF/SOF mask, include checksum */
  19:		RING_FLAG_ENABLE = 1 << 31,
  20:	};
  21:	
  22:	/**
  23:	 * struct ring_desc - TX/RX ring entry
  24:	 * @phys: DMA mapped address of the frame
  25:	 * @length: Size of the ring
  26:	 * @eof: End of frame protocol defined field
  27:	 * @sof: Start of frame protocol defined field
  28:	 * @flags: Ring descriptor flags
  29:	 * @time: Fill with zero
  30:	 *
  31:	 * For TX set length/eof/sof.
  32:	 * For RX length/eof/sof are set by the NHI.
  33:	 */
  34:	struct ring_desc {
  35:		u64 phys;
  36:		u32 length:12;
  37:		u32 eof:4;
  38:		u32 sof:4;
  39:		enum ring_desc_flags flags:12;
  40:		u32 time; /* write zero */
  41:	} __packed;
  42:	
  43:	/* NHI registers in bar 0 */
  44:	
  45:	/*
  46:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  47:	 * 00: physical pointer to an array of struct ring_desc
  48:	 * 08: ring tail (set by NHI)
  49:	 * 10: ring head (index of first non posted descriptor)
  50:	 * 12: descriptor count
  51:	 */
  52:	#define REG_TX_RING_BASE	0x00000
  53:	
  54:	/*
  55:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  56:	 * 00: physical pointer to an array of struct ring_desc
  57:	 * 08: ring head (index of first not posted descriptor)
  58:	 * 10: ring tail (set by NHI)
  59:	 * 12: descriptor count
  60:	 * 14: max frame sizes (anything larger than 0x100 has no effect)
  61:	 */
  62:	#define REG_RX_RING_BASE	0x08000
  63:	
  64:	/*
  65:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  66:	 * 00: enum_ring_flags
  67:	 * 04: isoch time stamp ?? (write 0)
  68:	 * ..: unknown
  69:	 */
  70:	#define REG_TX_OPTIONS_BASE	0x19800
  71:	
  72:	/*
  73:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  74:	 * 00: enum ring_flags
  75:	 *     If RING_FLAG_E2E_FLOW_CONTROL is set then bits 13-23 must be set to
  76:	 *     the corresponding TX hop id.
  77:	 * 04: EOF/SOF mask (ignored for RING_FLAG_RAW rings)
  78:	 * ..: unknown
  79:	 */
  80:	#define REG_RX_OPTIONS_BASE	0x29800
  81:	#define REG_RX_OPTIONS_E2E_HOP_MASK	GENMASK(22, 12)
  82:	#define REG_RX_OPTIONS_E2E_HOP_SHIFT	12
  83:	
  84:	/*
  85:	 * three bitfields: tx, rx, rx overflow
  86:	 * Every bitfield contains one bit for every hop (REG_CAPS).
  87:	 * New interrupts are fired only after ALL registers have been
  88:	 * read (even those containing only disabled rings).
  89:	 */
  90:	#define REG_RING_NOTIFY_BASE	0x37800
  91:	#define RING_NOTIFY_REG_COUNT(nhi) ((31 + 3 * nhi->hop_count) / 32)
  92:	#define REG_RING_INT_CLEAR	0x37808
  93:	
  94:	/*
  95:	 * two bitfields: rx, tx
  96:	 * Both bitfields contains one bit for every hop (REG_CAPS). To
  97:	 * enable/disable interrupts set/clear the corresponding bits.
  98:	 */
  99:	#define REG_RING_INTERRUPT_BASE	0x38200
 100:	#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
]

59/2 2026/08/10 08:25 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 42217
							output: 40
							thoughts: 10
						

Thoughts:
**My Thought Process for Approaching the Remaining File Content**

Alright, the immediate next step for me, as a seasoned professional in this domain, is to engage with the rest of this file. My intention is to absorb and process all of its contents thoroughly. I'm not just skimming; I'm looking to understand the nuances, the context, and the full scope of what's being presented. This isn't about a superficial glance; it's about a deep dive, ensuring no critical detail or subtle implication is missed. My goal is to build a complete and accurate picture, integrating this new information seamlessly with my existing knowledge base to form a comprehensive understanding.


60/2 2026/08/10 08:25 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:101 LineCount:100]

Results:
map[Contents: 101:	
 102:	#define REG_RING_INTERRUPT_MASK_CLEAR_BASE	0x38208
 103:	
 104:	#define REG_INT_THROTTLING_RATE			0x38c00
 105:	#define REG_INT_THROTTLING_RATE_INTERVAL_MASK	GENMASK(15, 0)
 106:	
 107:	/* Interrupt Vector Allocation */
 108:	#define REG_INT_VEC_ALLOC_BASE	0x38c40
 109:	#define REG_INT_VEC_ALLOC_BITS	4
 110:	#define REG_INT_VEC_ALLOC_MASK	GENMASK(3, 0)
 111:	#define REG_INT_VEC_ALLOC_REGS	(32 / REG_INT_VEC_ALLOC_BITS)
 112:	
 113:	/* The last 11 bits contain the number of hops supported by the NHI port. */
 114:	#define REG_CAPS			0x39640
 115:	#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
 116:	#define REG_CAPS_VERSION_2		0x40
 117:	
 118:	#define REG_DMA_MISC			0x39864
 119:	#define REG_DMA_MISC_INT_AUTO_CLEAR     BIT(2)
 120:	#define REG_DMA_MISC_DISABLE_AUTO_CLEAR	BIT(17)
 121:	
 122:	#define REG_RESET			0x39898
 123:	#define REG_RESET_HRR			BIT(0)
 124:	
 125:	#define REG_INMAIL_DATA			0x39900
 126:	
 127:	#define REG_INMAIL_CMD			0x39904
 128:	#define REG_INMAIL_CMD_MASK		GENMASK(7, 0)
 129:	#define REG_INMAIL_ERROR		BIT(30)
 130:	#define REG_INMAIL_OP_REQUEST		BIT(31)
 131:	
 132:	#define REG_OUTMAIL_CMD			0x3990c
 133:	#define REG_OUTMAIL_CMD_OPMODE_SHIFT	8
 134:	#define REG_OUTMAIL_CMD_OPMODE_MASK	GENMASK(11, 8)
 135:	
 136:	#define REG_FW_STS			0x39944
 137:	#define REG_FW_STS_NVM_AUTH_DONE	BIT(31)
 138:	#define REG_FW_STS_CIO_RESET_REQ	BIT(30)
 139:	#define REG_FW_STS_ICM_EN_CPU		BIT(2)
 140:	#define REG_FW_STS_ICM_EN_INVERT	BIT(1)
 141:	#define REG_FW_STS_ICM_EN		BIT(0)
 142:	
 143:	/* ICL NHI VSEC registers */
 144:	
 145:	/* FW ready */
 146:	#define VS_CAP_9			0xc8
 147:	#define VS_CAP_9_FW_READY		BIT(31)
 148:	/* UUID */
 149:	#define VS_CAP_10			0xcc
 150:	#define VS_CAP_11			0xd0
 151:	/* LTR */
 152:	#define VS_CAP_15			0xe0
 153:	#define VS_CAP_16			0xe4
 154:	/* TBT2PCIe */
 155:	#define VS_CAP_18			0xec
 156:	#define VS_CAP_18_DONE			BIT(0)
 157:	/* PCIe2TBT */
 158:	#define VS_CAP_19			0xf0
 159:	#define VS_CAP_19_VALID			BIT(0)
 160:	#define VS_CAP_19_CMD_SHIFT		1
 161:	#define VS_CAP_19_CMD_MASK		GENMASK(7, 1)
 162:	/* Force power */
 163:	#define VS_CAP_22			0xfc
 164:	#define VS_CAP_22_FORCE_POWER		BIT(1)
 165:	#define VS_CAP_22_DMA_DELAY_MASK	GENMASK(31, 24)
 166:	#define VS_CAP_22_DMA_DELAY_SHIFT	24
 167:	
 168:	/**
 169:	 * enum icl_lc_mailbox_cmd - ICL specific LC mailbox commands
 170:	 * @ICL_LC_GO2SX: Ask LC to enter Sx without wake
 171:	 * @ICL_LC_GO2SX_NO_WAKE: Ask LC to enter Sx with wake
 172:	 * @ICL_LC_PREPARE_FOR_RESET: Prepare LC for reset
 173:	 */
 174:	enum icl_lc_mailbox_cmd {
 175:		ICL_LC_GO2SX = 0x02,
 176:		ICL_LC_GO2SX_NO_WAKE = 0x03,
 177:		ICL_LC_PREPARE_FOR_RESET = 0x21,
 178:	};
 179:	
 180:	#endif
]

61/2 2026/08/10 08:25 llm initial-researcher
1m Model:
gemini-3.1-pro-preview

Tokens:
							input: 43797
							output: 21
							thoughts: 5353
						

Thoughts:
**A Deep Dive into a Mysterious Page Fault: The Case of the Unmapped PCI BAR**

I've been wrestling with a particularly stubborn kernel crash, a `#PF: supervisor write access in kernel mode` with an `error_code(0x0002 - not-present page)`. The address in question is `ffffc90000f70208`. My initial instinct was that this pointed to an out-of-bounds memory access within the Thunderbolt host controller driver (let's call it `nhi`).

My first hypothesis was centered around the `REG_CAPS` register, located at offset `0x39640`. If the Base Address Register (BAR) size was too small, say `0x38000`, then `0x39640` would clearly be outside the mapped region, and an attempt to read it via `ioread32` should have triggered a page fault. The `ioread32` function, after all, uses `readl` internally, which is designed to fault on unmapped memory.

However, the `ioread32` call to `nhi->iobase + 0x39640` didn't crash. This was perplexing. My `nhi->iobase` was `ffffc90000f38000`, and the calculated address `0x39640` ended up as `ffffc90000f71640`. If this address *was* mapped, then `ioread32` wouldn't fault.

This led me to think about the implications of `ioremap`. When `ioremap` is used to map a BAR, it maps a contiguous range of physical memory. If `0x39640` was mapped, then any address within the `ioremap`-ed range, from `nhi->iobase` up to `nhi->iobase + BAR_size`, *should* also be mapped. Specifically, if `0x39640` was mapped, then `0x38208` (which is `ffffc90000f70208`) *must* also be mapped, assuming the BAR was large enough to encompass `0x39640`.

The problem was, the crash occurred precisely when writing to `ffffc90000f70208`, which corresponds to `nhi->iobase + 0x38208`. The error message was unequivocal: "not-present page." This directly contradicted the idea that `0x39640` was mapped while `0x38208` was not. How could one be mapped and the other not, if they fall within the same `ioremap`'d region?

I began to consider alternative explanations. Could `ioremap` have mapped a larger chunk, but then some pages were somehow unmapped? Unlikely, as `ioremap` doesn't behave that way. Perhaps `nhi->iobase` itself wasn't `ffffc90000f38000`? But if it were something else, how would the crash address `ffffc90000f70208` relate to `nhi->iobase + 0x38208`?

Then I scrutinized the crash context. The crash was happening during `nhi_disable_interrupts`, which is called after `nhi_reset`. The fact that `nhi_reset` *didn't* crash implies it successfully accessed `REG_CAPS` (`0x39640`) and `REG_RESET` (`0x39898`). If `0x39898` was accessible, then `0x38208` *should* have been too. This brought me back to the core puzzle.

A critical insight emerged when I examined the `nhi_mask_interrupt` function. It has a conditional branch based on `nhi->quirks & QUIRK_AUTO_CLEAR_INT`. If the quirk is *not* set, it writes to `nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`, where `REG_RING_INTERRUPT_MASK_CLEAR_BASE` is `0x38208`. The `ring` value is calculated as `4 * i`, where `i` is limited by `RING_INTERRUPT_REG_COUNT(nhi)`. I calculated that even with the maximum possible `nhi->hop_count`, `i` would be at most 63, leading to a maximum `ring` of 252. This meant the highest address accessed would be `0x38208 + 252 = 0x38304`. This is still well below `0x39640`, so if `0x39640` was mapped, `0x38304` should have been too.

This led me to a radical re-evaluation. What if the BAR size was *much* smaller than I assumed, specifically smaller than `0x38208`? If the BAR size was, say, only 4KB, then `ioremap` would map only `ffffc90000f38000` to `ffffc90000f38fff`. In this scenario, `0x38208` (which is `ffffc90000f70208`) would indeed be unmapped, causing the page fault.

But this immediately presented a new problem: if the BAR was only 4KB, then `REG_CAPS` at `0x39640` would also be out of bounds and unmapped. Why didn't the `ioread32(nhi->iobase + REG_CAPS)` call in `nhi_probe` crash?

Here's where the syzkaller environment and memory mapping nuances came into play. It's possible, especially in a virtualized or heavily instrumented environment like syzkaller's, for memory pages to be mapped for reasons entirely unrelated to the current driver's `ioremap`. If the page containing `ffffc90000f71640` (where `REG_CAPS` is located) happened to be mapped by coincidence due to some other kernel allocation in the vmalloc space, then `ioread32` would read garbage data but wouldn't crash. If this garbage data coincidentally had the correct bits set (like `REG_CAPS_VERSION_2`), the `nhi_reset` function might proceed, even though it's operating on nonsensical values. This could lead to the observed "timeout resetting host router" because the device wouldn't actually reset correctly.

Meanwhile, the page containing `0x38208` (`ffffc90000f70208`) might *not* have been mapped by coincidence. Thus, the `iowrite32` in `nhi_disable_interrupts` would then trigger the page fault.

This theory perfectly explains the observed behavior: a non-crashing read from an out-of-bounds address (due to a coincidental mapping) followed by a crashing write to another out-of-bounds address (because its page was *not* coincidentally mapped).

The fundamental bug, therefore, is the lack of a proper check for the BAR size during driver initialization. The driver assumes the BAR is large enough to hold all its registers, but it doesn't verify this assumption. If a PCI device with a small BAR is presented, this leads to an out-of-bounds access, the consequences of which depend on the memory mapping landscape at the time of access. The crash at `0x38208` rather than `0x39640` is an artifact of this landscape, but the underlying issue is the same: the driver should have validated the BAR size upfront.


62/2 2026/08/10 08:26 tool grepper
0m Error:
log-in to see details

Args:
map[Expression:syz_pci_device]

Results:
map[Output:]

63/2 2026/08/10 08:26 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 49172
							output: 34
							thoughts: 521
						

Thoughts:
**My Thought Process Unpacking the Thunderbolt Driver Bug**

Okay, so the first thing that caught my eye was that "Important note" about syzkaller descriptions and expressions with 'syz_'. It explicitly states that *this tool* (meaning the one I'm operating under) cannot search those, and I should use `read-syz-spec` or `syz-grepper` instead. My immediate reaction is, "Right, I don't have those tools available here." That's a constraint I need to keep in mind.

Then I jump to the core of the problem: how can a C program actually inject a PCI device? My understanding is that normally, you can't just conjure up a new PCI device from unprivileged userspace without some special kernel module doing the heavy lifting. This raises a flag – is the bug about *creating* a new device?

But then I re-read the bug report, and it says: `thunderbolt 0000:00:07.0: timeout resetting host router`. That `0000:00:07.0` is a PCI device. This leads me to a crucial pivot: what if the bug isn't about *injecting* a new device, but about binding an *existing* PCI device to the `thunderbolt` driver? This is a much more plausible scenario for an unprivileged user.

So, I start thinking about the environment. The report mentions QEMU. In QEMU, especially with the standard PC setup (Q35 + ICH9, 2009), `0000:00:07.0` might actually represent a device that *already exists* in the emulated hardware. My next step is to figure out *what* device `0000:00:07.0` typically is in that QEMU configuration. I'm mentally digging through my knowledge of QEMU's Q35 PCI device mappings. I recall device 7 is often something like `piix4-ide` or a similar chipset component.

The hypothesis solidifies: if syzkaller can manage to bind an existing PCI device to the `thunderbolt` driver, that driver will then try to `probe` it. And here's where the vulnerability might lie: if that *existing* PCI device happens to have a small BAR 0, say only 4KB, then when the `thunderbolt` driver maps it and attempts to access offset `0x39640` within that BAR, it will result in an out-of-bounds access. This is the potential trigger for the bug.

Now, the question becomes: how do I even *attempt* to bind a device to a driver? The mechanism I know is writing the device's PCI address (like `0000:00:07.0`) to `/sys/bus/pci/drivers/thunderbolt/bind`.

But then another nuance surfaces: what about the `nhi_pci_probe` function? I'm wondering if it performs a PCI ID check. My initial thought is that the PCI core should handle the PCI ID filtering *before* calling the `probe` function itself. However, if I'm manually writing to the `bind` file, does the PCI core *still* enforce that PCI ID check? I need to verify this. My next logical step is to dive into the kernel source, specifically looking at `bind_store` within `drivers/base/bus.c`, to understand exactly how that manual binding process is handled and what checks are in place.


64/2 2026/08/10 08:27 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/base/bus.c Name:bind_store]

Results:
map[SourceCode: 253:	/*
 254:	 * Manually attach a device to a driver.
 255:	 * Note: the driver must want to bind to the device,
 256:	 * it is not possible to override the driver's id table.
 257:	 */
 258:	static ssize_t bind_store(struct device_driver *drv, const char *buf,
 259:				  size_t count)
 260:	{
 261:		const struct bus_type *bus = bus_get(drv->bus);
 262:		struct device *dev;
 263:		int err = -ENODEV;
 264:	
 265:		dev = bus_find_device_by_name(bus, NULL, buf);
 266:		if (dev && driver_match_device(drv, dev)) {
 267:			err = device_driver_attach(drv, dev);
 268:			if (!err) {
 269:				/* success */
 270:				err = count;
 271:			}
 272:		}
 273:		put_device(dev);
 274:		bus_put(bus);
 275:		return err;
 276:	}
 SourceFile:drivers/base/bus.c]

65/2 2026/08/10 08:27 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 50075
							output: 43
							thoughts: 572
						

Thoughts:
**The Inner Workings of Driver Binding and an Exploitable Vulnerability**

My thought process began with the `driver_match_device` function call, which immediately told me that the device in question *must* have an ID that matches an entry in the driver's ID table. This raised a significant question: how could `syzkaller` have possibly bound the device `0000:00:07.0` to the `thunderbolt` driver if it wasn't already in its ID table? This led me to hypothesize that `syzkaller` must have dynamically added the PCI ID of `0000:00:07.0` to the `thunderbolt` driver's recognized IDs.

My suspicion solidified when I recalled the existence of the `/sys/bus/pci/drivers/thunderbolt/new_id` sysfs file. I realized that this interface allows for the addition of *any* PCI Vendor and Device ID to a driver's acceptable list. This provided the mechanism: `syzkaller` could have written the Vendor and Device ID of `0000:00:07.0` to `new_id`, thereby tricking the `thunderbolt` driver into accepting it.

Following this line of reasoning, the next step would be to write `0000:00:07.0` to the `bind` interface. Once bound, the `thunderbolt` driver would attempt to probe this device. This is where the potential vulnerability emerged. If `0000:00:07.0` possessed a BAR 0 that was smaller than `0x3a000`, the `thunderbolt` driver, upon mapping this BAR, would subsequently attempt to access memory at offset `0x39640`. This access would fall outside the bounds of the allocated BAR, leading to an out-of-bounds (OOB) read or write.

I then began to consider the specifics of `0000:00:07.0` within QEMU. However, I quickly realized that the exact nature of the device was secondary. The critical factors were that it must have a memory-mapped BAR 0 and that this BAR's size needed to be less than `0x3a000`. I also pondered if it strictly had to be a memory BAR. My analysis confirmed that `pcim_iomap_region` handles both memory and I/O BARs. If it were an I/O BAR, `pci_iomap` would utilize `ioport_map`, resulting in a pointer within the `PCI_IOBASE` region. An access to `0x39640` on such a mapped I/O region could potentially still lead to a page fault if the mapped region was indeed small.

However, a crucial detail caught my attention: the `nhi_pci_probe` function contains a check: `if (!nhi_pci_imr_valid(pdev)) return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");`. This indicated that a prerequisite for the vulnerable probing logic was the validity of the firmware image, which I would need to investigate further by examining the `nhi_pci_imr_valid` function.


66/2 2026/08/10 08:27 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_imr_valid]

Results:
map[SourceCode: 148:	static bool nhi_pci_imr_valid(struct pci_dev *pdev)
 149:	{
 150:		u8 val;
 151:	
 152:		if (!device_property_read_u8(&pdev->dev, "IMR_VALID", &val))
 153:			return !!val;
 154:	
 155:		return true;
 156:	}
 SourceFile:drivers/thunderbolt/pci.c]

67/2 2026/08/10 08:27 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 50824
							output: 43
							thoughts: 421
						

Thoughts:
**My Thought Process for Initializing the Thunderbolt Controller**

Okay, so the initial check for the property returning `true` means it's *not* present, which is good – it means we pass that hurdle. My next step is to call `pcim_enable_device(pdev)`. Following that, I need to get the I/O memory mapped region using `pcim_iomap_region(pdev, 0, "thunderbolt")`.

Now, this `pcim_iomap_region` call is critical. It fundamentally relies on the PCI device having a valid BAR 0. If BAR 0 isn't there, or if its size is reported as zero, `pcim_iomap_region` will definitely fail. Therefore, my primary objective becomes finding a PCI device that *does* have a usable BAR 0.

How can I do that? The most straightforward approach is to scan the `/sys/bus/pci/devices/` directory. Within each device's entry, I need to look for a BAR 0 that has a size greater than zero but also less than `0x3a000`. The upper bound of `0x3a000` seems arbitrary at this stage, but it's a constraint I need to adhere to.

To determine the size of BAR 0, I'll examine the `/sys/bus/pci/devices/*/resource` file for each device. I know this file lists the resources for all six BARs, plus the ROM. Each line represents a resource and contains `start`, `end`, and `flags`. A BAR is considered valid and has a calculable size if both `start` and `end` are non-zero. The size itself is then derived as `end - start + 1`.

So, the plan is: iterate through devices, check their BAR 0 `resource` entries, and if I find one meeting the size criteria (greater than 0 and less than `0x3a000`), I've found my candidate device!

But wait, there's a potential complication: what if the device I want to use is already claimed by another driver? I can't just barge in. I need to proactively handle this. My solution is to first *unbind* the device from its current driver. This is done by writing the device's name to `/sys/bus/pci/devices/<dev>/driver/unbind`.

Once it's unbound, I need to register its PCI ID with the Thunderbolt driver. I'll do this by adding its ID to the `thunderbolt/new_id` file. Finally, I'll *bind* it to the `thunderbolt` driver itself.

Before I proceed, I should quickly check if there are any other crucial checks happening in `nhi_pci_probe` that might impact this process. I see `nhi_pci_check_quirks(nhi_pci)` and `nhi_pci_check_iommu(nhi_pci)`. I'll need to dive into `nhi_pci_check_quirks` next to see if there are any other device-specific behaviors or requirements I need to account for.


68/2 2026/08/10 08:27 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_check_quirks]

Results:
map[SourceCode:  41:	static void nhi_pci_check_quirks(struct tb_nhi_pci *nhi_pci)
  42:	{
  43:		struct tb_nhi *nhi = &nhi_pci->nhi;
  44:		struct pci_dev *pdev = to_pci_dev(nhi->dev);
  45:	
  46:		if (pdev->vendor == PCI_VENDOR_ID_INTEL) {
  47:			/*
  48:			 * Intel hardware supports auto clear of the interrupt
  49:			 * status register right after interrupt is being
  50:			 * issued.
  51:			 */
  52:			nhi->quirks |= QUIRK_AUTO_CLEAR_INT;
  53:	
  54:			switch (pdev->device) {
  55:			case PCI_DEVICE_ID_INTEL_FALCON_RIDGE_2C_NHI:
  56:			case PCI_DEVICE_ID_INTEL_FALCON_RIDGE_4C_NHI:
  57:				/*
  58:				 * Falcon Ridge controller needs the end-to-end
  59:				 * flow control workaround to avoid losing Rx
  60:				 * packets when RING_FLAG_E2E is set.
  61:				 */
  62:				nhi->quirks |= QUIRK_E2E;
  63:				break;
  64:			}
  65:		}
  66:	}
 SourceFile:drivers/thunderbolt/pci.c]

69/2 2026/08/10 08:27 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 51686
							output: 42
							thoughts: 3354
						

Thoughts:
**My Thought Process Unraveling the Thunderbolt Driver Crash**

Okay, so I'm looking at this crash and the associated code. The key observation is the use of `0x208` in the `iowrite32` call, which points directly to `REG_RING_INTERRUPT_MASK_CLEAR_BASE`. This address is only used when the `QUIRK_AUTO_CLEAR_INT` flag is *not* set. And `QUIRK_AUTO_CLEAR_INT` is only set if the device's vendor is `PCI_VENDOR_ID_INTEL`.

So, the immediate conclusion I draw is that the `syzkaller` fuzzing harness must have bound a device to the `thunderbolt` driver that is *not* an Intel device. This seems to validate my initial suspicion: `syzkaller` used the `new_id` mechanism to attach an arbitrary non-Intel PCI device to the `thunderbolt` driver. If it had been an Intel device, the code path would have used the address `0x38200` (`REG_RING_INTERRUPT_BASE`) instead of `0x38208`.

But then I pause and reconsider. The crash report mentions `0000:00:07.0`. In a QEMU environment, this specific device ID is often associated with `piix4-ide`, which *is* an Intel device (Vendor ID `8086`). This throws a wrench in my previous deduction. If the device *was* Intel, then `QUIRK_AUTO_CLEAR_INT` *should* have been set. So why did it use `0x38208`?

I go back to `nhi_pci_check_quirks` to re-examine the logic. Could it be that `pdev->vendor` was somehow not reported as Intel, even though the device itself is? Perhaps `syzkaller` bound a *different* device to `thunderbolt`, one that *isn't* Intel. For example, if it bound a `virtio-pci` device (Vendor `0x1af4`), then `QUIRK_AUTO_CLEAR_INT` would indeed not be set, leading to the use of `0x38208`.

However, the critical piece of information is the device mentioned in the bug report: `thunderbolt 0000:00:07.0: timeout resetting host router`. This strongly suggests that `0000:00:07.0` is the device in question. My earlier thought about `piix4-ide` is a red herring if it's not the device being bound. If `0000:00:07.0` is, for instance, a `virtio-9p` or `virtio-rng` device in certain QEMU configurations, then it's not an Intel device, `QUIRK_AUTO_CLEAR_INT` isn't set, and the access to `0x38208` is consistent.

The core of the issue, as I see it, is an out-of-bounds access due to a missing BAR size check. If we bind a non-Intel device with a BAR 0 of a small size, like 4KB, then `0x38208` is definitely out of bounds. But then I remember that `REG_CAPS` at `0x39640` is also accessed during probing. If the BAR size is only 4KB, `0x39640` would *also* be out of bounds. Why didn't that cause a crash first? My prior reasoning suggests that `0x39640` might have been mapped by coincidence due to adjacent `vmalloc` allocations.

This leads me to think about creating a reproducer. Relying on a `vmalloc` coincidence is not ideal for a reliable reproducer. However, if we simply trigger the out-of-bounds access, the *exact* location of the crash (whether it's at `0x39640` in `nhi_probe` or `0x38208` in `nhi_disable_interrupts`) becomes less critical. The root cause – the out-of-bounds access from an insufficient BAR size check – remains the same. Crashing at `0x39640` is perfectly acceptable.

Now, can I engineer a crash specifically at `0x38208` and *not* at `0x39640`? This would require `0x39640` to be *in bounds* and `0x38208` to be *out of bounds*. Given that `0x38208 < 0x39640`, this is impossible. If `0x39640` is mapped by `ioremap` (meaning it's within the BAR's allocated size), then `0x38208` must also be mapped. The only scenario where it crashed at `0x38208` and not `0x39640` is the coincidental mapping of `0x39640`, which, as I noted, is not robust for a reproducer.

Therefore, my strategy for a reproducer is clear:
1.  Identify any PCI device in the system that has a BAR 0 with a size greater than zero but less than `0x39640`. It doesn't strictly matter if it's Intel or not; the `thunderbolt` driver will attempt to `ioremap` this small BAR.
2.  Unbind this device from its current driver.
3.  Use `new_id` to register the device's vendor and device IDs with the `thunderbolt` driver.
4.  Bind the device to the `thunderbolt` driver.
5.  This action should trigger the `thunderbolt` driver's probe routine, which will perform an out-of-bounds memory access (likely at `0x39640` or `0x38208` if `QUIRK_AUTO_CLEAR_INT` isn't set), leading to a kernel panic.

I've also considered edge cases:
*   `nhi->iobase` being the start of the BAR is handled by `pcim_iomap_region`.
*   64-bit BARs are also correctly handled by `pcim_iomap_region`.
*   To ensure stability, I should probably avoid unbinding critical system devices like host or ISA bridges, so I'll filter by PCI class code.

The plan is to write a small C program that iterates through `/sys/bus/pci/devices`, finds a suitable candidate device based on BAR 0 size, and then performs the unbind/new\_id/bind sequence. It's crucial that the `thunderbolt` driver is loaded, which is generally assumed in these scenarios, but I might add a `modprobe` call for robustness.


70/2 2026/08/10 08:28 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:pci_nhi_default_ops]

Results:
map[SourceCode: 254:	static const struct tb_nhi_ops pci_nhi_default_ops = {
 255:		.pre_nvm_auth = nhi_pci_start_dma_port,
 256:		.post_nvm_auth = nhi_pci_complete_dma_port,
 257:		.request_ring_irq = nhi_pci_ring_request_msix,
 258:		.release_ring_irq = nhi_pci_ring_release_msix,
 259:		.shutdown = nhi_pci_shutdown,
 260:		.is_present = nhi_pci_is_present,
 261:		.init_interrupts = nhi_pci_init_msi,
 262:	};
 SourceFile:drivers/thunderbolt/pci.c]

71/2 2026/08/10 08:28 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 55298
							output: 23
							thoughts: 2413
						

Thoughts:
**My Thoughts on Exploiting the Thunderbolt Driver Vulnerability**

I've been dissecting this potential vulnerability in the Thunderbolt driver, and I think I've got a solid grasp on how to trigger it. The core issue seems to stem from how the `nhi_probe` function handles device initialization, specifically when it attempts to access hardware registers via memory-mapped I/O (MMIO) before verifying the size of the Address Translation Lookaside Buffer (ATLB) or BAR.

Here's my thought process:

First, I looked at the `nhi_probe` function and noted the initial check: `if (!nhi->ops->init_interrupts)`. This is immediately satisfied because the `pci_nhi_default_ops` structure provides `init_interrupts = nhi_pci_init_msi`. So, that safety net doesn't catch this.

The real problem appears when the code tries to read from `nhi->iobase + REG_CAPS`. `REG_CAPS` is at offset `0x39640`. The critical insight here is that if the device's BAR 0 (the primary mapping for PCI devices) is smaller than `0x39640`, this read will be an out-of-bounds (OOB) access. If this initial OOB access doesn't cause an immediate crash (perhaps due to memory aliasing or other coincidences), the code proceeds to `nhi_reset`.

`nhi_reset` reads `REG_CAPS` *again*, and then it might write to `REG_RESET` which is at `0x39898`. Following that, `nhi_disable_interrupts` writes to either `0x38208` or `0x38200` (depending on the vendor). Any of these subsequent accesses, if they fall beyond the allocated BAR 0, will trigger the dreaded page fault.

Now, the challenge is how to get a device with a small BAR 0 into a state where the `thunderbolt` driver tries to probe it. The key is in `nhi_pci_probe` itself. It calls `pcim_enable_device(pdev)` and then `pcim_iomap_region(pdev, 0, "thunderbolt")`.

`pcim_iomap_region` is where our opportunity lies. It will fail if BAR 0 is already claimed by another driver. The trick is that we can *unbind* the currently bound driver first. This is where the syzkaller environment becomes useful. In a typical syzkaller VM, there are usually several PCI devices (like network cards, audio controllers, or USB controllers) that can be unbound and rebound.

I started thinking about common PCI devices and their BAR 0 sizes. For example, the `e1000` network driver often uses a BAR 0 of 128KB (`0x20000`). Crucially, `0x20000` is *less than* `0x39640`. This makes `e1000` a perfect candidate! Similarly, `virtio-pci` devices might have small memory BARs, sometimes as little as 4KB or 256 bytes. So, I'm confident we can find a device with a BAR 0 that's too small.

What if `pcim_iomap_region` fails for other reasons? It could be that the BAR is reserved by the system, perhaps through ACPI. However, PCI BARs are typically not reserved by ACPI for general use; they're usually managed by the PCI subsystem. If `pcim_iomap_region` fails, the probe simply aborts, and we can just try the next device. The expectation is that at least one such device will be available.

I also considered if `nhi_pci_probe` could fail *before* `pcim_iomap_region`. The code checks `nhi_imr_valid(pdev)` and then `pcim_enable_device(pdev)`. `pcim_enable_device` should succeed for a properly functioning device, so this path seems less likely to be the primary failure point for our exploit.

Looking at the C code provided, it implements exactly this strategy: iterate through PCI devices, check their BAR 0 size, and if it's too small, unbind the current driver and attempt to bind the `thunderbolt` driver.

A thought that came up was what happens if the `thunderbolt` driver is already bound to the target device. In this case, the `unbind` operation would just detach it, and the subsequent `bind` would reattach it. This is perfectly acceptable.

Then I considered the `new_id` mechanism. Writing the vendor and device ID to `/sys/bus/pci/drivers/thunderbolt/new_id` is interesting. It's supposed to trigger a bus rescan and automatically bind matching unbound devices. While writing to `bind` explicitly is generally safer, the `new_id` mechanism is powerful. If writing to `new_id` fails because the ID is already there, we ignore it, which is fine. The key is that `new_id` can initiate the binding process without us needing to directly manipulate the `bind` file. However, explicitly writing to `bind` is still a good practice for robustness.

I also considered the case where the `thunderbolt` driver might not be loaded yet. If it's a module, `/sys/bus/pci/drivers/thunderbolt` might not exist. So, a simple `system("modprobe thunderbolt");` at the beginning of the exploit would be necessary to ensure the driver infrastructure is in place.

Finally, I re-examined the bug report: "`thunderbolt 0000:00:07.0: timeout resetting host router`" and "`BUG: unable to handle page fault for address: ffffc90000f70208`" with `RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225`. This is exactly what I predicted: an OOB access during an MMIO write operation.

One last detail: what if BAR 0 is a 64-bit BAR? The `resource` file format should handle that. What if BAR 0 is an *IO* BAR instead of a *memory* BAR? If it's an IO BAR, `pcim_iomap_region` uses `ioport_map`, which returns a mapped address relative to `PIO_OFFSET` (which is `0x10000` on x86). The `ioread32` and `iowrite32` functions, when used with IO ports, operate on 16-bit port numbers. This means that `0x10000 + 0x39640` would be truncated to `0xA640`. The same applies to other OOB accesses. This would read from or write to actual IO ports, which wouldn't cause a page fault, but just return garbage or have no effect. So, it's crucial that BAR 0 is a *memory* BAR for the OOB access to trigger a page fault. The `resource` file format indicates this with the `IORESOURCE_MEM` flag, which I'll need to check for.


72/2 2026/08/10 08:29 tool grepper
0m Args:
map[Expression:#define IORESOURCE_MEM\b]

Results:
map[Output:include/linux/ioport.h=22=struct resource {
--
include/linux/ioport.h-40-#define IORESOURCE_IO		0x00000100	/* PCI/ISA I/O ports */
include/linux/ioport.h:41:#define IORESOURCE_MEM		0x00000200
include/linux/ioport.h-42-#define IORESOURCE_REG		0x00000300	/* Register offsets */
]

73/2 2026/08/10 08:29 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 57857
							output: 40
							thoughts: 1823
						

Thoughts:
**My Thought Process on Reproducing a Thunderbolt Driver Vulnerability**

Here's a breakdown of how I arrived at the solution for reproducing this specific kernel bug. My goal was to create a reliable standalone C program that could trigger the vulnerability by manipulating PCI device bindings.

Initially, I identified that the core of the issue revolves around a PCI device's memory-mapped I/O (MMIO) region, specifically BAR 0, and its size. The `thunderbolt` driver, in its probing and initialization routines, assumes a certain minimum size for this BAR. If the BAR is smaller than expected, it leads to out-of-bounds memory accesses, ultimately causing a kernel crash. My first thought was, "Okay, I need to find a PCI device that *has* BAR 0, and that BAR 0 must be configured as a memory resource." This led me to the `flags & 0x200` check – `0x200` is the `IORESOURCE_MEM` flag, indicating it's a memory region. So, the first concrete step was to add `if (flags & 0x200)` to ensure I'm only looking at memory-mapped BARs.

Then, I started thinking about how to actually trigger the vulnerability. The bug report implies that if a device is bound to the `thunderbolt` driver and its BAR 0 is too small, the kernel will crash. This suggests a strategy: find such a device, unbind it from whatever driver currently controls it, and then bind it to the `thunderbolt` driver. This is where the C code begins to take shape. I'd need to iterate through PCI devices, check their class codes, read their resource information (start, end, flags), and if they meet my criteria (memory BAR 0, small size), I'd attempt to unbind and rebind.

The initial C code was a good starting point, but it had potential issues. For instance, what if the device is *already* bound to `thunderbolt`? My initial thought process was that unbinding and then rebinding wouldn't hurt; it would just re-establish the existing binding. I also considered what happens if writing to `/sys/bus/pci/drivers/thunderbolt/new_id` fails. My reasoning was that if `new_id` fails, it's likely because the ID is already registered, and the subsequent `bind` operation should still succeed.

However, as I delved deeper, I realized a critical flaw in the binding/unbinding logic: if `new_id` fails *not* because the ID is already there, but for some other reason, then the subsequent `bind` *would* fail because the driver wouldn't recognize the device's vendor/device ID. This led to a more refined understanding: `new_id` should only fail if the ID is *already* registered. If it's already registered, then the subsequent `bind` should succeed.

A much more significant concern arose: system stability. What if I unbind a critical device, like the disk controller, before the bug is triggered? The system could hang or crash prematurely, making it difficult to reliably trigger the intended kernel bug. I specifically thought about disk controllers like AHCI and NVMe. AHCI's BAR 0 is often an I/O port, which my `flags & 0x200` check would correctly skip. NVMe, however, commonly uses BAR 0 as a memory BAR, and if the root filesystem is on NVMe, unbinding it would certainly cause a hang.

The initial approach of "just try to unbind everything we can and hope for the best" is valid in a fuzzing environment like syzkaller, where a crash *is* the desired outcome. But for a more reliable reproducer, I needed to mitigate the risk of hitting the root disk. This led me to refine the device selection criteria. I reasoned that mass storage devices (class `0x01xxxx`) and network controllers (class `0x02xxxx`) are prime candidates for being critical system components. Therefore, I decided to explicitly skip these. Specifically, I added a check to skip devices with a base class of `0x01` (Mass Storage). This significantly increased the safety of the reproducer, as it would avoid unbinding the root filesystem device.

My final refinement of the class check became: `if (base_class == 0x06 || base_class == 0x01) continue;`. This skips Host/ISA bridges (class `0x06`) which are generally not the kind of device we're looking for here, and crucially, Mass Storage (class `0x01`), making the reproducer much safer.

Finally, I re-examined the bug mechanism itself. The sequence of events: `nhi_pci_probe` mapping BAR 0, `nhi_probe` accessing `REG_CAPS` at `0x39640`, and `nhi_disable_interrupts` accessing an even further out-of-bounds address, all without proper size checks. This confirmed that the core of the vulnerability lies in the driver's assumption about the BAR size. The fix, therefore, would be a straightforward size check in the driver itself. This solidifies my confidence in the reproducer's strategy: find a device with a memory BAR 0 smaller than `0x39640` and force the `thunderbolt` driver to use it.

With this refined understanding and robust safety checks in place, I felt confident in the approach and the resulting C code.


74/2 2026/08/10 08:29 tool codeexpert
7m Args:
map[Question:Is there any other register accessed by thunderbolt nhi driver that has an offset larger than 0x39640?]

Results:
map[Answer:Yes, there are several other registers accessed by the thunderbolt NHI (Native Host Interface) driver that have offsets larger than `0x39640` (which is `REG_CAPS`). 

These registers are defined in `drivers/thunderbolt/nhi_regs.h` and accessed via the NHI MMIO base pointer (`nhi->iobase`) in `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/icm.c`:

1. **`REG_DMA_MISC`** (Offset: **`0x39864`**)
   - **Description:** Used to configure DMA miscellaneous settings, such as enabling or disabling automatic clearing of interrupt status bits (`REG_DMA_MISC_INT_AUTO_CLEAR` / `REG_DMA_MISC_DISABLE_AUTO_CLEAR`).
   - **Accessed in:** `ring_interrupt_active()` in `drivers/thunderbolt/nhi.c`.

2. **`REG_RESET`** (Offset: **`0x39898`**)
   - **Description:** Used to trigger and poll a host router reset (`REG_RESET_HRR`) for v2 and later routers.
   - **Accessed in:** `nhi_reset()` in `drivers/thunderbolt/nhi.c`.

3. **`REG_INMAIL_DATA`** (Offset: **`0x39900`**)
   - **Description:** Used to write data associated with an incoming mailbox command to the firmware.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

4. **`REG_INMAIL_CMD`** (Offset: **`0x39904`**)
   - **Description:** Used to send incoming mailbox commands to the firmware and check for completion or errors.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

5. **`REG_OUTMAIL_CMD`** (Offset: **`0x3990c`**)
   - **Description:** Used to read the current firmware operation mode from the outgoing mailbox command register.
   - **Accessed in:** `nhi_mailbox_mode()` in `drivers/thunderbolt/nhi.c`.

6. **`REG_FW_STS`** (Offset: **`0x39944`**)
   - **Description:** Used to check the firmware status, such as whether the ICM (Internal Connection Manager) firmware is running, NVM authentication is done, or to request a CIO reset.
   - **Accessed in:** Several functions in `drivers/thunderbolt/icm.c` (including `icm_firmware_running()`, `icm_ar_get_mode()`, `icm_tgl_is_supported()`, `icm_firmware_reset()`, and `icm_firmware_start()`).

All other registers accessed by the driver (such as ring bases, ring options, and interrupt/throttling registers) have offsets below `0x39640`.]

75/3 2026/08/10 08:29 agent codeexpert
7m Model:
good-balanced

Results:
map[Answer:Yes, there are several other registers accessed by the thunderbolt NHI (Native Host Interface) driver that have offsets larger than `0x39640` (which is `REG_CAPS`). 

These registers are defined in `drivers/thunderbolt/nhi_regs.h` and accessed via the NHI MMIO base pointer (`nhi->iobase`) in `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/icm.c`:

1. **`REG_DMA_MISC`** (Offset: **`0x39864`**)
   - **Description:** Used to configure DMA miscellaneous settings, such as enabling or disabling automatic clearing of interrupt status bits (`REG_DMA_MISC_INT_AUTO_CLEAR` / `REG_DMA_MISC_DISABLE_AUTO_CLEAR`).
   - **Accessed in:** `ring_interrupt_active()` in `drivers/thunderbolt/nhi.c`.

2. **`REG_RESET`** (Offset: **`0x39898`**)
   - **Description:** Used to trigger and poll a host router reset (`REG_RESET_HRR`) for v2 and later routers.
   - **Accessed in:** `nhi_reset()` in `drivers/thunderbolt/nhi.c`.

3. **`REG_INMAIL_DATA`** (Offset: **`0x39900`**)
   - **Description:** Used to write data associated with an incoming mailbox command to the firmware.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

4. **`REG_INMAIL_CMD`** (Offset: **`0x39904`**)
   - **Description:** Used to send incoming mailbox commands to the firmware and check for completion or errors.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

5. **`REG_OUTMAIL_CMD`** (Offset: **`0x3990c`**)
   - **Description:** Used to read the current firmware operation mode from the outgoing mailbox command register.
   - **Accessed in:** `nhi_mailbox_mode()` in `drivers/thunderbolt/nhi.c`.

6. **`REG_FW_STS`** (Offset: **`0x39944`**)
   - **Description:** Used to check the firmware status, such as whether the ICM (Internal Connection Manager) firmware is running, NVM authentication is done, or to request a CIO reset.
   - **Accessed in:** Several functions in `drivers/thunderbolt/icm.c` (including `icm_firmware_running()`, `icm_ar_get_mode()`, `icm_tgl_is_supported()`, `icm_firmware_reset()`, and `icm_firmware_start()`).

All other registers accessed by the driver (such as ring bases, ring options, and interrupt/throttling registers) have offsets below `0x39640`.]

Instruction:
You are a capable Linux kernel developer tasked with researching complex questions
about kernel source code. You will be given a concrete question, and need to provide
a concrete answer.
Use tools extensively while researching the question. Don't make assumptions,
or rely on your previous knowledge about the kernel source code, use available tools
to access the actual source code.
Use all available sources of information:
 - kernel source code
 - documentation in the Documentation dir in the source tree

Do not guess file names or file paths and attempt to read them without
verifying their existence first using content search or directory listing tools.
If a file, symbol, or directory is not found via content search (grepper) or
directory listing (codesearch-dir-index), treat it as completely absent.
Do not attempt to guess alternative names, extensions, or directories.

Tool Selection Guidelines:
1. For C functions, structs, and variables: Prefer codesearch-definition-source
   or codesearch-struct-layout FIRST to retrieve clean, exact definitions
   without line-number guessing.
2. If symbol lookup fails (e.g., preprocessor macros, macro-generated code, or
   disabled #ifdef branches), fall back to read-file or grepper.
3. For file headers, #include directives, preprocessor macro definitions, and
   non-C files (Kconfig, Makefiles, docs): Use read-file or grepper directly.

Prefer calling several tools at the same time to save round-trips.


Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.

Prompt:
Is there any other register accessed by thunderbolt nhi driver that has an offset larger than 0x39640?

76/4 2026/08/10 08:29 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 2245
							output: 22
							thoughts: 109
						

Thoughts:
**My Thought Process**

Alright, so the user wants to know if the Thunderbolt NHI driver accesses any registers beyond offset `0x39640`. This is a pretty specific technical question, and to answer it, I need to dive into the kernel source code.

First things first, I need to pinpoint *where* in the kernel the Thunderbolt NHI driver actually lives. The most efficient way to do this, given my expertise with the kernel's structure, is to start by searching for keywords like "thunderbolt" or "nhi" within the source tree. I'll leverage my tools – `grepper` or `codesearch-dir-index` are perfect for this kind of targeted search. My intuition tells me the Thunderbolt-related code is likely to be under a dedicated directory, so I'll specifically focus my search within `drivers/thunderbolt/`. This is where I expect to find the relevant driver files. Once I've located those files, I can then proceed to analyze their register access patterns to determine the maximum offset used.


77/4 2026/08/10 08:29 tool codesearch-dir-index
0m Args:
map[Dir:drivers/thunderbolt]

Results:
map[Files:[acpi.c cap.c clx.c configfs.c ctl.c ctl.h debugfs.c dma_port.c dma_port.h dma_test.c domain.c eeprom.c icm.c lc.c nhi.c nhi.h nhi_regs.h nvm.c path.c pci.c property.c quirks.c retimer.c sb_regs.h stream.c switch.c tb.c tb.h tb_msgs.h tb_regs.h test.c tmu.c trace.h tunnel.c tunnel.h usb4.c usb4_port.c xdomain.c] Subdirs:<nil>]

78/4 2026/08/10 08:29 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 2533
							output: 29
							thoughts: 83
						

Thoughts:
**My Thought Process on Register Investigation**

Ah, excellent! I've identified a set of relevant files: `drivers/thunderbolt/nhi.c`, `drivers/thunderbolt/nhi.h`, `drivers/thunderbolt/nhi_regs.h`, and `drivers/thunderbolt/tb_regs.h`, among others. My immediate next step is to pinpoint the exact register associated with the value `0x39640`. To do this, I'll perform a targeted search for `0x39640` specifically within the `drivers/thunderbolt/` directory. This will help me understand its context and function within the Thunderbolt driver subsystem.


79/4 2026/08/10 08:29 tool grepper
0m Args:
map[Expression:39640 PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-113-/* The last 11 bits contain the number of hops supported by the NHI port. */
drivers/thunderbolt/nhi_regs.h:114:#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h-115-#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
]

80/4 2026/08/10 08:29 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 2768
							output: 38
							thoughts: 140
						

Thoughts:
**My Thought Process on Register Offsets**

My initial thought is drawn to the specific value `0x39640`, which I recognize as the definition for `REG_CAPS` within the `drivers/thunderbolt/nhi_regs.h` header file. This immediate recognition prompts me to explore the broader context of register definitions within that same file. My primary objective is to ascertain the full spectrum of registers defined, specifically looking for any other register addresses that might exceed this `0x39640` offset. To achieve this, my immediate action is to delve into `drivers/thunderbolt/nhi_regs.h`. I'm considering two approaches: either a full read of the file to grasp its entirety, or a targeted search for all register offsets to efficiently identify any values larger than the one that initially caught my eye. For the practical execution of this, I plan to use a `read-file` command to access the content, and I'm curious to gauge the file's length as part of this initial reconnaissance.


81/4 2026/08/10 08:29 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:1 LineCount:100]

Results:
map[Contents:   1:	/* SPDX-License-Identifier: GPL-2.0 */
   2:	/*
   3:	 * Thunderbolt driver - NHI registers
   4:	 *
   5:	 * Copyright (c) 2014 Andreas Noever <andreas.noever@gmail.com>
   6:	 * Copyright (C) 2018, Intel Corporation
   7:	 */
   8:	
   9:	#ifndef NHI_REGS_H_
  10:	#define NHI_REGS_H_
  11:	
  12:	#include <linux/types.h>
  13:	
  14:	enum ring_flags {
  15:		RING_FLAG_ISOCH_ENABLE = 1 << 27, /* TX only? */
  16:		RING_FLAG_E2E_FLOW_CONTROL = 1 << 28,
  17:		RING_FLAG_PCI_NO_SNOOP = 1 << 29,
  18:		RING_FLAG_RAW = 1 << 30, /* ignore EOF/SOF mask, include checksum */
  19:		RING_FLAG_ENABLE = 1 << 31,
  20:	};
  21:	
  22:	/**
  23:	 * struct ring_desc - TX/RX ring entry
  24:	 * @phys: DMA mapped address of the frame
  25:	 * @length: Size of the ring
  26:	 * @eof: End of frame protocol defined field
  27:	 * @sof: Start of frame protocol defined field
  28:	 * @flags: Ring descriptor flags
  29:	 * @time: Fill with zero
  30:	 *
  31:	 * For TX set length/eof/sof.
  32:	 * For RX length/eof/sof are set by the NHI.
  33:	 */
  34:	struct ring_desc {
  35:		u64 phys;
  36:		u32 length:12;
  37:		u32 eof:4;
  38:		u32 sof:4;
  39:		enum ring_desc_flags flags:12;
  40:		u32 time; /* write zero */
  41:	} __packed;
  42:	
  43:	/* NHI registers in bar 0 */
  44:	
  45:	/*
  46:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  47:	 * 00: physical pointer to an array of struct ring_desc
  48:	 * 08: ring tail (set by NHI)
  49:	 * 10: ring head (index of first non posted descriptor)
  50:	 * 12: descriptor count
  51:	 */
  52:	#define REG_TX_RING_BASE	0x00000
  53:	
  54:	/*
  55:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  56:	 * 00: physical pointer to an array of struct ring_desc
  57:	 * 08: ring head (index of first not posted descriptor)
  58:	 * 10: ring tail (set by NHI)
  59:	 * 12: descriptor count
  60:	 * 14: max frame sizes (anything larger than 0x100 has no effect)
  61:	 */
  62:	#define REG_RX_RING_BASE	0x08000
  63:	
  64:	/*
  65:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  66:	 * 00: enum_ring_flags
  67:	 * 04: isoch time stamp ?? (write 0)
  68:	 * ..: unknown
  69:	 */
  70:	#define REG_TX_OPTIONS_BASE	0x19800
  71:	
  72:	/*
  73:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  74:	 * 00: enum ring_flags
  75:	 *     If RING_FLAG_E2E_FLOW_CONTROL is set then bits 13-23 must be set to
  76:	 *     the corresponding TX hop id.
  77:	 * 04: EOF/SOF mask (ignored for RING_FLAG_RAW rings)
  78:	 * ..: unknown
  79:	 */
  80:	#define REG_RX_OPTIONS_BASE	0x29800
  81:	#define REG_RX_OPTIONS_E2E_HOP_MASK	GENMASK(22, 12)
  82:	#define REG_RX_OPTIONS_E2E_HOP_SHIFT	12
  83:	
  84:	/*
  85:	 * three bitfields: tx, rx, rx overflow
  86:	 * Every bitfield contains one bit for every hop (REG_CAPS).
  87:	 * New interrupts are fired only after ALL registers have been
  88:	 * read (even those containing only disabled rings).
  89:	 */
  90:	#define REG_RING_NOTIFY_BASE	0x37800
  91:	#define RING_NOTIFY_REG_COUNT(nhi) ((31 + 3 * nhi->hop_count) / 32)
  92:	#define REG_RING_INT_CLEAR	0x37808
  93:	
  94:	/*
  95:	 * two bitfields: rx, tx
  96:	 * Both bitfields contains one bit for every hop (REG_CAPS). To
  97:	 * enable/disable interrupts set/clear the corresponding bits.
  98:	 */
  99:	#define REG_RING_INTERRUPT_BASE	0x38200
 100:	#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
]

82/4 2026/08/10 08:29 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 4507
							output: 40
							thoughts: 20
						

Thoughts:
**My Journey Through `drivers/thunderbolt/nhi_regs.h`**

Alright, the immediate impulse is to dive into the rest of this `drivers/thunderbolt/nhi_regs.h` file. I'm assuming this is the logical next step, given my current focus on the Thunderbolt driver implementation. My objective here is to gain a comprehensive understanding of the low-level hardware interface, specifically the registers that govern the Network Host Interface (NHI).

I anticipate this header file will be densely packed with definitions – macros, structures, and constants – that abstract away the raw memory addresses and bit manipulation required to interact with the Thunderbolt NHI controller. My goal is to map these definitions back to the hardware specifications, or at least the documentation I have for the NHI. This isn't just about memorizing register offsets; it's about understanding *what* each register controls and *how* it affects the NHI's behavior.

I'll be looking for key areas of functionality. For instance, I expect to find registers related to:

*   **Control and Status:** How do I enable/disable the NHI, reset it, and query its current operational state? This will likely involve flags for interrupts, error conditions, and general operational modes.
*   **Configuration:** What parameters can I configure for the NHI? This could include things like bus widths, clocking, power management states, and any protocol-specific settings.
*   **Data Transfer:** While the actual data paths might be handled elsewhere, I expect to see registers that manage DMA operations, buffer descriptors, or transmit/receive queues.
*   **Interrupt Handling:** How does the NHI signal events to the system? I'll be scrutinizing interrupt masks, status bits, and potentially vector definitions.
*   **Device Discovery and Management:** Given Thunderbolt's hot-plugging nature, there might be registers involved in detecting connected devices, their capabilities, and managing their enumeration.

As I parse these definitions, I'll be actively trying to connect the dots. A specific macro might represent a bit within a larger status register. A structure might group related control fields for a particular NHI function. I'll be thinking about how these low-level primitives will be used by the higher-level driver logic – how will functions like `nhc_init()`, `nhc_enable_port()`, or `nhc_send_packet()` translate into sequences of reads and writes to these very registers?

I'll also be keeping an eye out for any vendor-specific extensions or proprietary mechanisms. Thunderbolt, like any complex interconnect, can have nuances that are not fully captured by the general specifications. Understanding these details will be crucial for robust and performant driver development.

Essentially, this file is the hardware's programming manual, expressed in C. My task is to read it, internalize it, and use it as the bedrock for building the software that makes it all work. I'm ready to commit to this exploration and emerge with a clearer picture of the NHI's inner workings.


83/4 2026/08/10 08:30 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:101 LineCount:100]

Results:
map[Contents: 101:	
 102:	#define REG_RING_INTERRUPT_MASK_CLEAR_BASE	0x38208
 103:	
 104:	#define REG_INT_THROTTLING_RATE			0x38c00
 105:	#define REG_INT_THROTTLING_RATE_INTERVAL_MASK	GENMASK(15, 0)
 106:	
 107:	/* Interrupt Vector Allocation */
 108:	#define REG_INT_VEC_ALLOC_BASE	0x38c40
 109:	#define REG_INT_VEC_ALLOC_BITS	4
 110:	#define REG_INT_VEC_ALLOC_MASK	GENMASK(3, 0)
 111:	#define REG_INT_VEC_ALLOC_REGS	(32 / REG_INT_VEC_ALLOC_BITS)
 112:	
 113:	/* The last 11 bits contain the number of hops supported by the NHI port. */
 114:	#define REG_CAPS			0x39640
 115:	#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
 116:	#define REG_CAPS_VERSION_2		0x40
 117:	
 118:	#define REG_DMA_MISC			0x39864
 119:	#define REG_DMA_MISC_INT_AUTO_CLEAR     BIT(2)
 120:	#define REG_DMA_MISC_DISABLE_AUTO_CLEAR	BIT(17)
 121:	
 122:	#define REG_RESET			0x39898
 123:	#define REG_RESET_HRR			BIT(0)
 124:	
 125:	#define REG_INMAIL_DATA			0x39900
 126:	
 127:	#define REG_INMAIL_CMD			0x39904
 128:	#define REG_INMAIL_CMD_MASK		GENMASK(7, 0)
 129:	#define REG_INMAIL_ERROR		BIT(30)
 130:	#define REG_INMAIL_OP_REQUEST		BIT(31)
 131:	
 132:	#define REG_OUTMAIL_CMD			0x3990c
 133:	#define REG_OUTMAIL_CMD_OPMODE_SHIFT	8
 134:	#define REG_OUTMAIL_CMD_OPMODE_MASK	GENMASK(11, 8)
 135:	
 136:	#define REG_FW_STS			0x39944
 137:	#define REG_FW_STS_NVM_AUTH_DONE	BIT(31)
 138:	#define REG_FW_STS_CIO_RESET_REQ	BIT(30)
 139:	#define REG_FW_STS_ICM_EN_CPU		BIT(2)
 140:	#define REG_FW_STS_ICM_EN_INVERT	BIT(1)
 141:	#define REG_FW_STS_ICM_EN		BIT(0)
 142:	
 143:	/* ICL NHI VSEC registers */
 144:	
 145:	/* FW ready */
 146:	#define VS_CAP_9			0xc8
 147:	#define VS_CAP_9_FW_READY		BIT(31)
 148:	/* UUID */
 149:	#define VS_CAP_10			0xcc
 150:	#define VS_CAP_11			0xd0
 151:	/* LTR */
 152:	#define VS_CAP_15			0xe0
 153:	#define VS_CAP_16			0xe4
 154:	/* TBT2PCIe */
 155:	#define VS_CAP_18			0xec
 156:	#define VS_CAP_18_DONE			BIT(0)
 157:	/* PCIe2TBT */
 158:	#define VS_CAP_19			0xf0
 159:	#define VS_CAP_19_VALID			BIT(0)
 160:	#define VS_CAP_19_CMD_SHIFT		1
 161:	#define VS_CAP_19_CMD_MASK		GENMASK(7, 1)
 162:	/* Force power */
 163:	#define VS_CAP_22			0xfc
 164:	#define VS_CAP_22_FORCE_POWER		BIT(1)
 165:	#define VS_CAP_22_DMA_DELAY_MASK	GENMASK(31, 24)
 166:	#define VS_CAP_22_DMA_DELAY_SHIFT	24
 167:	
 168:	/**
 169:	 * enum icl_lc_mailbox_cmd - ICL specific LC mailbox commands
 170:	 * @ICL_LC_GO2SX: Ask LC to enter Sx without wake
 171:	 * @ICL_LC_GO2SX_NO_WAKE: Ask LC to enter Sx with wake
 172:	 * @ICL_LC_PREPARE_FOR_RESET: Prepare LC for reset
 173:	 */
 174:	enum icl_lc_mailbox_cmd {
 175:		ICL_LC_GO2SX = 0x02,
 176:		ICL_LC_GO2SX_NO_WAKE = 0x03,
 177:		ICL_LC_PREPARE_FOR_RESET = 0x21,
 178:	};
 179:	
 180:	#endif
]

84/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 6097
							output: 38
							thoughts: 367
						

Thoughts:
**My Thought Process on Thunderbolt NHI Register Exploration**

Okay, so my initial dive into the Thunderbolt driver code, specifically `drivers/thunderbolt/nhi_regs.h`, has revealed something interesting. I noticed several register definitions that have offsets *larger* than `0x39640`, which I recognize as the offset for `REG_CAPS`. The registers I've identified with these higher offsets are: `REG_DMA_MISC` at `0x39864`, `REG_RESET` at `0x39898`, `REG_INMAIL_DATA` at `0x39900`, `REG_INMAIL_CMD` at `0x39904`, `REG_OUTMAIL_CMD` at `0x3990c`, and `REG_FW_STS` at `0x39944`.

This immediately prompts me to ask: are there *any other* registers, defined in this file or perhaps elsewhere, that also fall into this higher offset range? And critically, where are these registers being *used*? I need to understand the context of their access.

So, my next logical step is to broaden my search. I'm going to look for any other register definitions within `drivers/thunderbolt/` that have offsets similar to these higher values, perhaps by searching for patterns like `0x39` or even just `0x3` to cast a wider net.

But before I go too deep into register definitions, I should solidify my understanding of the core component I'm examining. What exactly *is* the NHI driver? I quickly check and confirm that the NHI driver's implementation is primarily found in files like `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/nhi.h`, and likely others within that directory.

With that in mind, my investigation now needs to focus on how these registers are actually interacted with. I'll be looking through all the files within the `drivers/thunderbolt/` directory to find any instances where registers are being read from or written to. My primary targets for this search will be common I/O functions like `ioread`, `iowrite`, `readl`, and `writel`. I'm also keeping an eye out for any references to `tb_ring` or direct mentions of `nhi` registers, as these are likely indicators of direct hardware interaction by the driver. This comprehensive grep will help me pinpoint exactly which parts of the driver are touching these higher-offset registers and in what manner.


85/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:(readl|writel|ioread|iowrite) PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/icm.c=375=static bool icm_firmware_running(const struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-378-
drivers/thunderbolt/icm.c:379:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-380-	return !!(val & REG_FW_STS_ICM_EN);
--
drivers/thunderbolt/icm.c=1509=static int icm_ar_get_mode(struct tb *tb)
--
drivers/thunderbolt/icm.c-1515-	do {
drivers/thunderbolt/icm.c:1516:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1517-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1719=static bool icm_tgl_is_supported(struct tb *tb)
--
drivers/thunderbolt/icm.c-1725-
drivers/thunderbolt/icm.c:1726:		val = ioread32(tb->nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1727-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1837=static int icm_firmware_reset(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1845-	/* Put ARC to wait for CIO reset event to happen */
drivers/thunderbolt/icm.c:1846:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1847-	val |= REG_FW_STS_CIO_RESET_REQ;
drivers/thunderbolt/icm.c:1848:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1849-
drivers/thunderbolt/icm.c-1850-	/* Re-start ARC */
drivers/thunderbolt/icm.c:1851:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1852-	val |= REG_FW_STS_ICM_EN_INVERT;
drivers/thunderbolt/icm.c-1853-	val |= REG_FW_STS_ICM_EN_CPU;
drivers/thunderbolt/icm.c:1854:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1855-
--
drivers/thunderbolt/icm.c=1860=static int icm_firmware_start(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1878-		/* Check that the ICM firmware is running */
drivers/thunderbolt/icm.c:1879:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1880-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/nhi.c=51=static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
--
drivers/thunderbolt/nhi.c-55-
drivers/thunderbolt/nhi.c:56:		val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
drivers/thunderbolt/nhi.c:57:		iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
drivers/thunderbolt/nhi.c-58-	} else {
drivers/thunderbolt/nhi.c:59:		iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
drivers/thunderbolt/nhi.c-60-	}
--
drivers/thunderbolt/nhi.c=63=static void nhi_clear_interrupt(struct tb_nhi *nhi, int ring)
--
drivers/thunderbolt/nhi.c-65-	if (nhi->quirks & QUIRK_AUTO_CLEAR_INT)
drivers/thunderbolt/nhi.c:66:		ioread32(nhi->iobase + REG_RING_NOTIFY_BASE + ring);
drivers/thunderbolt/nhi.c-67-	else
drivers/thunderbolt/nhi.c:68:		iowrite32(~0, nhi->iobase + REG_RING_INT_CLEAR + ring);
drivers/thunderbolt/nhi.c-69-}
--
drivers/thunderbolt/nhi.c=76=static void ring_interrupt_active(struct tb_ring *ring, bool active)
--
drivers/thunderbolt/nhi.c-105-		 */
drivers/thunderbolt/nhi.c:106:		misc = ioread32(ring->nhi->iobase + REG_DMA_MISC);
drivers/thunderbolt/nhi.c-107-		if (ring->nhi->quirks & QUIRK_AUTO_CLEAR_INT)
--
drivers/thunderbolt/nhi.c-111-		if (!(misc & auto_clear_bit))
drivers/thunderbolt/nhi.c:112:			iowrite32(misc | auto_clear_bit,
drivers/thunderbolt/nhi.c-113-				  ring->nhi->iobase + REG_DMA_MISC);
--
drivers/thunderbolt/nhi.c-117-		shift = index % REG_INT_VEC_ALLOC_REGS * REG_INT_VEC_ALLOC_BITS;
drivers/thunderbolt/nhi.c:118:		ivr = ioread32(ivr_base + step);
drivers/thunderbolt/nhi.c-119-		ivr &= ~(REG_INT_VEC_ALLOC_MASK << shift);
--
drivers/thunderbolt/nhi.c-121-			ivr |= ring->vector << shift;
drivers/thunderbolt/nhi.c:122:		iowrite32(ivr, ivr_base + step);
drivers/thunderbolt/nhi.c-123-
--
drivers/thunderbolt/nhi.c-126-		itr &= REG_INT_THROTTLING_RATE_INTERVAL_MASK;
drivers/thunderbolt/nhi.c:127:		iowrite32(itr, ring->nhi->iobase + REG_INT_THROTTLING_RATE +
drivers/thunderbolt/nhi.c-128-			  ring->vector * 4);
--
drivers/thunderbolt/nhi.c-130-
drivers/thunderbolt/nhi.c:131:	old = ioread32(ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-132-	if (active)
--
drivers/thunderbolt/nhi.c-146-	if (active)
drivers/thunderbolt/nhi.c:147:		iowrite32(new, ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-148-	else
--
drivers/thunderbolt/nhi.c=179=static void __iomem *ring_options_base(struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-186-
drivers/thunderbolt/nhi.c:187:static void ring_iowrite_cons(struct tb_ring *ring, u16 cons)
drivers/thunderbolt/nhi.c-188-{
--
drivers/thunderbolt/nhi.c-190-	 * The other 16-bits in the register is read-only and writes to it
drivers/thunderbolt/nhi.c:191:	 * are ignored by the hardware so we can save one ioread32() by
drivers/thunderbolt/nhi.c-192-	 * filling the read-only bits with zeroes.
drivers/thunderbolt/nhi.c-193-	 */
drivers/thunderbolt/nhi.c:194:	iowrite32(cons, ring_desc_base(ring) + 8);
drivers/thunderbolt/nhi.c-195-}
drivers/thunderbolt/nhi.c-196-
drivers/thunderbolt/nhi.c:197:static void ring_iowrite_prod(struct tb_ring *ring, u16 prod)
drivers/thunderbolt/nhi.c-198-{
drivers/thunderbolt/nhi.c:199:	/* See ring_iowrite_cons() above for explanation */
drivers/thunderbolt/nhi.c:200:	iowrite32(prod << 16, ring_desc_base(ring) + 8);
drivers/thunderbolt/nhi.c-201-}
drivers/thunderbolt/nhi.c-202-
drivers/thunderbolt/nhi.c:203:static void ring_iowrite32desc(struct tb_ring *ring, u32 value, u32 offset)
drivers/thunderbolt/nhi.c-204-{
drivers/thunderbolt/nhi.c:205:	iowrite32(value, ring_desc_base(ring) + offset);
drivers/thunderbolt/nhi.c-206-}
drivers/thunderbolt/nhi.c-207-
drivers/thunderbolt/nhi.c:208:static void ring_iowrite64desc(struct tb_ring *ring, u64 value, u32 offset)
drivers/thunderbolt/nhi.c-209-{
drivers/thunderbolt/nhi.c:210:	iowrite32(value, ring_desc_base(ring) + offset);
drivers/thunderbolt/nhi.c:211:	iowrite32(value >> 32, ring_desc_base(ring) + offset + 4);
drivers/thunderbolt/nhi.c-212-}
drivers/thunderbolt/nhi.c-213-
drivers/thunderbolt/nhi.c:214:static void ring_iowrite32options(struct tb_ring *ring, u32 value, u32 offset)
drivers/thunderbolt/nhi.c-215-{
drivers/thunderbolt/nhi.c:216:	iowrite32(value, ring_options_base(ring) + offset);
drivers/thunderbolt/nhi.c-217-}
--
drivers/thunderbolt/nhi.c=234=static void ring_write_descriptors(struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-252-		if (ring->is_tx)
drivers/thunderbolt/nhi.c:253:			ring_iowrite_prod(ring, ring->head);
drivers/thunderbolt/nhi.c-254-		else
drivers/thunderbolt/nhi.c:255:			ring_iowrite_cons(ring, ring->head);
drivers/thunderbolt/nhi.c-256-	}
--
drivers/thunderbolt/nhi.c=380=static void __ring_interrupt_mask(struct tb_ring *ring, bool mask)
--
drivers/thunderbolt/nhi.c-386-
drivers/thunderbolt/nhi.c:387:	val = ioread32(ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-388-	if (mask)
--
drivers/thunderbolt/nhi.c-391-		val |= BIT(bit);
drivers/thunderbolt/nhi.c:392:	iowrite32(val, ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-393-}
--
drivers/thunderbolt/nhi.c=429=static void ring_clear_msix(const struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-437-	if (ring->is_tx)
drivers/thunderbolt/nhi.c:438:		iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR);
drivers/thunderbolt/nhi.c-439-	else
drivers/thunderbolt/nhi.c:440:		iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR +
drivers/thunderbolt/nhi.c-441-			  4 * (ring->nhi->hop_count / 32));
--
drivers/thunderbolt/nhi.c=642=void tb_ring_start(struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-666-
drivers/thunderbolt/nhi.c:667:	ring_iowrite64desc(ring, ring->descriptors_dma, 0);
drivers/thunderbolt/nhi.c-668-	if (ring->is_tx) {
drivers/thunderbolt/nhi.c:669:		ring_iowrite32desc(ring, ring->size, 12);
drivers/thunderbolt/nhi.c:670:		ring_iowrite32options(ring, 0, 4);
drivers/thunderbolt/nhi.c:671:		ring_iowrite32options(ring, flags, 0);
drivers/thunderbolt/nhi.c-672-	} else {
--
drivers/thunderbolt/nhi.c-674-
drivers/thunderbolt/nhi.c:675:		ring_iowrite32desc(ring, (frame_size << 16) | ring->size, 12);
drivers/thunderbolt/nhi.c:676:		ring_iowrite32options(ring, sof_eof_mask, 4);
drivers/thunderbolt/nhi.c:677:		ring_iowrite32options(ring, flags, 0);
drivers/thunderbolt/nhi.c-678-	}
--
drivers/thunderbolt/nhi.c-700-		flags |= RING_FLAG_E2E_FLOW_CONTROL;
drivers/thunderbolt/nhi.c:701:		ring_iowrite32options(ring, flags, 0);
drivers/thunderbolt/nhi.c-702-	}
--
drivers/thunderbolt/nhi.c=751=void tb_ring_stop(struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-765-
drivers/thunderbolt/nhi.c:766:	ring_iowrite32options(ring, 0, 0);
drivers/thunderbolt/nhi.c:767:	ring_iowrite64desc(ring, 0, 0);
drivers/thunderbolt/nhi.c:768:	ring_iowrite32desc(ring, 0, 8);
drivers/thunderbolt/nhi.c:769:	ring_iowrite32desc(ring, 0, 12);
drivers/thunderbolt/nhi.c-770-	ring->head = 0;
--
drivers/thunderbolt/nhi.c=870=int nhi_mailbox_cmd(struct tb_nhi *nhi, enum nhi_mailbox_cmd cmd, u32 data)
--
drivers/thunderbolt/nhi.c-874-
drivers/thunderbolt/nhi.c:875:	iowrite32(data, nhi->iobase + REG_INMAIL_DATA);
drivers/thunderbolt/nhi.c-876-
drivers/thunderbolt/nhi.c:877:	val = ioread32(nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-878-	val &= ~(REG_INMAIL_CMD_MASK | REG_INMAIL_ERROR);
drivers/thunderbolt/nhi.c-879-	val |= REG_INMAIL_OP_REQUEST | cmd;
drivers/thunderbolt/nhi.c:880:	iowrite32(val, nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-881-
--
drivers/thunderbolt/nhi.c-883-	do {
drivers/thunderbolt/nhi.c:884:		val = ioread32(nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-885-		if (!(val & REG_INMAIL_OP_REQUEST))
--
drivers/thunderbolt/nhi.c=907=enum nhi_fw_mode nhi_mailbox_mode(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-910-
drivers/thunderbolt/nhi.c:911:	val = ioread32(nhi->iobase + REG_OUTMAIL_CMD);
drivers/thunderbolt/nhi.c-912-	val &= REG_OUTMAIL_CMD_OPMODE_MASK;
--
drivers/thunderbolt/nhi.c=918=void nhi_interrupt_work(struct work_struct *work)
--
drivers/thunderbolt/nhi.c-935-		if (bit % 32 == 0)
drivers/thunderbolt/nhi.c:936:			value = ioread32(nhi->iobase
drivers/thunderbolt/nhi.c-937-					 + REG_RING_NOTIFY_BASE
--
drivers/thunderbolt/nhi.c=1132=static void nhi_reset(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-1136-
drivers/thunderbolt/nhi.c:1137:	val = ioread32(nhi->iobase + REG_CAPS);
drivers/thunderbolt/nhi.c-1138-	/* Reset only v2 and later routers */
--
drivers/thunderbolt/nhi.c-1146-
drivers/thunderbolt/nhi.c:1147:	iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
drivers/thunderbolt/nhi.c-1148-	msleep(100);
--
drivers/thunderbolt/nhi.c-1151-	do {
drivers/thunderbolt/nhi.c:1152:		val = ioread32(nhi->iobase + REG_RESET);
drivers/thunderbolt/nhi.c-1153-		if (!(val & REG_RESET_HRR)) {
--
drivers/thunderbolt/nhi.c=1186=int nhi_probe(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-1197-
drivers/thunderbolt/nhi.c:1198:	nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
drivers/thunderbolt/nhi.c-1199-	dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
]

86/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 11441
							output: 32
							thoughts: 96
						

Thoughts:
**My Investigative Process Regarding Thunderbolt Driver Register Access**

My current objective is to thoroughly understand how registers are being accessed within the Thunderbolt driver stack. To do this, I need to identify all relevant files that might be involved in direct register manipulation.

My initial scan of `drivers/thunderbolt/` has led me to consider a few specific files that I believe warrant closer examination. I'm asking myself: are there other files within this directory besides the ones I've already identified that might be directly interacting with hardware registers?

Specifically, I'm wondering about the potential register access patterns in files like `lc.c`, `usb4.c`, `switch.c`, and `tb.c`. These names suggest they could be core components or peripheral handlers within the Thunderbolt infrastructure.

A crucial step in my thought process is to confirm whether these files are indeed part of what I'm defining as the "thunderbolt nhi driver." This distinction is important for scope and to ensure I'm not straying into unrelated areas.

To achieve this confirmation and gain a clear overview of the driver's compilation structure, my next logical action is to examine the `drivers/thunderbolt/Makefile`. This will explicitly tell me which files are being built into the Thunderbolt driver, thus providing a definitive list of components I need to analyze for register access.


87/4 2026/08/10 08:30 tool read-file
0m Args:
map[File:drivers/thunderbolt/Makefile FirstLine:1 LineCount:50]

Results:
map[Contents:   1:	# SPDX-License-Identifier: GPL-2.0-only
   2:	ccflags-y := -I$(src)
   3:	obj-${CONFIG_USB4} := thunderbolt.o
   4:	thunderbolt-objs := nhi.o ctl.o tb.o switch.o cap.o pci.o path.o tunnel.o eeprom.o
   5:	thunderbolt-objs += domain.o dma_port.o icm.o property.o xdomain.o lc.o tmu.o usb4.o
   6:	thunderbolt-objs += usb4_port.o nvm.o retimer.o quirks.o clx.o
   7:	
   8:	thunderbolt-${CONFIG_ACPI} += acpi.o
   9:	thunderbolt-$(CONFIG_DEBUG_FS) += debugfs.o
  10:	thunderbolt-$(CONFIG_USB4_CONFIGFS) += configfs.o
  11:	thunderbolt-${CONFIG_USB4_KUNIT_TEST} += test.o
  12:	CFLAGS_test.o += $(DISABLE_STRUCTLEAK_PLUGIN)
  13:	
  14:	thunderbolt_dma_test-${CONFIG_USB4_DMA_TEST} += dma_test.o
  15:	obj-$(CONFIG_USB4_DMA_TEST) += thunderbolt_dma_test.o
  16:	
  17:	thunderbolt_stream-${CONFIG_USB4_STREAM} += stream.o
  18:	obj-$(CONFIG_USB4_STREAM) += thunderbolt_stream.o
]

88/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 11955
							output: 39
							thoughts: 947
						

Thoughts:
**My Thought Process on Thunderbolt NHI Driver Registers**

My immediate thought upon seeing the question about Thunderbolt registers, specifically those exceeding an offset of `0x39640`, was to focus on the core compilation unit, which I know is typically handled by `thunderbolt.o` or `thunderbolt-objs`. However, I quickly reminded myself to re-read the precise query: "Is there any other register accessed by thunderbolt nhi driver that has an offset larger than 0x39640?" This directed my attention to the specifics of the NHI (Thunderbolt Network Interface) driver.

My next step was to systematically examine where register definitions and accesses are declared and implemented. The obvious place to start was `nhi_regs.h`, as this is where the symbolic names for register offsets are usually defined. I meticulously went through the list provided in `nhi_regs.h`:

*   `REG_TX_RING_BASE` at `0x00000`
*   `REG_RX_RING_BASE` at `0x08000`
*   `REG_TX_OPTIONS_BASE` at `0x19800`
*   `REG_RX_OPTIONS_BASE` at `0x29800`
*   `REG_RING_NOTIFY_BASE` at `0x37800`
*   `REG_RING_INT_CLEAR` at `0x37808`
*   `REG_RING_INTERRUPT_BASE` at `0x38200`
*   `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at `0x38208`
*   `REG_INT_THROTTLING_RATE` at `0x38c00`
*   `REG_INT_VEC_ALLOC_BASE` at `0x38c40`
*   `REG_CAPS` at `0x39640`

As I reviewed this list, I specifically noted `REG_CAPS` sitting precisely at the threshold of `0x39640`. The question asks for registers *larger* than this, so `REG_CAPS` itself doesn't fit the criteria, but it's a crucial reference point.

However, I realized that simply checking the header file might not be exhaustive. Register accesses could be defined elsewhere, or new registers might be defined and used without being explicitly listed in that particular header. Therefore, my thought process evolved to consider other potential locations for register definitions and, more importantly, where these registers are actually *accessed* within the NHI driver's source code. This led me to look at `nhi.c` and any other files contributing to the NHI driver's functionality.

To confirm if any registers *defined* in `nhi_regs.h` already exceeded `0x39640`, I identified the ones from the list that met this condition:

*   `REG_DMA_MISC` at `0x39864`
*   `REG_RESET` at `0x39898`
*   `REG_INMAIL_DATA` at `0x39900`
*   `REG_INMAIL_CMD` at `0x39904`
*   `REG_OUTMAIL_CMD` at `0x3990c`
*   `REG_FW_STS` at `0x39944`

These are the first set of registers that clearly satisfy the "larger than `0x39640`" condition based on the provided definitions.

Still, I wasn't entirely satisfied. The possibility of other registers, either defined elsewhere or used through different mechanisms (like macros that resolve to offsets), remained. To ensure I didn't miss anything, I decided to perform a broader search. My instinct was to look for hexadecimal values within a relevant range in the `drivers/thunderbolt/` directory. I specifically targeted the prefixes that would encompass values immediately following `0x39640` and extending upwards. This included searching for hex numbers starting with `0x39` (beyond the already identified ones), `0x3a`, `0x3b`, `0x3c`, `0x3d`, `0x3e`, `0x3f`, and then jumping to higher ranges like `0x4` through `0xf` multiplied by powers of 16.

To make this search efficient and precise, I decided the best tool would be `grepper` (or a similar command-line utility like `grep` with appropriate flags). My final thought was to initiate a targeted search for the string `0x39` within the `drivers/thunderbolt/` directory, as this would likely reveal any other defined offsets or accesses in that vicinity or, at the very least, give me a starting point for a more granular search if needed. This systematic approach, moving from specific header files to broader code searches, is my standard procedure for ensuring a comprehensive understanding of register usage.


89/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:0x39[0-9a-fA-F]+ PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-113-/* The last 11 bits contain the number of hops supported by the NHI port. */
drivers/thunderbolt/nhi_regs.h:114:#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h-115-#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
--
drivers/thunderbolt/nhi_regs.h-117-
drivers/thunderbolt/nhi_regs.h:118:#define REG_DMA_MISC			0x39864
drivers/thunderbolt/nhi_regs.h-119-#define REG_DMA_MISC_INT_AUTO_CLEAR     BIT(2)
--
drivers/thunderbolt/nhi_regs.h-121-
drivers/thunderbolt/nhi_regs.h:122:#define REG_RESET			0x39898
drivers/thunderbolt/nhi_regs.h-123-#define REG_RESET_HRR			BIT(0)
drivers/thunderbolt/nhi_regs.h-124-
drivers/thunderbolt/nhi_regs.h:125:#define REG_INMAIL_DATA			0x39900
drivers/thunderbolt/nhi_regs.h-126-
drivers/thunderbolt/nhi_regs.h:127:#define REG_INMAIL_CMD			0x39904
drivers/thunderbolt/nhi_regs.h-128-#define REG_INMAIL_CMD_MASK		GENMASK(7, 0)
--
drivers/thunderbolt/nhi_regs.h-131-
drivers/thunderbolt/nhi_regs.h:132:#define REG_OUTMAIL_CMD			0x3990c
drivers/thunderbolt/nhi_regs.h-133-#define REG_OUTMAIL_CMD_OPMODE_SHIFT	8
--
drivers/thunderbolt/nhi_regs.h-135-
drivers/thunderbolt/nhi_regs.h:136:#define REG_FW_STS			0x39944
drivers/thunderbolt/nhi_regs.h-137-#define REG_FW_STS_NVM_AUTH_DONE	BIT(31)
]

90/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 13528
							output: 49
							thoughts: 159
						

Thoughts:
**My Thought Process on Approaching This Search Query**

Initially, my mind grappled with the idea of searching for specific, seemingly arbitrary hexadecimal values: `0x3a`, `0x3b`, `0x3c`, `0x3d`, `0x3e`, `0x3f`, `0x4`, `0x5`, `0x6`, `0x7`, `0x8`, `0x9`, `0xa`, `0xb`, `0xc`, `0xd`, `0xe`, `0xf`. This felt a bit scattershot, like looking for specific grains of sand on a beach without a clear strategy. I recognized that while these might be *individual* interesting values, simply listing them felt inefficient. There had to be a more structured way to approach what I was likely trying to find – patterns or specific types of hexadecimal representations within a codebase.

This led me to refine my thinking. I realized that the `0x` prefix clearly indicates hexadecimal notation. The single-digit hex values (`0x4` through `0xf`) were likely part of a broader range I was interested in. The two-digit values (`0x3a` through `0x3f`) also hinted at a specific range of interest, perhaps a contiguous block of bytes or a specific set of markers. The repetition suggested I wasn't just looking for *any* hex values, but rather values within a particular segment of the hexadecimal spectrum.

Then, a more precise pattern emerged in my mind. I started thinking about how these hexadecimal values are represented and how they might appear in code. The initial list of single and double hex values felt like precursors to a more complex structure. This is where the idea of regular expressions began to solidify. I started to conceptualize a pattern that would capture not just isolated hex numbers, but also those that are part of a larger hexadecimal sequence.

Specifically, I thought about the structure of hexadecimal numbers in code. They often begin with `0x`. Then, depending on their length and significance, they might be followed by a certain number of hexadecimal digits. My initial list was a bit of a jumble, but it pointed towards a need to capture values that started with `0x` and were followed by at least one hex digit.

My refinement then zeroed in on a more robust and common pattern: a hexadecimal number that begins with `0x`, followed by a hexadecimal digit from 4 through 9 (both uppercase and lowercase), and then followed by four *more* hexadecimal digits (again, uppercase or lowercase). This felt like a much more targeted and likely useful search pattern. The `[4-9a-fA-F]` part directly addresses the lower bound of my initial hex range (`0x4` through `0xf`, with `a-f` covering the rest), while the `{4}` ensures I'm looking for values of a specific, and likely significant, length after the initial digit. The choice of targeting this specific length (five hex digits after `0x`) often signifies specific data structures, pointers, or constants that are of particular interest in lower-level code.

Finally, to ensure I was looking in the most relevant place, I narrowed the scope of my search. Given the nature of the hex values I was considering, they likely relate to low-level system operations or hardware interfaces. The `drivers/thunderbolt/` directory immediately came to mind as the most probable location within a codebase for such specific hexadecimal encodings related to hardware interaction. This directory would house code directly managing the Thunderbolt interface, which is rich with hardware-specific constants and registers represented in hexadecimal. This combination of a precise regex and a targeted directory seemed like the most effective way to uncover the information I was seeking.


91/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:0x[4-9a-fA-F][0-9a-fA-F]{4} PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/acpi.c=181=static const guid_t retimer_dsm_guid =
drivers/thunderbolt/acpi.c:182:	GUID_INIT(0xe0053122, 0x795b, 0x4122,
drivers/thunderbolt/acpi.c-183-		  0x8a, 0x5e, 0x57, 0xbe, 0x1d, 0x26, 0xac, 0xb3);
--
drivers/thunderbolt/dma_port.c=168=static int dma_find_port(struct tb_switch *sw)
--
drivers/thunderbolt/dma_port.c-182-				    2, 1, DMA_PORT_TIMEOUT);
drivers/thunderbolt/dma_port.c:183:		if (!ret && (type & 0xffffff) == TB_TYPE_NHI)
drivers/thunderbolt/dma_port.c-184-			return ports[i];
--
drivers/thunderbolt/eeprom.c=362=static int tb_drom_parse_entry_port(struct tb_switch *sw,
--
drivers/thunderbolt/eeprom.c-385-		return res;
drivers/thunderbolt/eeprom.c:386:	type &= 0xffffff;
drivers/thunderbolt/eeprom.c-387-
--
drivers/thunderbolt/icm.c=1579=static int icm_ar_get_boot_acl(struct tb *tb, uuid_t *uuids, size_t nuuids)
--
drivers/thunderbolt/icm.c-1601-
drivers/thunderbolt/icm.c:1602:		if (uuid[0] == 0xffffffff && uuid[1] == 0xffffffff) {
drivers/thunderbolt/icm.c-1603-			/* Map empty entries to null UUID */
--
drivers/thunderbolt/icm.c-1607-			/* Upper two DWs are always one's */
drivers/thunderbolt/icm.c:1608:			uuid[2] = 0xffffffff;
drivers/thunderbolt/icm.c:1609:			uuid[3] = 0xffffffff;
drivers/thunderbolt/icm.c-1610-		}
--
drivers/thunderbolt/icm.c=1616=static int icm_ar_set_boot_acl(struct tb *tb, const uuid_t *uuids,
--
drivers/thunderbolt/icm.c-1635-			 */
drivers/thunderbolt/icm.c:1636:			request.acl[i].uuid_lo = 0xffffffff;
drivers/thunderbolt/icm.c:1637:			request.acl[i].uuid_hi = 0xffffffff;
drivers/thunderbolt/icm.c-1638-		} else {
drivers/thunderbolt/icm.c-1639-			/* Two high DWs need to be set to all one */
drivers/thunderbolt/icm.c:1640:			if (uuid[2] != 0xffffffff || uuid[3] != 0xffffffff)
drivers/thunderbolt/icm.c-1641-				return -EINVAL;
--
drivers/thunderbolt/icm.c=1687=static void icm_icl_set_uuid(struct tb *tb)
--
drivers/thunderbolt/icm.c-1693-	pci_read_config_dword(pdev, VS_CAP_11, &uuid[1]);
drivers/thunderbolt/icm.c:1694:	uuid[2] = 0xffffffff;
drivers/thunderbolt/icm.c:1695:	uuid[3] = 0xffffffff;
drivers/thunderbolt/icm.c-1696-
--
drivers/thunderbolt/nvm.c=89=static int intel_switch_nvm_validate(struct tb_nvm *nvm)
--
drivers/thunderbolt/nvm.c-101-	 */
drivers/thunderbolt/nvm.c:102:	hdr_size = (*(u32 *)buf) & 0xffffff;
drivers/thunderbolt/nvm.c-103-	if (hdr_size + INTEL_NVM_DEVID + 2 >= image_size)
--
drivers/thunderbolt/nvm.c=160=static int asmedia_switch_nvm_version(struct tb_nvm *nvm)
--
drivers/thunderbolt/nvm.c-169-
drivers/thunderbolt/nvm.c:170:	nvm->major = (val << 16) & 0xff0000;
drivers/thunderbolt/nvm.c-171-	nvm->major |= val & 0x00ff00;
--
drivers/thunderbolt/nvm.c-177-
drivers/thunderbolt/nvm.c:178:	nvm->minor = (val << 16) & 0xff0000;
drivers/thunderbolt/nvm.c-179-	nvm->minor |= val & 0x00ff00;
--
drivers/thunderbolt/nvm.c=223=static int intel_retimer_nvm_validate(struct tb_nvm *nvm)
--
drivers/thunderbolt/nvm.c-235-	 */
drivers/thunderbolt/nvm.c:236:	hdr_size = (*(u32 *)buf) & 0xffffff;
drivers/thunderbolt/nvm.c-237-	if (hdr_size + INTEL_NVM_DEVID + 2 >= image_size)
--
drivers/thunderbolt/property.c=32=struct tb_property_dir_entry {
--
drivers/thunderbolt/property.c-36-
drivers/thunderbolt/property.c:37:#define TB_PROPERTY_ROOTDIR_MAGIC	0x55584401
drivers/thunderbolt/property.c-38-#define TB_PROPERTY_MAX_DEPTH		8
--
drivers/thunderbolt/sb_regs.h=21=enum usb4_sb_opcode {
drivers/thunderbolt/sb_regs.h-22-	USB4_SB_OPCODE_ERR = 0x20525245,			/* "ERR " */
drivers/thunderbolt/sb_regs.h:23:	USB4_SB_OPCODE_ONS = 0x444d4321,			/* "!CMD" */
drivers/thunderbolt/sb_regs.h:24:	USB4_SB_OPCODE_ROUTER_OFFLINE = 0x4e45534c,		/* "LSEN" */
drivers/thunderbolt/sb_regs.h:25:	USB4_SB_OPCODE_ENUMERATE_RETIMERS = 0x4d554e45,		/* "ENUM" */
drivers/thunderbolt/sb_regs.h:26:	USB4_SB_OPCODE_SET_INBOUND_SBTX = 0x5055534c,		/* "LSUP" */
drivers/thunderbolt/sb_regs.h:27:	USB4_SB_OPCODE_UNSET_INBOUND_SBTX = 0x50555355,		/* "USUP" */
drivers/thunderbolt/sb_regs.h:28:	USB4_SB_OPCODE_QUERY_LAST_RETIMER = 0x5453414c,		/* "LAST" */
drivers/thunderbolt/sb_regs.h:29:	USB4_SB_OPCODE_QUERY_CABLE_RETIMER = 0x524c4243,	/* "CBLR" */
drivers/thunderbolt/sb_regs.h:30:	USB4_SB_OPCODE_GET_NVM_SECTOR_SIZE = 0x53534e47,	/* "GNSS" */
drivers/thunderbolt/sb_regs.h:31:	USB4_SB_OPCODE_NVM_SET_OFFSET = 0x53504f42,		/* "BOPS" */
drivers/thunderbolt/sb_regs.h:32:	USB4_SB_OPCODE_NVM_BLOCK_WRITE = 0x574b4c42,		/* "BLKW" */
drivers/thunderbolt/sb_regs.h:33:	USB4_SB_OPCODE_NVM_AUTH_WRITE = 0x48545541,		/* "AUTH" */
drivers/thunderbolt/sb_regs.h:34:	USB4_SB_OPCODE_NVM_READ = 0x52524641,			/* "AFRR" */
drivers/thunderbolt/sb_regs.h:35:	USB4_SB_OPCODE_READ_LANE_MARGINING_CAP = 0x50434452,	/* "RDCP" */
drivers/thunderbolt/sb_regs.h:36:	USB4_SB_OPCODE_RUN_HW_LANE_MARGINING = 0x474d4852,	/* "RHMG" */
drivers/thunderbolt/sb_regs.h:37:	USB4_SB_OPCODE_RUN_SW_LANE_MARGINING = 0x474d5352,	/* "RSMG" */
drivers/thunderbolt/sb_regs.h:38:	USB4_SB_OPCODE_READ_SW_MARGIN_ERR = 0x57534452,		/* "RDSW" */
drivers/thunderbolt/sb_regs.h-39-};
--
drivers/thunderbolt/switch.c=1750=static int tb_plug_events_active(struct tb_switch *sw, bool active)
--
drivers/thunderbolt/switch.c-1762-	if (active) {
drivers/thunderbolt/switch.c:1763:		data = data & 0xFFFFFF83;
drivers/thunderbolt/switch.c-1764-		switch (sw->config.device_id) {
--
drivers/thunderbolt/switch.c=2676=static int tb_switch_set_uuid(struct tb_switch *sw)
--
drivers/thunderbolt/switch.c-2709-		 */
drivers/thunderbolt/switch.c:2710:		uuid[0] = sw->uid & 0xffffffff;
drivers/thunderbolt/switch.c:2711:		uuid[1] = (sw->uid >> 32) & 0xffffffff;
drivers/thunderbolt/switch.c:2712:		uuid[2] = 0xffffffff;
drivers/thunderbolt/switch.c:2713:		uuid[3] = 0xffffffff;
drivers/thunderbolt/switch.c-2714-	}
--
drivers/thunderbolt/test.c=72=static struct tb_switch *alloc_host(struct kunit *test)
--
drivers/thunderbolt/test.c-129-	sw->ports[7].config.max_out_hop_id = 11;
drivers/thunderbolt/test.c:130:	sw->ports[7].config.nfc_credits = 0x41800000;
drivers/thunderbolt/test.c-131-
--
drivers/thunderbolt/test.c=655=static void tb_test_path_complex_tree_walk(struct kunit *test)
--
drivers/thunderbolt/test.c-678-	static const struct port_expectation test_data[] = {
drivers/thunderbolt/test.c:679:		{ .route = 0x50301, .port = 13, .type = TB_TYPE_DP_HDMI_IN },
drivers/thunderbolt/test.c:680:		{ .route = 0x50301, .port = 1, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c-681-		{ .route = 0x301, .port = 5, .type = TB_TYPE_PORT },
--
drivers/thunderbolt/test.c-686-		{ .route = 0x701, .port = 7, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c:687:		{ .route = 0x70701, .port = 1, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c:688:		{ .route = 0x70701, .port = 3, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c-689-		{ .route = 0x3070701, .port = 1, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c-690-		{ .route = 0x3070701, .port = 5, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c:691:		{ .route = 0x503070701, .port = 1, .type = TB_TYPE_PORT },
drivers/thunderbolt/test.c:692:		{ .route = 0x503070701, .port = 14, .type = TB_TYPE_DP_HDMI_OUT },
drivers/thunderbolt/test.c-693-	};
--
drivers/thunderbolt/test.c-700-	dev2 = alloc_dev_default(test, dev1, 0x301, true);
drivers/thunderbolt/test.c:701:	dev3 = alloc_dev_with_dpin(test, dev2, 0x50301, true);
drivers/thunderbolt/test.c-702-	alloc_dev_default(test, dev1, 0x501, true);
drivers/thunderbolt/test.c-703-	dev5 = alloc_dev_default(test, dev1, 0x701, true);
drivers/thunderbolt/test.c:704:	dev6 = alloc_dev_default(test, dev5, 0x70701, true);
drivers/thunderbolt/test.c-705-	dev7 = alloc_dev_default(test, dev6, 0x3070701, true);
drivers/thunderbolt/test.c-706-	alloc_dev_default(test, dev7, 0x303070701, true);
drivers/thunderbolt/test.c:707:	dev9 = alloc_dev_default(test, dev7, 0x503070701, true);
drivers/thunderbolt/test.c-708-
--
drivers/thunderbolt/test.c=990=static void tb_test_path_not_bonded_lane1_chain(struct kunit *test)
--
drivers/thunderbolt/test.c-1028-		{
drivers/thunderbolt/test.c:1029:			.route = 0x50701,
drivers/thunderbolt/test.c-1030-			.in_port = 2,
--
drivers/thunderbolt/test.c-1043-	dev2 = alloc_dev_default(test, dev1, 0x701, false);
drivers/thunderbolt/test.c:1044:	dev3 = alloc_dev_default(test, dev2, 0x50701, false);
drivers/thunderbolt/test.c-1045-
--
drivers/thunderbolt/test.c=1070=static void tb_test_path_not_bonded_lane1_chain_reverse(struct kunit *test)
--
drivers/thunderbolt/test.c-1087-		{
drivers/thunderbolt/test.c:1088:			.route = 0x50701,
drivers/thunderbolt/test.c-1089-			.in_port = 13,
--
drivers/thunderbolt/test.c-1123-	dev2 = alloc_dev_default(test, dev1, 0x701, false);
drivers/thunderbolt/test.c:1124:	dev3 = alloc_dev_with_dpin(test, dev2, 0x50701, false);
drivers/thunderbolt/test.c-1125-
--
drivers/thunderbolt/test.c=1150=static void tb_test_path_mixed_chain(struct kunit *test)
--
drivers/thunderbolt/test.c-1192-		{
drivers/thunderbolt/test.c:1193:			.route = 0x50701,
drivers/thunderbolt/test.c-1194-			.in_port = 2,
--
drivers/thunderbolt/test.c-1214-	dev2 = alloc_dev_default(test, dev1, 0x701, false);
drivers/thunderbolt/test.c:1215:	dev3 = alloc_dev_default(test, dev2, 0x50701, false);
drivers/thunderbolt/test.c-1216-	dev4 = alloc_dev_default(test, dev3, 0x3050701, true);
--
drivers/thunderbolt/test.c=1242=static void tb_test_path_mixed_chain_reverse(struct kunit *test)
--
drivers/thunderbolt/test.c-1270-		{
drivers/thunderbolt/test.c:1271:			.route = 0x50701,
drivers/thunderbolt/test.c-1272-			.in_port = 3,
--
drivers/thunderbolt/test.c-1306-	dev2 = alloc_dev_default(test, dev1, 0x701, false);
drivers/thunderbolt/test.c:1307:	dev3 = alloc_dev_default(test, dev2, 0x50701, false);
drivers/thunderbolt/test.c-1308-	dev4 = alloc_dev_default(test, dev3, 0x3050701, true);
--
drivers/thunderbolt/test.c=1473=static void tb_test_tunnel_dp_tree(struct kunit *test)
--
drivers/thunderbolt/test.c-1499-	alloc_dev_default(test, dev1, 0x703, true);
drivers/thunderbolt/test.c:1500:	dev5 = alloc_dev_default(test, dev3, 0x50503, true);
drivers/thunderbolt/test.c-1501-
--
drivers/thunderbolt/test.c=1603=static void tb_test_tunnel_3dp(struct kunit *test)
--
drivers/thunderbolt/test.c-1629-	dev4 = alloc_dev_default(test, dev1, 0x703, true);
drivers/thunderbolt/test.c:1630:	dev5 = alloc_dev_default(test, dev3, 0x50503, true);
drivers/thunderbolt/test.c-1631-
--
drivers/thunderbolt/test.c=1724=static void tb_test_tunnel_port_on_path(struct kunit *test)
--
drivers/thunderbolt/test.c-1748-	dev4 = alloc_dev_default(test, dev1, 0x703, true);
drivers/thunderbolt/test.c:1749:	dev5 = alloc_dev_default(test, dev3, 0x50503, true);
drivers/thunderbolt/test.c-1750-
--
drivers/thunderbolt/test.c=2607=static const u32 root_directory[] = {
drivers/thunderbolt/test.c:2608:	0x55584401,	/* "UXD" v1 */
drivers/thunderbolt/test.c-2609-	0x00000018,	/* Root directory length */
drivers/thunderbolt/test.c:2610:	0x76656e64,	/* "vend" */
drivers/thunderbolt/test.c:2611:	0x6f726964,	/* "orid" */
drivers/thunderbolt/test.c:2612:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2613-	0x00000a27,	/* Immediate value, ! Vendor ID */
drivers/thunderbolt/test.c:2614:	0x76656e64,	/* "vend" */
drivers/thunderbolt/test.c:2615:	0x6f726964,	/* "orid" */
drivers/thunderbolt/test.c:2616:	0x74000003,	/* "t" R 3 */
drivers/thunderbolt/test.c-2617-	0x0000001a,	/* Text leaf offset, (“Apple Inc.”) */
drivers/thunderbolt/test.c:2618:	0x64657669,	/* "devi" */
drivers/thunderbolt/test.c:2619:	0x63656964,	/* "ceid" */
drivers/thunderbolt/test.c:2620:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2621-	0x0000000a,	/* Immediate value, ! Device ID */
drivers/thunderbolt/test.c:2622:	0x64657669,	/* "devi" */
drivers/thunderbolt/test.c:2623:	0x63656964,	/* "ceid" */
drivers/thunderbolt/test.c:2624:	0x74000003,	/* "t" R 3 */
drivers/thunderbolt/test.c-2625-	0x0000001d,	/* Text leaf offset, (“Macintosh”) */
drivers/thunderbolt/test.c:2626:	0x64657669,	/* "devi" */
drivers/thunderbolt/test.c:2627:	0x63657276,	/* "cerv" */
drivers/thunderbolt/test.c:2628:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c:2629:	0x80000100,	/* Immediate value, Device Revision */
drivers/thunderbolt/test.c:2630:	0x6e657477,	/* "netw" */
drivers/thunderbolt/test.c:2631:	0x6f726b00,	/* "ork" */
drivers/thunderbolt/test.c:2632:	0x44000014,	/* "D" R 20 */
drivers/thunderbolt/test.c-2633-	0x00000021,	/* Directory data offset, (Network Directory) */
drivers/thunderbolt/test.c:2634:	0x4170706c,	/* "Appl" */
drivers/thunderbolt/test.c:2635:	0x6520496e,	/* "e In" */
drivers/thunderbolt/test.c:2636:	0x632e0000,	/* "c." ! */
drivers/thunderbolt/test.c:2637:	0x4d616369,	/* "Maci" */
drivers/thunderbolt/test.c:2638:	0x6e746f73,	/* "ntos" */
drivers/thunderbolt/test.c:2639:	0x68000000,	/* "h" */
drivers/thunderbolt/test.c-2640-	0x00000000,	/* padding */
drivers/thunderbolt/test.c:2641:	0xca8961c6,	/* Directory UUID, Network Directory */
drivers/thunderbolt/test.c:2642:	0x9541ce1c,	/* Directory UUID, Network Directory */
drivers/thunderbolt/test.c:2643:	0x5949b8bd,	/* Directory UUID, Network Directory */
drivers/thunderbolt/test.c:2644:	0x4f5a5f2e,	/* Directory UUID, Network Directory */
drivers/thunderbolt/test.c:2645:	0x70727463,	/* "prtc" */
drivers/thunderbolt/test.c:2646:	0x69640000,	/* "id" */
drivers/thunderbolt/test.c:2647:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2648-	0x00000001,	/* Immediate value, Network Protocol ID */
drivers/thunderbolt/test.c:2649:	0x70727463,	/* "prtc" */
drivers/thunderbolt/test.c:2650:	0x76657273,	/* "vers" */
drivers/thunderbolt/test.c:2651:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2652-	0x00000001,	/* Immediate value, Network Protocol Version */
drivers/thunderbolt/test.c:2653:	0x70727463,	/* "prtc" */
drivers/thunderbolt/test.c:2654:	0x72657673,	/* "revs" */
drivers/thunderbolt/test.c:2655:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2656-	0x00000001,	/* Immediate value, Network Protocol Revision */
drivers/thunderbolt/test.c:2657:	0x70727463,	/* "prtc" */
drivers/thunderbolt/test.c:2658:	0x73746e73,	/* "stns" */
drivers/thunderbolt/test.c:2659:	0x76000001,	/* "v" R 1 */
drivers/thunderbolt/test.c-2660-	0x00000000,	/* Immediate value, Network Protocol Settings */
--
drivers/thunderbolt/test.c=2663=static const uuid_t network_dir_uuid =
drivers/thunderbolt/test.c:2664:	UUID_INIT(0xc66189ca, 0x1cce, 0x4195,
drivers/thunderbolt/test.c-2665-		  0xbd, 0xb8, 0x49, 0x59, 0x2e, 0x5f, 0x5a, 0x4f);
--
drivers/thunderbolt/test.c=2868=static void tb_test_property_parse_u32_wrap(struct kunit *test)
--
drivers/thunderbolt/test.c-2880-
drivers/thunderbolt/test.c:2881:	block[0] = 0x55584401;	/* "UXD" v1 magic */
drivers/thunderbolt/test.c-2882-	block[1] = 0x00000004;	/* Root directory length: one entry */
--
drivers/thunderbolt/test.c-2884-	/*
drivers/thunderbolt/test.c:2885:	 * DATA entry whose value 0xffffff00 + length 0x100 wrap to 0
drivers/thunderbolt/test.c-2886-	 * in u32, passing the sum <= block_len guard even though the
--
drivers/thunderbolt/test.c-2888-	 */
drivers/thunderbolt/test.c:2889:	block[2] = 0x61616161;	/* key_hi */
drivers/thunderbolt/test.c:2890:	block[3] = 0x61616161;	/* key_lo */
drivers/thunderbolt/test.c:2891:	block[4] = 0x64000100;	/* type=DATA, reserved=0, length=0x100 */
drivers/thunderbolt/test.c:2892:	block[5] = 0xffffff00;	/* value */
drivers/thunderbolt/test.c-2893-
--
drivers/thunderbolt/test.c=2899=static void tb_test_property_parse_recursion(struct kunit *test)
--
drivers/thunderbolt/test.c-2912-
drivers/thunderbolt/test.c:2913:	block[0] = 0x55584401;	/* "UXD" v1 magic */
drivers/thunderbolt/test.c-2914-	block[1] = 0x00000004;	/* Root directory length: one entry */
--
drivers/thunderbolt/test.c-2923-	 */
drivers/thunderbolt/test.c:2924:	block[2] = 0x61616161;	/* key_hi */
drivers/thunderbolt/test.c:2925:	block[3] = 0x61616161;	/* key_lo */
drivers/thunderbolt/test.c:2926:	block[4] = 0x44000008;	/* type=DIRECTORY, reserved=0, length=8 */
drivers/thunderbolt/test.c-2927-	block[5] = 0x00000002;	/* value = dir_offset */
drivers/thunderbolt/test.c-2928-
drivers/thunderbolt/test.c:2929:	block[6] = 0x62626262;	/* doubles as UUID dword 0 / child key_hi */
drivers/thunderbolt/test.c:2930:	block[7] = 0x62626262;	/* doubles as UUID dword 1 / child key_lo */
drivers/thunderbolt/test.c:2931:	block[8] = 0x44000008;	/* type=DIRECTORY, reserved=0, length=8 */
drivers/thunderbolt/test.c-2932-	block[9] = 0x00000002;	/* value = dir_offset (back at parent) */
--
drivers/thunderbolt/test.c=2939=static void tb_test_property_parse_dir_len_underflow(struct kunit *test)
--
drivers/thunderbolt/test.c-2957-
drivers/thunderbolt/test.c:2958:	block[0] = 0x55584401;	/* "UXD" v1 magic */
drivers/thunderbolt/test.c-2959-	block[1] = 0x00000004;	/* Root directory length: one entry */
--
drivers/thunderbolt/test.c-2967-	 */
drivers/thunderbolt/test.c:2968:	block[2] = 0x61616161;	/* key_hi */
drivers/thunderbolt/test.c:2969:	block[3] = 0x61616161;	/* key_lo */
drivers/thunderbolt/test.c:2970:	block[4] = 0x44000003;	/* type=DIRECTORY, reserved=0, length=3 */
drivers/thunderbolt/test.c-2971-	block[5] = 0x00000004;	/* value = dir_offset */
--
drivers/thunderbolt/test.c=2979=static void tb_test_property_parse_zero_length(struct kunit *test)
--
drivers/thunderbolt/test.c-2985-
drivers/thunderbolt/test.c:2986:	block[0] = 0x55584401;	/* rootdir magic */
drivers/thunderbolt/test.c-2987-	block[1] = 0x00000004;	/* root length: one entry */
drivers/thunderbolt/test.c-2988-
drivers/thunderbolt/test.c:2989:	block[2] = 0x61616161;	/* key_hi */
drivers/thunderbolt/test.c:2990:	block[3] = 0x61616161;	/* key_lo */
drivers/thunderbolt/test.c:2991:	block[4] = 0x74000000;	/* type=TEXT, reserved=0, length=0 */
drivers/thunderbolt/test.c-2992-	block[5] = 0x00000000;	/* value */
--
drivers/thunderbolt/test.c=2999=static void tb_test_property_parse_rootdir_overflow(struct kunit *test)
--
drivers/thunderbolt/test.c-3005-
drivers/thunderbolt/test.c:3006:	block[0] = 0x55584401;	/* rootdir magic */
drivers/thunderbolt/test.c-3007-	block[1] = 0x00000004;	/* root length claims 4 dwords of content */
drivers/thunderbolt/test.c:3008:	block[2] = 0x61616161;
drivers/thunderbolt/test.c:3009:	block[3] = 0x61616161;
drivers/thunderbolt/test.c-3010-
--
drivers/thunderbolt/tmu.c=447=int tb_switch_tmu_post_time(struct tb_switch *sw)
--
drivers/thunderbolt/tmu.c-502-	 * Have the new switch update its local time by:
drivers/thunderbolt/tmu.c:503:	 * 1) writing 0x1 to the Post Time Low register and 0xffffffff to
drivers/thunderbolt/tmu.c-504-	 * Post Time High register.
--
drivers/thunderbolt/tmu.c-508-	 */
drivers/thunderbolt/tmu.c:509:	post_time = 0xffffffff00000001ULL;
drivers/thunderbolt/tmu.c-510-
--
drivers/thunderbolt/xdomain.c=81=static const uuid_t tb_xdp_uuid =
drivers/thunderbolt/xdomain.c:82:	UUID_INIT(0xb638d70e, 0x42ff, 0x40bb,
drivers/thunderbolt/xdomain.c-83-		  0x97, 0xc2, 0x90, 0xe2, 0xc0, 0xb2, 0xff, 0x07);
--
drivers/thunderbolt/xdomain.c=2748=int tb_xdomain_init(void)
--
drivers/thunderbolt/xdomain.c-2764-	tb_property_add_immediate(xdomain_property_dir, "deviceid", 0x0004);
drivers/thunderbolt/xdomain.c:2765:	tb_property_add_immediate(xdomain_property_dir, "devicerv", 0x80000100);
drivers/thunderbolt/xdomain.c-2766-
]

92/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 23006
							output: 29
							thoughts: 535
						

Thoughts:
**My Investigation into Thunderbolt NHI Register Offsets**

Initially, my understanding was that the values I was seeing weren't directly register offsets. This led me to hypothesize that the actual register offsets might be defined elsewhere, so I decided to search for `0x39` and other potential offsets within `drivers/thunderbolt/nhi.c` and related files. However, upon revisiting `drivers/thunderbolt/nhi_regs.h`, I meticulously reviewed the defined registers. My findings here were:

*   `REG_TX_RING_BASE`: `0x00000`
*   `REG_RX_RING_BASE`: `0x08000`
*   `REG_TX_OPTIONS_BASE`: `0x19800`
*   `REG_RX_OPTIONS_BASE`: `0x29800`
*   `REG_RING_NOTIFY_BASE`: `0x37800`
*   `REG_RING_INT_CLEAR`: `0x37808`
*   `REG_RING_INTERRUPT_BASE`: `0x38200`
*   `REG_RING_INTERRUPT_MASK_CLEAR_BASE`: `0x38208`
*   `REG_INT_THROTTLING_RATE`: `0x38c00`
*   `REG_INT_VEC_ALLOC_BASE`: `0x38c40`
*   `REG_CAPS`: `0x39640`
*   `REG_DMA_MISC`: `0x39864`
*   `REG_RESET`: `0x39898`
*   `REG_INMAIL_DATA`: `0x39900`
*   `REG_INMAIL_CMD`: `0x39904`
*   `REG_OUTMAIL_CMD`: `0x3990c`
*   `REG_FW_STS`: `0x39944`

After confirming that I had examined the entire `nhi_regs.h` file and that no other registers were defined within it, my next thought was to consider whether the NHI driver might be interacting with registers defined in *other* header files. Specifically, I began to wonder if the NHI driver accesses registers defined in `drivers/thunderbolt/tb_regs.h`. To investigate this, I planned to search for any references to `tb_regs.h` within `drivers/thunderbolt/nhi.c` and other files in that directory, essentially performing a grep operation for `tb_regs.h` within the `drivers/thunderbolt/` path.


93/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:tb_regs\.h PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/dma_port.c-13-#include "dma_port.h"
drivers/thunderbolt/dma_port.c:14:#include "tb_regs.h"
drivers/thunderbolt/dma_port.c-15-
--
drivers/thunderbolt/tb.c-15-#include "tb.h"
drivers/thunderbolt/tb.c:16:#include "tb_regs.h"
drivers/thunderbolt/tb.c-17-#include "tunnel.h"
--
drivers/thunderbolt/tb.h-18-
drivers/thunderbolt/tb.h:19:#include "tb_regs.h"
drivers/thunderbolt/tb.h-20-#include "ctl.h"
]

94/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 23747
							output: 35
							thoughts: 55
						

Thoughts:
**My Thought Process on the `nhi.c` Inclusion Issue**

Okay, I've just been looking at `nhi.c`, and a potential issue has immediately jumped out at me. I'm realizing that `nhi.c` *doesn't* appear to include `tb_regs.h`. This is a bit concerning, given the nature of the code.

My immediate next step is to confirm my suspicion and understand the scope of this potential problem. To do that, I need to see if `nhi.c` is including *any* register definition files at all. My instinct is to go straight to the source, so I'm going to pull up and examine the very top of the `drivers/thunderbolt/nhi.c` file. This will give me a clear picture of its direct dependencies and whether it's relying on external definitions for register access.


95/4 2026/08/10 08:30 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi.c FirstLine:1 LineCount:40]

Results:
map[Contents:   1:	// SPDX-License-Identifier: GPL-2.0-only
   2:	/*
   3:	 * Thunderbolt driver - NHI driver
   4:	 *
   5:	 * The NHI (native host interface) is the device that allows us to send and
   6:	 * receive frames from the thunderbolt bus.
   7:	 *
   8:	 * Copyright (c) 2014 Andreas Noever <andreas.noever@gmail.com>
   9:	 * Copyright (C) 2018, Intel Corporation
  10:	 */
  11:	
  12:	#include <linux/pm_runtime.h>
  13:	#include <linux/slab.h>
  14:	#include <linux/errno.h>
  15:	#include <linux/dma-mapping.h>
  16:	#include <linux/interrupt.h>
  17:	#include <linux/iommu.h>
  18:	#include <linux/module.h>
  19:	#include <linux/delay.h>
  20:	#include <linux/property.h>
  21:	#include <linux/string_choices.h>
  22:	#include <linux/string_helpers.h>
  23:	
  24:	#include "nhi.h"
  25:	#include "nhi_regs.h"
  26:	#include "tb.h"
  27:	
  28:	#define RING_TYPE(ring) ((ring)->is_tx ? "TX ring" : "RX ring")
  29:	
  30:	#define RING_FIRST_USABLE_HOPID	1
  31:	/*
  32:	 * Used with QUIRK_E2E to specify an unused HopID the Rx credits are
  33:	 * transferred.
  34:	 */
  35:	#define RING_E2E_RESERVED_HOPID	RING_FIRST_USABLE_HOPID
  36:	
  37:	#define NHI_MAILBOX_TIMEOUT	500 /* ms */
  38:	
  39:	static bool host_reset = true;
  40:	module_param(host_reset, bool, 0444);
]

96/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 24415
							output: 36
							thoughts: 59
						

Thoughts:
**My Thought Process on Investigating NHI Driver Files**

My initial reaction upon encountering the NHI driver was a strong impulse to ensure I had a comprehensive understanding of its scope within the `drivers/thunderbolt/` directory. I immediately considered the possibility of other files besides the one I was directly examining that might also be intrinsically linked to the NHI driver or, crucially, directly interact with its underlying registers. This isn't just about checking for related files; it's about identifying all the pieces of the puzzle that constitute the NHI driver's implementation and its hardware interface.

Following this line of reasoning, my next logical step was to delve into `drivers/thunderbolt/nhi.h`. My reasoning here is straightforward: header files, especially those named like `nhi.h` in this context, are typically where key definitions, structures, enumerations, and function prototypes related to a specific module reside. By examining `nhi.h`, I expect to gain immediate insight into the public interface of the NHI driver, understand the data structures it employs, and potentially identify the register definitions themselves. This would be the foundational step in grasping how other parts of the driver, or even external code, would communicate with and control the NHI hardware.


97/4 2026/08/10 08:30 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi.h FirstLine:1 LineCount:100]

Results:
map[Contents:   1:	/* SPDX-License-Identifier: GPL-2.0 */
   2:	/*
   3:	 * Thunderbolt driver - NHI driver
   4:	 *
   5:	 * Copyright (c) 2014 Andreas Noever <andreas.noever@gmail.com>
   6:	 * Copyright (C) 2018, Intel Corporation
   7:	 */
   8:	
   9:	#ifndef DSL3510_H_
  10:	#define DSL3510_H_
  11:	
  12:	#include <linux/thunderbolt.h>
  13:	
  14:	enum nhi_fw_mode {
  15:		NHI_FW_SAFE_MODE,
  16:		NHI_FW_AUTH_MODE,
  17:		NHI_FW_EP_MODE,
  18:		NHI_FW_CM_MODE,
  19:	};
  20:	
  21:	enum nhi_mailbox_cmd {
  22:		NHI_MAILBOX_SAVE_DEVS = 0x05,
  23:		NHI_MAILBOX_DISCONNECT_PCIE_PATHS = 0x06,
  24:		NHI_MAILBOX_DRV_UNLOADS = 0x07,
  25:		NHI_MAILBOX_DISCONNECT_PA = 0x10,
  26:		NHI_MAILBOX_DISCONNECT_PB = 0x11,
  27:		NHI_MAILBOX_ALLOW_ALL_DEVS = 0x23,
  28:	};
  29:	
  30:	int nhi_mailbox_cmd(struct tb_nhi *nhi, enum nhi_mailbox_cmd cmd, u32 data);
  31:	enum nhi_fw_mode nhi_mailbox_mode(struct tb_nhi *nhi);
  32:	void nhi_enable_int_throttling(struct tb_nhi *nhi);
  33:	void nhi_disable_interrupts(struct tb_nhi *nhi);
  34:	void nhi_interrupt_work(struct work_struct *work);
  35:	irqreturn_t nhi_msi(int irq, void *data);
  36:	irqreturn_t ring_msix(int irq, void *data);
  37:	int nhi_probe(struct tb_nhi *nhi);
  38:	void nhi_shutdown(struct tb_nhi *nhi);
  39:	extern const struct dev_pm_ops nhi_pm_ops;
  40:	
  41:	/**
  42:	 * struct tb_nhi_ops - NHI specific optional operations
  43:	 * @init: NHI specific initialization
  44:	 * @suspend_noirq: NHI specific suspend_noirq hook
  45:	 * @resume_noirq: NHI specific resume_noirq hook
  46:	 * @runtime_suspend: NHI specific runtime_suspend hook
  47:	 * @runtime_resume: NHI specific runtime_resume hook
  48:	 * @shutdown: NHI specific shutdown
  49:	 * @pre_nvm_auth: hook to run before Thunderbolt 3 NVM authentication
  50:	 * @post_nvm_auth: hook to run after Thunderbolt 3 NVM authentication
  51:	 * @request_ring_irq: NHI specific interrupt retrieval hook
  52:	 * @release_ring_irq: NHI specific interrupt release hook
  53:	 * @is_present: Whether the device is currently present on the parent bus
  54:	 * @init_interrupts: NHI specific interrupt initialization hook
  55:	 */
  56:	struct tb_nhi_ops {
  57:		int (*init)(struct tb_nhi *nhi);
  58:		int (*suspend_noirq)(struct tb_nhi *nhi, bool wakeup);
  59:		int (*resume_noirq)(struct tb_nhi *nhi);
  60:		int (*runtime_suspend)(struct tb_nhi *nhi);
  61:		int (*runtime_resume)(struct tb_nhi *nhi);
  62:		void (*shutdown)(struct tb_nhi *nhi);
  63:		void (*pre_nvm_auth)(struct tb_nhi *nhi);
  64:		void (*post_nvm_auth)(struct tb_nhi *nhi);
  65:		int (*request_ring_irq)(struct tb_ring *ring, bool no_suspend);
  66:		void (*release_ring_irq)(struct tb_ring *ring);
  67:		bool (*is_present)(struct tb_nhi *nhi);
  68:		int (*init_interrupts)(struct tb_nhi *nhi);
  69:	};
  70:	
  71:	/*
  72:	 * PCI IDs used in this driver from Win Ridge forward. There is no
  73:	 * need for the PCI quirk anymore as we will use ICM also on Apple
  74:	 * hardware.
  75:	 */
  76:	#define PCI_DEVICE_ID_INTEL_MAPLE_RIDGE_2C_NHI		0x1134
  77:	#define PCI_DEVICE_ID_INTEL_MAPLE_RIDGE_4C_NHI		0x1137
  78:	#define PCI_DEVICE_ID_INTEL_WIN_RIDGE_2C_NHI            0x157d
  79:	#define PCI_DEVICE_ID_INTEL_WIN_RIDGE_2C_BRIDGE         0x157e
  80:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_NHI		0x15bf
  81:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_BRIDGE	0x15c0
  82:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_4C_NHI	0x15d2
  83:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_4C_BRIDGE	0x15d3
  84:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_2C_NHI	0x15d9
  85:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_2C_BRIDGE	0x15da
  86:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_USBONLY_NHI	0x15dc
  87:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_USBONLY_NHI	0x15dd
  88:	#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_USBONLY_NHI	0x15de
  89:	#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_2C_BRIDGE	0x15e7
  90:	#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_2C_NHI		0x15e8
  91:	#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_4C_BRIDGE	0x15ea
  92:	#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_4C_NHI		0x15eb
  93:	#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_DD_BRIDGE	0x15ef
  94:	#define PCI_DEVICE_ID_INTEL_ADL_NHI0			0x463e
  95:	#define PCI_DEVICE_ID_INTEL_ADL_NHI1			0x466d
  96:	#define PCI_DEVICE_ID_INTEL_WCL_NHI0			0x4d33
  97:	#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_80G_NHI	0x5781
  98:	#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_40G_NHI	0x5784
  99:	#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HUB_80G_BRIDGE 0x5786
 100:	#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HUB_40G_BRIDGE 0x57a4
]

98/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 26671
							output: 37
							thoughts: 18
						

Thoughts:
**My Thought Process Regarding `drivers/thunderbolt/nhi.h`**

Alright, so after digging into the broader Thunderbolt driver architecture, I've now arrived at the point where I need to understand the specifics of the NHI (Native Host Interface) layer. My immediate inclination is to dive into `drivers/thunderbolt/nhi.h`. I expect this header file to be the lynchpin for understanding how the higher-level Thunderbolt protocol interacts with the underlying hardware controller.

My objective here is to meticulously dissect what `nhi.h` exposes and defines. I'll be looking for key data structures that represent the NHI's internal state and the hardware itself. I'm particularly interested in the API – the functions, macros, and constants that the rest of the Thunderbolt driver stack will use to communicate with the NHI. This is where the abstraction happens; I need to grasp how the complex world of Thunderbolt operations (like tunneling, link management, and device enumeration) is translated into concrete commands and data exchanges through this interface.

Furthermore, I'll be scrutinizing the definitions related to error handling and status reporting. How does the NHI signal events, failures, or successful operations back to the driver? Understanding these mechanisms is crucial for building a robust and reliable Thunderbolt subsystem. I anticipate seeing definitions for various states, capabilities, and perhaps even specific register layouts or memory-mapped I/O regions that the driver will need to manipulate. Essentially, this header file should serve as the blueprint for interacting with the NHI component of the Thunderbolt controller. It's the contract between the software driver and the hardware's native interface, and comprehending it is paramount to understanding how Thunderbolt is managed at this fundamental level.


99/4 2026/08/10 08:30 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi.h FirstLine:101 LineCount:50]

Results:
map[Contents: 101:	#define PCI_DEVICE_ID_INTEL_MTL_M_NHI0			0x7eb2
 102:	#define PCI_DEVICE_ID_INTEL_MTL_P_NHI0			0x7ec2
 103:	#define PCI_DEVICE_ID_INTEL_MTL_P_NHI1			0x7ec3
 104:	#define PCI_DEVICE_ID_INTEL_ICL_NHI1			0x8a0d
 105:	#define PCI_DEVICE_ID_INTEL_ICL_NHI0			0x8a17
 106:	#define PCI_DEVICE_ID_INTEL_TGL_NHI0			0x9a1b
 107:	#define PCI_DEVICE_ID_INTEL_TGL_NHI1			0x9a1d
 108:	#define PCI_DEVICE_ID_INTEL_TGL_H_NHI0			0x9a1f
 109:	#define PCI_DEVICE_ID_INTEL_TGL_H_NHI1			0x9a21
 110:	#define PCI_DEVICE_ID_INTEL_RPL_NHI0			0xa73e
 111:	#define PCI_DEVICE_ID_INTEL_RPL_NHI1			0xa76d
 112:	#define PCI_DEVICE_ID_INTEL_LNL_NHI0			0xa833
 113:	#define PCI_DEVICE_ID_INTEL_LNL_NHI1			0xa834
 114:	#define PCI_DEVICE_ID_INTEL_PTL_M_NHI0			0xe333
 115:	#define PCI_DEVICE_ID_INTEL_PTL_M_NHI1			0xe334
 116:	#define PCI_DEVICE_ID_INTEL_PTL_P_NHI0			0xe433
 117:	#define PCI_DEVICE_ID_INTEL_PTL_P_NHI1			0xe434
 118:	
 119:	#define PCI_CLASS_SERIAL_USB_USB4			0x0c0340
 120:	
 121:	/* Host interface quirks */
 122:	#define QUIRK_AUTO_CLEAR_INT	BIT(0)
 123:	#define QUIRK_E2E		BIT(1)
 124:	
 125:	/*
 126:	 * Minimal number of vectors when we use MSI-X. Two for control channel
 127:	 * Rx/Tx and the rest four are for cross domain DMA paths.
 128:	 */
 129:	#define MSIX_MIN_VECS		6
 130:	#define MSIX_MAX_VECS		16
 131:	
 132:	#endif
]

100/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 27476
							output: 30
							thoughts: 68
						

Thoughts:
**My Internal Monologue:**

Okay, so I've been examining the Thunderbolt driver, specifically looking at NHI operations. My immediate thought is to ensure I have a complete picture of how these operations are handled. It's not enough to just look at one file; I need to be absolutely certain I'm not missing any crucial implementations or related components. Therefore, my next step is to systematically search the `drivers/thunderbolt/` directory for any other files that might be involved. My primary search terms will be `struct tb_nhi_ops` and the more general `nhi_ops`. This way, I can identify any other structures or functions that define or utilize NHI operations, giving me a comprehensive understanding of the NHI driver's architecture and how it's integrated within the broader Thunderbolt subsystem.


101/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:tb_nhi_ops PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/nhi.h=39=extern const struct dev_pm_ops nhi_pm_ops;
--
drivers/thunderbolt/nhi.h-41-/**
drivers/thunderbolt/nhi.h:42: * struct tb_nhi_ops - NHI specific optional operations
drivers/thunderbolt/nhi.h-43- * @init: NHI specific initialization
--
drivers/thunderbolt/nhi.h-55- */
drivers/thunderbolt/nhi.h:56:struct tb_nhi_ops {
drivers/thunderbolt/nhi.h-57-	int (*init)(struct tb_nhi *nhi);
--
drivers/thunderbolt/pci.c=249=static bool nhi_pci_is_present(struct tb_nhi *nhi)
--
drivers/thunderbolt/pci.c-253-
drivers/thunderbolt/pci.c:254:static const struct tb_nhi_ops pci_nhi_default_ops = {
drivers/thunderbolt/pci.c-255-	.pre_nvm_auth = nhi_pci_start_dma_port,
--
drivers/thunderbolt/pci.c=425=static void icl_nhi_shutdown(struct tb_nhi *nhi)
--
drivers/thunderbolt/pci.c-431-
drivers/thunderbolt/pci.c:432:static const struct tb_nhi_ops icl_nhi_ops = {
drivers/thunderbolt/pci.c-433-	.init = icl_nhi_resume,
--
drivers/thunderbolt/pci.c=447=static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
--
drivers/thunderbolt/pci.c-466-	nhi->dev = dev;
drivers/thunderbolt/pci.c:467:	nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
drivers/thunderbolt/pci.c-468-
]

102/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 28104
							output: 43
							thoughts: 121
						

Thoughts:
**My Thought Process on Exploring Thunderbolt PCI Driver Register Access**

My immediate impulse upon encountering `drivers/thunderbolt/pci.c` and noting the presence of `pci_nhi_default_ops` and `icl_nhi_ops` is to delve into the specifics of how these operations interact with the hardware. As an expert in this domain, I understand that the true essence of driver functionality often lies in the direct manipulation of hardware registers. Therefore, my primary objective becomes uncovering any register read or write operations within this particular file. I'm particularly keen to identify *which* registers are being accessed and their precise memory-mapped offsets. To efficiently achieve this, I'll leverage a powerful searching tool like `grepper`. My search query will specifically target patterns indicative of register access: `ioread`, `iowrite`, `readl`, `writel`, and any explicit register offset values. This targeted approach will allow me to quickly pinpoint the critical low-level interactions within the Thunderbolt PCI driver.


103/4 2026/08/10 08:30 tool grepper
0m Error:
log-in to see details

Args:
map[Expression:(readl|writel|ioread|iowrite) PathPrefix:drivers/thunderbolt/pci.c]

Results:
map[Output:]

104/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 28266
							output: 37
							thoughts: 125
						

Thoughts:
**My Investigation into Thunderbolt PCI Register Access**

My initial scan for specific I/O access functions like `readl`, `writel`, `ioread`, and `iowrite` within `drivers/thunderbolt/pci.c` yielded no results. This immediately raised a question in my mind: how is register access actually being performed in this critical driver file? My next step was to broaden my search, specifically looking for the more generic PCI configuration space access mechanisms. I hypothesized that it was likely using the standard `pci_read_config` and `pci_write_config` functions, or their variants like `pci_read_config_dword`. Therefore, I decided to search `drivers/thunderbolt/pci.c` for these common PCI configuration access patterns to understand the underlying register manipulation.


105/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:pci_(read|write)_config PathPrefix:drivers/thunderbolt/pci.c]

Results:
map[Output:drivers/thunderbolt/pci.c=283=static int icl_nhi_force_power(struct tb_nhi *nhi, bool power)
--
drivers/thunderbolt/pci.c-299-	 */
drivers/thunderbolt/pci.c:300:	pci_read_config_dword(pdev, VS_CAP_22, &vs_cap);
drivers/thunderbolt/pci.c-301-	if (power) {
--
drivers/thunderbolt/pci.c-307-	}
drivers/thunderbolt/pci.c:308:	pci_write_config_dword(pdev, VS_CAP_22, vs_cap);
drivers/thunderbolt/pci.c-309-
--
drivers/thunderbolt/pci.c-315-		do {
drivers/thunderbolt/pci.c:316:			pci_read_config_dword(pdev, VS_CAP_9, &val);
drivers/thunderbolt/pci.c-317-			if (val & VS_CAP_9_FW_READY)
--
drivers/thunderbolt/pci.c=328=static void icl_nhi_lc_mailbox_cmd(struct tb_nhi *nhi, enum icl_lc_mailbox_cmd cmd)
--
drivers/thunderbolt/pci.c-333-	data = (cmd << VS_CAP_19_CMD_SHIFT) & VS_CAP_19_CMD_MASK;
drivers/thunderbolt/pci.c:334:	pci_write_config_dword(pdev, VS_CAP_19, data | VS_CAP_19_VALID);
drivers/thunderbolt/pci.c-335-}
--
drivers/thunderbolt/pci.c=337=static int icl_nhi_lc_mailbox_cmd_complete(struct tb_nhi *nhi, int timeout)
--
drivers/thunderbolt/pci.c-347-	do {
drivers/thunderbolt/pci.c:348:		pci_read_config_dword(pdev, VS_CAP_18, &data);
drivers/thunderbolt/pci.c-349-		if (data & VS_CAP_18_DONE)
--
drivers/thunderbolt/pci.c-357-	/* Clear the valid bit */
drivers/thunderbolt/pci.c:358:	pci_write_config_dword(pdev, VS_CAP_19, 0);
drivers/thunderbolt/pci.c-359-	return 0;
--
drivers/thunderbolt/pci.c=362=static void icl_nhi_set_ltr(struct tb_nhi *nhi)
--
drivers/thunderbolt/pci.c-366-
drivers/thunderbolt/pci.c:367:	pci_read_config_dword(pdev, VS_CAP_16, &max_ltr);
drivers/thunderbolt/pci.c-368-	max_ltr &= 0xffff;
--
drivers/thunderbolt/pci.c-370-	ltr = max_ltr << 16 | max_ltr;
drivers/thunderbolt/pci.c:371:	pci_write_config_dword(pdev, VS_CAP_15, ltr);
drivers/thunderbolt/pci.c-372-}
]

106/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 29279
							output: 31
							thoughts: 497
						

Thoughts:
**My Thought Process Regarding Thunderbolt NIC Register Access**

Initially, my attention was drawn to a set of registers I recognized as being part of the PCI configuration space. I know these are typically accessed using functions like `pci_read_config_dword` and `pci_write_config_dword`. I quickly noted down the specific offsets: `VS_CAP_22` at `0xfc`, `VS_CAP_9` at `0xc8`, `VS_CAP_19` at `0xf0`, `VS_CAP_18` at `0xec`, `VS_CAP_16` at `0xe4`, and `VS_CAP_15` at `0xe0`. It's significant to me that all these fall within the standard PCI configuration space, which is a relatively small address range and notably smaller than `0x39640`.

This led me to question whether there were *other* registers or files within the Thunderbolt NIC driver that might be involved in register access. My next step was to revisit `drivers/thunderbolt/nhi_regs.h`. I specifically wanted to examine registers defined there that had offsets *greater* than `0x39640`, which I identified as `REG_CAPS`. The ones that stood out were: `REG_DMA_MISC` at `0x39864`, `REG_RESET` at `0x39898`, `REG_INMAIL_DATA` at `0x39900`, `REG_INMAIL_CMD` at `0x39904`, `REG_OUTMAIL_CMD` at `0x3990c`, and `REG_FW_STS` at `0x39944`.

My investigation didn't stop there. I continued to ponder if there were *any* other registers accessed by the Thunderbolt NIC driver beyond those already examined. This prompted me to broaden my scope and look for other files within the `drivers/thunderbolt/` directory that might be involved in register access. My focus then shifted to `drivers/thunderbolt/icm.c`. I recalled seeing this file interact with `REG_FW_STS` (which is at `0x39944`). To deepen my understanding, I decided to thoroughly check `icm.c` for any *other* registers it might be accessing. As a practical approach, I decided to search for patterns like `nhi->iobase` or simply `iobase` within `drivers/thunderbolt/icm.c` to uncover potential register accesses.


107/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:iobase PathPrefix:drivers/thunderbolt/icm.c]

Results:
map[Output:drivers/thunderbolt/icm.c=375=static bool icm_firmware_running(const struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-378-
drivers/thunderbolt/icm.c:379:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-380-	return !!(val & REG_FW_STS_ICM_EN);
--
drivers/thunderbolt/icm.c=1509=static int icm_ar_get_mode(struct tb *tb)
--
drivers/thunderbolt/icm.c-1515-	do {
drivers/thunderbolt/icm.c:1516:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1517-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1719=static bool icm_tgl_is_supported(struct tb *tb)
--
drivers/thunderbolt/icm.c-1725-
drivers/thunderbolt/icm.c:1726:		val = ioread32(tb->nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1727-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1837=static int icm_firmware_reset(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1845-	/* Put ARC to wait for CIO reset event to happen */
drivers/thunderbolt/icm.c:1846:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1847-	val |= REG_FW_STS_CIO_RESET_REQ;
drivers/thunderbolt/icm.c:1848:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1849-
drivers/thunderbolt/icm.c-1850-	/* Re-start ARC */
drivers/thunderbolt/icm.c:1851:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1852-	val |= REG_FW_STS_ICM_EN_INVERT;
drivers/thunderbolt/icm.c-1853-	val |= REG_FW_STS_ICM_EN_CPU;
drivers/thunderbolt/icm.c:1854:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1855-
--
drivers/thunderbolt/icm.c=1860=static int icm_firmware_start(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1878-		/* Check that the ICM firmware is running */
drivers/thunderbolt/icm.c:1879:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1880-		if (val & REG_FW_STS_NVM_AUTH_DONE)
]

108/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 30686
							output: 26
							thoughts: 62
						

Thoughts:
**My Thought Process on Thunderbolt Register Access**

Alright, so I've just confirmed that `icm.c` is exclusively interacting with `REG_FW_STS`, which corresponds to memory address `0x39944`. This is a very specific and narrow observation. My next logical step, given this focused finding, is to broaden my search within the immediate vicinity of this code. I need to determine if this isolated access to `REG_FW_STS` is a solitary event, or if it's part of a larger pattern of register manipulation within the `drivers/thunderbolt/` directory. To do this, I'm going to systematically examine all other files within that directory, specifically looking for any instances where `nhi->iobase` or the standalone `iobase` variable is being accessed. This will tell me if the Thunderbolt driver as a whole uses a more generalized approach to I/O base addressing, or if `REG_FW_STS` is indeed accessed in a unique manner by `icm.c`.


109/4 2026/08/10 08:30 tool grepper
0m Args:
map[Expression:iobase PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/icm.c=375=static bool icm_firmware_running(const struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-378-
drivers/thunderbolt/icm.c:379:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-380-	return !!(val & REG_FW_STS_ICM_EN);
--
drivers/thunderbolt/icm.c=1509=static int icm_ar_get_mode(struct tb *tb)
--
drivers/thunderbolt/icm.c-1515-	do {
drivers/thunderbolt/icm.c:1516:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1517-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1719=static bool icm_tgl_is_supported(struct tb *tb)
--
drivers/thunderbolt/icm.c-1725-
drivers/thunderbolt/icm.c:1726:		val = ioread32(tb->nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1727-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/icm.c=1837=static int icm_firmware_reset(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1845-	/* Put ARC to wait for CIO reset event to happen */
drivers/thunderbolt/icm.c:1846:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1847-	val |= REG_FW_STS_CIO_RESET_REQ;
drivers/thunderbolt/icm.c:1848:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1849-
drivers/thunderbolt/icm.c-1850-	/* Re-start ARC */
drivers/thunderbolt/icm.c:1851:	val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1852-	val |= REG_FW_STS_ICM_EN_INVERT;
drivers/thunderbolt/icm.c-1853-	val |= REG_FW_STS_ICM_EN_CPU;
drivers/thunderbolt/icm.c:1854:	iowrite32(val, nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1855-
--
drivers/thunderbolt/icm.c=1860=static int icm_firmware_start(struct tb *tb, struct tb_nhi *nhi)
--
drivers/thunderbolt/icm.c-1878-		/* Check that the ICM firmware is running */
drivers/thunderbolt/icm.c:1879:		val = ioread32(nhi->iobase + REG_FW_STS);
drivers/thunderbolt/icm.c-1880-		if (val & REG_FW_STS_NVM_AUTH_DONE)
--
drivers/thunderbolt/nhi.c=51=static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
--
drivers/thunderbolt/nhi.c-55-
drivers/thunderbolt/nhi.c:56:		val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
drivers/thunderbolt/nhi.c:57:		iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
drivers/thunderbolt/nhi.c-58-	} else {
drivers/thunderbolt/nhi.c:59:		iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
drivers/thunderbolt/nhi.c-60-	}
--
drivers/thunderbolt/nhi.c=63=static void nhi_clear_interrupt(struct tb_nhi *nhi, int ring)
--
drivers/thunderbolt/nhi.c-65-	if (nhi->quirks & QUIRK_AUTO_CLEAR_INT)
drivers/thunderbolt/nhi.c:66:		ioread32(nhi->iobase + REG_RING_NOTIFY_BASE + ring);
drivers/thunderbolt/nhi.c-67-	else
drivers/thunderbolt/nhi.c:68:		iowrite32(~0, nhi->iobase + REG_RING_INT_CLEAR + ring);
drivers/thunderbolt/nhi.c-69-}
--
drivers/thunderbolt/nhi.c=76=static void ring_interrupt_active(struct tb_ring *ring, bool active)
--
drivers/thunderbolt/nhi.c-105-		 */
drivers/thunderbolt/nhi.c:106:		misc = ioread32(ring->nhi->iobase + REG_DMA_MISC);
drivers/thunderbolt/nhi.c-107-		if (ring->nhi->quirks & QUIRK_AUTO_CLEAR_INT)
--
drivers/thunderbolt/nhi.c-112-			iowrite32(misc | auto_clear_bit,
drivers/thunderbolt/nhi.c:113:				  ring->nhi->iobase + REG_DMA_MISC);
drivers/thunderbolt/nhi.c-114-
drivers/thunderbolt/nhi.c:115:		ivr_base = ring->nhi->iobase + REG_INT_VEC_ALLOC_BASE;
drivers/thunderbolt/nhi.c-116-		step = index / REG_INT_VEC_ALLOC_REGS * REG_INT_VEC_ALLOC_BITS;
--
drivers/thunderbolt/nhi.c-126-		itr &= REG_INT_THROTTLING_RATE_INTERVAL_MASK;
drivers/thunderbolt/nhi.c:127:		iowrite32(itr, ring->nhi->iobase + REG_INT_THROTTLING_RATE +
drivers/thunderbolt/nhi.c-128-			  ring->vector * 4);
--
drivers/thunderbolt/nhi.c-130-
drivers/thunderbolt/nhi.c:131:	old = ioread32(ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-132-	if (active)
--
drivers/thunderbolt/nhi.c-146-	if (active)
drivers/thunderbolt/nhi.c:147:		iowrite32(new, ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-148-	else
--
drivers/thunderbolt/nhi.c=171=static void __iomem *ring_desc_base(struct tb_ring *ring)
drivers/thunderbolt/nhi.c-172-{
drivers/thunderbolt/nhi.c:173:	void __iomem *io = ring->nhi->iobase;
drivers/thunderbolt/nhi.c-174-	io += ring->is_tx ? REG_TX_RING_BASE : REG_RX_RING_BASE;
--
drivers/thunderbolt/nhi.c=179=static void __iomem *ring_options_base(struct tb_ring *ring)
drivers/thunderbolt/nhi.c-180-{
drivers/thunderbolt/nhi.c:181:	void __iomem *io = ring->nhi->iobase;
drivers/thunderbolt/nhi.c-182-	io += ring->is_tx ? REG_TX_OPTIONS_BASE : REG_RX_OPTIONS_BASE;
--
drivers/thunderbolt/nhi.c=380=static void __ring_interrupt_mask(struct tb_ring *ring, bool mask)
--
drivers/thunderbolt/nhi.c-386-
drivers/thunderbolt/nhi.c:387:	val = ioread32(ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-388-	if (mask)
--
drivers/thunderbolt/nhi.c-391-		val |= BIT(bit);
drivers/thunderbolt/nhi.c:392:	iowrite32(val, ring->nhi->iobase + reg);
drivers/thunderbolt/nhi.c-393-}
--
drivers/thunderbolt/nhi.c=429=static void ring_clear_msix(const struct tb_ring *ring)
--
drivers/thunderbolt/nhi.c-437-	if (ring->is_tx)
drivers/thunderbolt/nhi.c:438:		iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR);
drivers/thunderbolt/nhi.c-439-	else
drivers/thunderbolt/nhi.c:440:		iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR +
drivers/thunderbolt/nhi.c-441-			  4 * (ring->nhi->hop_count / 32));
--
drivers/thunderbolt/nhi.c=870=int nhi_mailbox_cmd(struct tb_nhi *nhi, enum nhi_mailbox_cmd cmd, u32 data)
--
drivers/thunderbolt/nhi.c-874-
drivers/thunderbolt/nhi.c:875:	iowrite32(data, nhi->iobase + REG_INMAIL_DATA);
drivers/thunderbolt/nhi.c-876-
drivers/thunderbolt/nhi.c:877:	val = ioread32(nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-878-	val &= ~(REG_INMAIL_CMD_MASK | REG_INMAIL_ERROR);
drivers/thunderbolt/nhi.c-879-	val |= REG_INMAIL_OP_REQUEST | cmd;
drivers/thunderbolt/nhi.c:880:	iowrite32(val, nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-881-
--
drivers/thunderbolt/nhi.c-883-	do {
drivers/thunderbolt/nhi.c:884:		val = ioread32(nhi->iobase + REG_INMAIL_CMD);
drivers/thunderbolt/nhi.c-885-		if (!(val & REG_INMAIL_OP_REQUEST))
--
drivers/thunderbolt/nhi.c=907=enum nhi_fw_mode nhi_mailbox_mode(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-910-
drivers/thunderbolt/nhi.c:911:	val = ioread32(nhi->iobase + REG_OUTMAIL_CMD);
drivers/thunderbolt/nhi.c-912-	val &= REG_OUTMAIL_CMD_OPMODE_MASK;
--
drivers/thunderbolt/nhi.c=918=void nhi_interrupt_work(struct work_struct *work)
--
drivers/thunderbolt/nhi.c-935-		if (bit % 32 == 0)
drivers/thunderbolt/nhi.c:936:			value = ioread32(nhi->iobase
drivers/thunderbolt/nhi.c-937-					 + REG_RING_NOTIFY_BASE
--
drivers/thunderbolt/nhi.c=1132=static void nhi_reset(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-1136-
drivers/thunderbolt/nhi.c:1137:	val = ioread32(nhi->iobase + REG_CAPS);
drivers/thunderbolt/nhi.c-1138-	/* Reset only v2 and later routers */
--
drivers/thunderbolt/nhi.c-1146-
drivers/thunderbolt/nhi.c:1147:	iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
drivers/thunderbolt/nhi.c-1148-	msleep(100);
--
drivers/thunderbolt/nhi.c-1151-	do {
drivers/thunderbolt/nhi.c:1152:		val = ioread32(nhi->iobase + REG_RESET);
drivers/thunderbolt/nhi.c-1153-		if (!(val & REG_RESET_HRR)) {
--
drivers/thunderbolt/nhi.c=1186=int nhi_probe(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-1197-
drivers/thunderbolt/nhi.c:1198:	nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
drivers/thunderbolt/nhi.c-1199-	dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
--
drivers/thunderbolt/pci.c=447=static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
--
drivers/thunderbolt/pci.c-468-
drivers/thunderbolt/pci.c:469:	nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
drivers/thunderbolt/pci.c:470:	res = PTR_ERR_OR_ZERO(nhi->iobase);
drivers/thunderbolt/pci.c-471-	if (res)
]

110/4 2026/08/10 08:30 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 34362
							output: 45
							thoughts: 1550
						

Thoughts:
**My Thought Process Regarding `nhi->iobase` Register Access**

This is all exceptionally clear and precise, which is a great starting point. My primary focus has been on understanding the exact usage of `nhi->iobase`, and I've confirmed that access is strictly confined to two files: `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/icm.c`.

To thoroughly map this out, I've meticulously listed every register accessed through `nhi->iobase`, along with their specific offsets. This list includes:

1.  `REG_TX_RING_BASE` at `0x00000` (accessed via `ring_desc_base`)
2.  `REG_RX_RING_BASE` at `0x08000` (accessed via `ring_desc_base`)
3.  `REG_TX_OPTIONS_BASE` at `0x19800` (accessed via `ring_options_base`)
4.  `REG_RX_OPTIONS_BASE` at `0x29800` (accessed via `ring_options_base`)
5.  `REG_RING_NOTIFY_BASE` at `0x37800` (accessed via `nhi_clear_interrupt` and `nhi_interrupt_work`)
6.  `REG_RING_INT_CLEAR` at `0x37808` (accessed via `nhi_clear_interrupt` and `ring_clear_msix`)
7.  `REG_RING_INTERRUPT_BASE` at `0x38200` (accessed via `nhi_mask_interrupt` and `ring_interrupt_active`)
8.  `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at `0x38208` (accessed via `nhi_mask_interrupt` and `ring_interrupt_active`)
9.  `REG_INT_THROTTLING_RATE` at `0x38c00` (accessed via `ring_interrupt_active`)
10. `REG_INT_VEC_ALLOC_BASE` at `0x38c40` (accessed via `ring_interrupt_active`)
11. `REG_CAPS` at `0x39640` (accessed via `nhi_reset` and `nhi_probe`)
12. `REG_DMA_MISC` at `0x39864` (accessed via `ring_interrupt_active`)
13. `REG_RESET` at `0x39898` (accessed via `nhi_reset`)
14. `REG_INMAIL_DATA` at `0x39900` (accessed via `nhi_mailbox_cmd`)
15. `REG_INMAIL_CMD` at `0x39904` (accessed via `nhi_mailbox_cmd`)
16. `REG_OUTMAIL_CMD` at `0x3990c` (accessed via `nhi_mailbox_mode`)
17. `REG_FW_STS` at `0x39944` (accessed via `icm_firmware_running`, `icm_ar_get_mode`, `icm_tgl_is_supported`, `icm_firmware_reset`, `icm_firmware_start`)

My next step was to ensure completeness. I revisited `nhi_regs.h` to confirm that the defined registers perfectly matched my findings and that no other relevant definitions were present. This verification was positive; the defines in the header are exactly what I've documented.

I also specifically noted the registers with offsets higher than `REG_CAPS` (`0x39640`), which are `REG_DMA_MISC`, `REG_RESET`, `REG_INMAIL_DATA`, `REG_INMAIL_CMD`, `REG_OUTMAIL_CMD`, and `REG_FW_STS`.

To be absolutely certain no stone was left unturned within the `drivers/thunderbolt/` directory, I performed a comprehensive search for any other files that might define or access registers. This involved a targeted `grep` for hexadecimal patterns. Specifically, a search for `0x39[0-9a-fA-F]+` yielded the list of registers starting with `0x39` that I've already captured.

However, I'm not entirely satisfied with just that. To be exhaustive, I'm now considering if there are any registers with offsets in the `0x3a`, `0x3b`, `0x3c` ranges, or even higher. This prompts a further, broader search using `0x3[a-fA-F][0-9a-fA-F]+` across the entire `drivers/thunderbolt/` directory. This is my current point of focus for ensuring absolute completeness.


111/4 2026/08/10 08:31 tool grepper
0m Args:
map[Expression:0x3[a-fA-F][0-9a-fA-F]+ PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/dma_port.h=16=struct tb_dma_port;
drivers/thunderbolt/dma_port.h-17-
drivers/thunderbolt/dma_port.h:18:#define DMA_PORT_CSS_ADDRESS		0x3fffff
drivers/thunderbolt/dma_port.h-19-#define DMA_PORT_CSS_MAX_SIZE		SZ_128
--
drivers/thunderbolt/eeprom.c=557=static int tb_drom_bit_bang(struct tb_switch *sw, u16 *size)
--
drivers/thunderbolt/eeprom.c-564-
drivers/thunderbolt/eeprom.c:565:	*size &= 0x3ff;
drivers/thunderbolt/eeprom.c-566-	*size += TB_DROM_DATA_START;
--
drivers/thunderbolt/nhi.c=1186=int nhi_probe(struct tb_nhi *nhi)
--
drivers/thunderbolt/nhi.c-1197-
drivers/thunderbolt/nhi.c:1198:	nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
drivers/thunderbolt/nhi.c-1199-	dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
--
drivers/thunderbolt/stream.c=206=static const uuid_t tbstream_dir_uuid =
drivers/thunderbolt/stream.c:207:	UUID_INIT(0x3a1cb984, 0xc4d9, 0x4469,
drivers/thunderbolt/stream.c-208-		  0xa2, 0x77, 0xce, 0x2f, 0xdf, 0xd1, 0x1f, 0x0d);
]

112/4 2026/08/10 08:31 llm codeexpert
1m Model:
gemini-3.5-flash

Tokens:
							input: 36433
							output: 25
							thoughts: 73
						

Thoughts:
**My Thought Process on `DMA_PORT_CSS_ADDRESS`**

My initial thought upon seeing `DMA_PORT_CSS_ADDRESS` with a value of `0x3fffff` is to immediately question its relevance to the NHI driver. This is a crucial step for me as an expert; I need to establish the functional connection. My immediate next action, therefore, is to investigate the definition and usage of `DMA_PORT_CSS_ADDRESS`. I want to understand precisely what this address represents and, more importantly, where it's being referenced within the codebase. To do this systematically, I'll be performing a targeted search, specifically within the `drivers/thunderbolt/` directory. This focused search allows me to efficiently pinpoint any interactions or dependencies the NHI driver might have with this particular DMA port address.


113/4 2026/08/10 08:32 tool codesearch-find-references
0m Error:
log-in to see details

Args:
map[Name:DMA_PORT_CSS_ADDRESS]

Results:
map[References:<nil> TruncatedOutput:false]

114/4 2026/08/10 08:32 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 36540
							output: 31
							thoughts: 21
						

Thoughts:
**My Thought Process**

Right, so the first thing that comes to my mind when I see this is, "How can I efficiently pinpoint all occurrences of this specific constant, `DMA_PORT_CSS_ADDRESS`?" I need to search through the codebase, and for this kind of targeted string search, my go-to tool is `grepper`. It's exceptionally good at quickly scanning files and directories for exact patterns. So, I'll be invoking `grepper` with the intention of finding every single line where `DMA_PORT_CSS_ADDRESS` appears. This will give me a comprehensive overview of where this particular memory-mapped register or configuration parameter is being referenced, which is crucial for understanding its usage, potential dependencies, and any side effects that might arise from modifications.


115/4 2026/08/10 08:32 tool grepper
0m Args:
map[Expression:DMA_PORT_CSS_ADDRESS PathPrefix:drivers/thunderbolt]

Results:
map[Output:drivers/thunderbolt/dma_port.c=317=static int dma_port_flash_write_block(void *data, unsigned int dwaddress,
--
drivers/thunderbolt/dma_port.c-333-	/* CSS header write is always done to the same magic address */
drivers/thunderbolt/dma_port.c:334:	if (dwaddress >= DMA_PORT_CSS_ADDRESS)
drivers/thunderbolt/dma_port.c-335-		in |= MAIL_IN_CSS;
--
drivers/thunderbolt/dma_port.c=353=int dma_port_flash_read(struct tb_dma_port *dma, unsigned int address,
--
drivers/thunderbolt/dma_port.c-367- * Writes block of data to the non-active flash region of the switch. If
drivers/thunderbolt/dma_port.c:368: * the address is given as %DMA_PORT_CSS_ADDRESS the block is written
drivers/thunderbolt/dma_port.c-369- * using CSS command.
--
drivers/thunderbolt/dma_port.c=373=int dma_port_flash_write(struct tb_dma_port *dma, unsigned int address,
--
drivers/thunderbolt/dma_port.c-375-{
drivers/thunderbolt/dma_port.c:376:	if (address >= DMA_PORT_CSS_ADDRESS && size > DMA_PORT_CSS_MAX_SIZE)
drivers/thunderbolt/dma_port.c-377-		return -E2BIG;
--
drivers/thunderbolt/dma_port.h=16=struct tb_dma_port;
drivers/thunderbolt/dma_port.h-17-
drivers/thunderbolt/dma_port.h:18:#define DMA_PORT_CSS_ADDRESS		0x3fffff
drivers/thunderbolt/dma_port.h-19-#define DMA_PORT_CSS_MAX_SIZE		SZ_128
--
drivers/thunderbolt/nvm.c=136=static int intel_switch_nvm_write_headers(struct tb_nvm *nvm)
--
drivers/thunderbolt/nvm.c-144-		ret = dma_port_flash_write(sw->dma_port,
drivers/thunderbolt/nvm.c:145:			DMA_PORT_CSS_ADDRESS, nvm->buf + INTEL_NVM_CSS,
drivers/thunderbolt/nvm.c-146-			DMA_PORT_CSS_MAX_SIZE);
]

116/4 2026/08/10 08:32 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 37225
							output: 31
							thoughts: 243
						

Thoughts:
**My Thought Process Regarding Thunderbolt NHI Register Offsets**

My initial realization was about the nature of `DMA_PORT_CSS_ADDRESS`. I've concluded that this isn't a register offset that the NHI driver would typically access. Instead, it serves as a flash address, specifically a double-word address, intended for writing to switch NVM flash via the DMA port. This distinction is crucial – it's not a memory-mapped register address in the conventional sense for the NHI driver.

Following this clarification, my immediate next step was to be more systematic about identifying potential register offsets. I wanted to ensure I hadn't overlooked any significant hex numbers that *could* represent register addresses, especially those larger than the `0x39640` value we've been discussing. To achieve this, I decided to perform targeted searches. My strategy was to look for hexadecimal numbers exceeding `0x39640`. I formulated search patterns like `0x[4-9a-fA-F][0-9a-fA-F]{4}` (for 5-digit hex numbers starting from 4 upwards) and `0x[1-9a-fA-F][0-9a-fA-F]{5}` (for 6-digit hex numbers). I planned to apply these patterns specifically within the `drivers/thunderbolt/nhi_regs.h` and `drivers/thunderbolt/nhi.c` files.

To broaden my initial search and get a comprehensive view of all hexadecimal values present, I also decided to simply search for `0x` within `drivers/thunderbolt/nhi_regs.h`. This would give me a complete list of all defined hex constants, allowing me to manually review them and ensure none were misidentified as register offsets.

However, I then remembered that I had already thoroughly reviewed `nhi_regs.h` in its entirety. This means the manual inspection approach for that file has already been completed, and I should have a firm understanding of its contents.

Given that `nhi_regs.h` has been covered, my focus shifted to `nhi.c`. I needed to double-check if there were any register offsets defined directly within the C source file, rather than solely in the header. My approach for this was to use `grep` to search for `#define` directives within `drivers/thunderbolt/nhi.c`. This would effectively list all macro definitions, and I could then examine any hex values associated with them to confirm if they represent register offsets.


117/4 2026/08/10 08:32 tool grepper
0m Args:
map[Expression:#define PathPrefix:drivers/thunderbolt/nhi.c]

Results:
map[Output:drivers/thunderbolt/nhi.c-27-
drivers/thunderbolt/nhi.c:28:#define RING_TYPE(ring) ((ring)->is_tx ? "TX ring" : "RX ring")
drivers/thunderbolt/nhi.c-29-
drivers/thunderbolt/nhi.c:30:#define RING_FIRST_USABLE_HOPID	1
drivers/thunderbolt/nhi.c-31-/*
--
drivers/thunderbolt/nhi.c-34- */
drivers/thunderbolt/nhi.c:35:#define RING_E2E_RESERVED_HOPID	RING_FIRST_USABLE_HOPID
drivers/thunderbolt/nhi.c-36-
drivers/thunderbolt/nhi.c:37:#define NHI_MAILBOX_TIMEOUT	500 /* ms */
drivers/thunderbolt/nhi.c-38-
]

118/4 2026/08/10 08:32 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 37712
							output: 31
							thoughts: 43
						

Thoughts:
**My Thought Process on Unidentified Register Offsets**

I've just been looking at `nhi.c` and it's struck me that there are no other register offsets defined there. This feels like an oversight, or perhaps an indication that these offsets are managed elsewhere. My immediate next step is to investigate `nhi.h`. I need to perform a thorough search within that header file for any `#define` directives that might be specifying these register offsets. I'll use `grep` for this to ensure I don't miss anything within `drivers/thunderbolt/nhi.h`.


119/4 2026/08/10 08:32 tool grepper
0m Args:
map[Expression:#define PathPrefix:drivers/thunderbolt/nhi.h]

Results:
map[Output:drivers/thunderbolt/nhi.h-9-#ifndef DSL3510_H_
drivers/thunderbolt/nhi.h:10:#define DSL3510_H_
drivers/thunderbolt/nhi.h-11-
--
drivers/thunderbolt/nhi.h=56=struct tb_nhi_ops {
--
drivers/thunderbolt/nhi.h-75- */
drivers/thunderbolt/nhi.h:76:#define PCI_DEVICE_ID_INTEL_MAPLE_RIDGE_2C_NHI		0x1134
drivers/thunderbolt/nhi.h:77:#define PCI_DEVICE_ID_INTEL_MAPLE_RIDGE_4C_NHI		0x1137
drivers/thunderbolt/nhi.h:78:#define PCI_DEVICE_ID_INTEL_WIN_RIDGE_2C_NHI            0x157d
drivers/thunderbolt/nhi.h:79:#define PCI_DEVICE_ID_INTEL_WIN_RIDGE_2C_BRIDGE         0x157e
drivers/thunderbolt/nhi.h:80:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_NHI		0x15bf
drivers/thunderbolt/nhi.h:81:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_BRIDGE	0x15c0
drivers/thunderbolt/nhi.h:82:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_4C_NHI	0x15d2
drivers/thunderbolt/nhi.h:83:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_4C_BRIDGE	0x15d3
drivers/thunderbolt/nhi.h:84:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_2C_NHI	0x15d9
drivers/thunderbolt/nhi.h:85:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_2C_BRIDGE	0x15da
drivers/thunderbolt/nhi.h:86:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_LP_USBONLY_NHI	0x15dc
drivers/thunderbolt/nhi.h:87:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_USBONLY_NHI	0x15dd
drivers/thunderbolt/nhi.h:88:#define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_C_USBONLY_NHI	0x15de
drivers/thunderbolt/nhi.h:89:#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_2C_BRIDGE	0x15e7
drivers/thunderbolt/nhi.h:90:#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_2C_NHI		0x15e8
drivers/thunderbolt/nhi.h:91:#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_4C_BRIDGE	0x15ea
drivers/thunderbolt/nhi.h:92:#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_4C_NHI		0x15eb
drivers/thunderbolt/nhi.h:93:#define PCI_DEVICE_ID_INTEL_TITAN_RIDGE_DD_BRIDGE	0x15ef
drivers/thunderbolt/nhi.h:94:#define PCI_DEVICE_ID_INTEL_ADL_NHI0			0x463e
drivers/thunderbolt/nhi.h:95:#define PCI_DEVICE_ID_INTEL_ADL_NHI1			0x466d
drivers/thunderbolt/nhi.h:96:#define PCI_DEVICE_ID_INTEL_WCL_NHI0			0x4d33
drivers/thunderbolt/nhi.h:97:#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_80G_NHI	0x5781
drivers/thunderbolt/nhi.h:98:#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HOST_40G_NHI	0x5784
drivers/thunderbolt/nhi.h:99:#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HUB_80G_BRIDGE 0x5786
drivers/thunderbolt/nhi.h:100:#define PCI_DEVICE_ID_INTEL_BARLOW_RIDGE_HUB_40G_BRIDGE 0x57a4
drivers/thunderbolt/nhi.h:101:#define PCI_DEVICE_ID_INTEL_MTL_M_NHI0			0x7eb2
drivers/thunderbolt/nhi.h:102:#define PCI_DEVICE_ID_INTEL_MTL_P_NHI0			0x7ec2
drivers/thunderbolt/nhi.h:103:#define PCI_DEVICE_ID_INTEL_MTL_P_NHI1			0x7ec3
drivers/thunderbolt/nhi.h:104:#define PCI_DEVICE_ID_INTEL_ICL_NHI1			0x8a0d
drivers/thunderbolt/nhi.h:105:#define PCI_DEVICE_ID_INTEL_ICL_NHI0			0x8a17
drivers/thunderbolt/nhi.h:106:#define PCI_DEVICE_ID_INTEL_TGL_NHI0			0x9a1b
drivers/thunderbolt/nhi.h:107:#define PCI_DEVICE_ID_INTEL_TGL_NHI1			0x9a1d
drivers/thunderbolt/nhi.h:108:#define PCI_DEVICE_ID_INTEL_TGL_H_NHI0			0x9a1f
drivers/thunderbolt/nhi.h:109:#define PCI_DEVICE_ID_INTEL_TGL_H_NHI1			0x9a21
drivers/thunderbolt/nhi.h:110:#define PCI_DEVICE_ID_INTEL_RPL_NHI0			0xa73e
drivers/thunderbolt/nhi.h:111:#define PCI_DEVICE_ID_INTEL_RPL_NHI1			0xa76d
drivers/thunderbolt/nhi.h:112:#define PCI_DEVICE_ID_INTEL_LNL_NHI0			0xa833
drivers/thunderbolt/nhi.h:113:#define PCI_DEVICE_ID_INTEL_LNL_NHI1			0xa834
drivers/thunderbolt/nhi.h:114:#define PCI_DEVICE_ID_INTEL_PTL_M_NHI0			0xe333
drivers/thunderbolt/nhi.h:115:#define PCI_DEVICE_ID_INTEL_PTL_M_NHI1			0xe334
drivers/thunderbolt/nhi.h:116:#define PCI_DEVICE_ID_INTEL_PTL_P_NHI0			0xe433
drivers/thunderbolt/nhi.h:117:#define PCI_DEVICE_ID_INTEL_PTL_P_NHI1			0xe434
drivers/thunderbolt/nhi.h-118-
drivers/thunderbolt/nhi.h:119:#define PCI_CLASS_SERIAL_USB_USB4			0x0c0340
drivers/thunderbolt/nhi.h-120-
drivers/thunderbolt/nhi.h-121-/* Host interface quirks */
drivers/thunderbolt/nhi.h:122:#define QUIRK_AUTO_CLEAR_INT	BIT(0)
drivers/thunderbolt/nhi.h:123:#define QUIRK_E2E		BIT(1)
drivers/thunderbolt/nhi.h-124-
--
drivers/thunderbolt/nhi.h-128- */
drivers/thunderbolt/nhi.h:129:#define MSIX_MIN_VECS		6
drivers/thunderbolt/nhi.h:130:#define MSIX_MAX_VECS		16
drivers/thunderbolt/nhi.h-131-
]

120/4 2026/08/10 08:32 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 39815
							output: 31
							thoughts: 1702
						

Thoughts:
**My Thought Process Regarding Thunderbolt NHI Driver Register Accesses**

I've been tasked with determining if there are any registers accessed by the Thunderbolt NHI driver that have an offset greater than `0x39640`. My initial scan of `nhi.h` revealed no explicit definitions for register offsets beyond that point.

However, I need to be absolutely precise. The question specifically asks about "any other register." This implies I need to consider registers beyond just `REG_CAPS` (which has an offset of `0x39640`) and identify any that exceed this threshold. I've enumerated those that *do* exceed `0x39640` based on my current knowledge:

*   `REG_DMA_MISC` (offset `0x39864`)
*   `REG_RESET` (offset `0x39898`)
*   `REG_INMAIL_DATA` (offset `0x39900`)
*   `REG_INMAIL_CMD` (offset `0x39904`)
*   `REG_OUTMAIL_CMD` (offset `0x3990c`)
*   `REG_FW_STS` (offset `0x39944`)

Now, the critical step is to confirm if there are *any other* registers accessed that are *not* explicitly defined in `nhi_regs.h` but *are* accessed within the relevant driver files, specifically `nhi.c`, `icm.c`, or `pci.c`. My investigation involved searching for all instances where `iobase` is utilized. This search revealed that the offsets added to `iobase` are limited to:

*   `REG_RING_INTERRUPT_BASE + ring`
*   `REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`
*   `REG_RING_NOTIFY_BASE + ring`
*   `REG_RING_INT_CLEAR + ring`
*   `REG_DMA_MISC`
*   `REG_INT_VEC_ALLOC_BASE`
*   `REG_INT_THROTTLING_RATE + ring->vector * 4`
*   `REG_TX_RING_BASE` / `REG_RX_RING_BASE`
*   `REG_TX_OPTIONS_BASE` / `REG_RX_OPTIONS_BASE`
*   `REG_INMAIL_DATA`
*   `REG_INMAIL_CMD`
*   `REG_OUTMAIL_CMD`
*   `REG_CAPS`
*   `REG_RESET`
*   `REG_FW_STS`

I then meticulously examined the ring descriptors themselves. These are accessed via `ring_desc_base(ring) + offset`. Since `ring_desc_base(ring)` is derived from `iobase + REG_TX_RING_BASE` (offset `0x00000`) or `iobase + REG_RX_RING_BASE` (offset `0x08000`), and the offsets added are typically small (e.g., 0, 4, 8, 12), these accesses remain well below the `0x39640` threshold.

Similarly, `ring_options_base(ring)` is based on `iobase + REG_TX_OPTIONS_BASE` (offset `0x19800`) or `iobase + REG_RX_OPTIONS_BASE` (offset `0x29800`). Again, the subsequent small offsets (e.g., 0, 4) keep these accesses below the critical `0x39640`.

I also checked other base addresses and their related offsets:

*   `REG_RING_NOTIFY_BASE` (offset `0x37800`)
*   `REG_RING_INT_CLEAR` (offset `0x37808`)
*   `REG_RING_INTERRUPT_BASE` (offset `0x38200`)
*   `REG_RING_INTERRUPT_MASK_CLEAR_BASE` (offset `0x38208`)
*   `REG_INT_THROTTLING_RATE` (offset `0x38c00`)
*   `REG_INT_VEC_ALLOC_BASE` (offset `0x38c40`)

All of these are, importantly, less than `0x39640`.

Therefore, based on my thorough examination of the registered offsets and the search for direct register accesses within the `nhi.c` and `icm.c` files (specifically looking for `readl`, `writel`, `ioread`, `iowrite`, `readq`, and `writeq`), the registers accessed by the Thunderbolt NHI driver that have an offset *larger* than `0x39640` are precisely these six:

1.  `REG_DMA_MISC` at offset `0x39864`
2.  `REG_RESET` at offset `0x39898`
3.  `REG_INMAIL_DATA` at offset `0x39900`
4.  `REG_INMAIL_CMD` at offset `0x39904`
5.  `REG_OUTMAIL_CMD` at offset `0x3990c`
6.  `REG_FW_STS` at offset `0x39944`

To be absolutely certain, I also scanned other files within the `drivers/thunderbolt/` directory. `ctl.c`, `tb.c`, `switch.c`, `usb4.c`, `tunnel.c`, and `path.c` do not appear to perform direct register accesses to the NHI device's I/O regions in a manner that would introduce offsets greater than `0x39640`. Instead, they rely on control channel packets, DMA ports, or calls to functions that ultimately manage these lower-level accesses. My searches for direct I/O read/write operations in these files did not yield any additional registers exceeding the specified offset.


121/4 2026/08/10 08:33 tool grepper
0m Error:
log-in to see details

Args:
map[Expression:(readq|writeq) PathPrefix:drivers/thunderbolt]

Results:
map[Output:]

122/4 2026/08/10 08:33 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 41546
							output: 32
							thoughts: 55
						

Thoughts:
**My Thought Process on Finding DMA Operations in Thunderbolt Drivers**

Alright, so I'm digging into this Thunderbolt driver code, and I'm trying to pinpoint how it's handling Direct Memory Access (DMA) operations – specifically, how it's transferring data between the system's main memory and the Thunderbolt controller's I/O space. My initial instinct was to look for the standard `readq` and `writeq` functions. These are pretty common for direct register access, especially when dealing with 64-bit values. However, a quick check reveals that there are no direct matches for `readq` or `writeq` in this context. This tells me that the driver isn't just doing simple, direct register reads or writes. It's likely using a more abstract, higher-level mechanism for I/O memory access, which is typical for DMA.

So, the next logical step is to consider functions designed for block transfers to and from I/O memory. The `memcpy_fromio` and `memcpy_toio` functions immediately come to mind. These are specifically built for copying blocks of data to and from I/O memory regions, which is precisely what you'd expect for a DMA setup. They handle the underlying memory mapping and access details, abstracting away the complexities of the hardware.

Therefore, my next move is to perform a targeted search. I'll be grepping through the `drivers/thunderbolt/` directory specifically for instances of `memcpy_fromio` or `memcpy_toio`. This should give me direct insight into where and how the driver is initiating these crucial DMA data transfers. If I find them, it will confirm my hypothesis about the driver's approach and allow me to analyze the specific data paths and buffer management involved.


123/4 2026/08/10 08:33 tool grepper
0m Error:
log-in to see details

Args:
map[Expression:memcpy_(fromio|toio) PathPrefix:drivers/thunderbolt]

Results:
map[Output:]

124/4 2026/08/10 08:33 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 41631
							output: 22
							thoughts: 95
						

Thoughts:
**A Deep Dive into `iobase` and `tb_nhi`**

I'm grappling with a situation where I'm seeing "no matches," which is always a frustrating starting point. My immediate thought is to explore the most direct avenue for accessing memory-mapped I/O: direct pointer dereferencing of `iobase`. However, I need to pause and verify the type of `iobase` before proceeding. I recall, or suspect, that `iobase` is declared as `void __iomem *iobase` within the `struct tb_nhi` definition. To be absolutely certain, I need to locate the precise definition of `struct tb_nhi`. My next step will be to search for this structure's definition, likely within the kernel source, specifically in files like `include/linux/thunderbolt.h` or potentially `drivers/thunderbolt/tb.h`, as that seems like the most logical place for Thunderbolt-related structures. This verification is crucial before I can confidently consider direct dereferencing or any other manipulation of `iobase`.


125/4 2026/08/10 08:33 tool codesearch-definition-source
0m Args:
map[Name:tb_nhi]

Results:
map[SourceCode: 500:	/**
 501:	 * struct tb_nhi - thunderbolt native host interface
 502:	 * @lock: Must be held during ring creation/destruction. Is acquired by
 503:	 *	  interrupt_work when dispatching interrupts to individual rings.
 504:	 * @dev: Device associated with this NHI instance
 505:	 * @ops: NHI specific optional ops
 506:	 * @iobase: MMIO space of the NHI
 507:	 * @tx_rings: All Tx rings available on this host controller
 508:	 * @rx_rings: All Rx rings available on this host controller
 509:	 * @going_away: The host controller device is about to disappear so when
 510:	 *		this flag is set, avoid touching the hardware anymore.
 511:	 * @iommu_dma_protection: An IOMMU will isolate external-facing ports.
 512:	 * @interrupt_work: Work scheduled to handle ring interrupt when no
 513:	 *		    MSI-X is used.
 514:	 * @hop_count: Number of rings (end point hops) supported by NHI.
 515:	 * @quirks: NHI specific quirks if any
 516:	 * @domain_released: Completed when domain has been fully released
 517:	 */
 518:	struct tb_nhi {
 519:		spinlock_t lock;
 520:		struct device *dev;
 521:		const struct tb_nhi_ops *ops;
 522:		void __iomem *iobase;
 523:		struct tb_ring **tx_rings;
 524:		struct tb_ring **rx_rings;
 525:		bool going_away;
 526:		bool iommu_dma_protection;
 527:		struct work_struct interrupt_work;
 528:		u32 hop_count;
 529:		unsigned long quirks;
 530:		struct completion domain_released;
 531:	};
 SourceFile:include/linux/thunderbolt.h]

126/4 2026/08/10 08:33 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 42304
							output: 25
							thoughts: 220
						

Thoughts:
**My Thought Process Regarding `iobase` and Thunderbolt Driver Interactions**

So, I've confirmed that `iobase` is indeed a `void __iomem *`. My next step was to meticulously investigate its usage within the `drivers/thunderbolt/` directory. I wanted to be absolutely certain which files were interacting with this specific member. My initial search, using `grep` for `iobase` specifically within `drivers/thunderbolt/`, yielded a definitive list: `icm.c`, `nhi.c`, and `pci.c`. The absence of any other files in this directory that contained references to `iobase` provided a strong indication that my focus was correctly narrowed.

However, my curiosity didn't stop there. As an expert in this domain, I understand the importance of a comprehensive understanding. I needed to ascertain if `tb_nhi::iobase`, or more practically, `nhi->iobase` (given the likely structure), was being accessed or manipulated from *outside* the immediate Thunderbolt driver directory. To achieve this, I decided to leverage a more powerful tool: `codesearch-find-references`. This tool is invaluable for tracing symbol usage across the entire kernel codebase. My intention was to run it specifically to find all references to `tb_nhi::iobase`, which would, by extension, reveal any external dependencies or interactions with the `iobase` member of the `tb_nhi` structure.


127/4 2026/08/10 08:33 tool codesearch-find-references
0m Args:
map[Name:tb_nhi::iobase]

Results:
map[References:[map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:__ring_interrupt_mask SourceFile:drivers/thunderbolt/nhi.c SourceLine:387] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:__ring_interrupt_mask SourceFile:drivers/thunderbolt/nhi.c SourceLine:392] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_ar_get_mode SourceFile:drivers/thunderbolt/icm.c SourceLine:1516] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_reset SourceFile:drivers/thunderbolt/icm.c SourceLine:1846] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_reset SourceFile:drivers/thunderbolt/icm.c SourceLine:1848] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_reset SourceFile:drivers/thunderbolt/icm.c SourceLine:1851] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_reset SourceFile:drivers/thunderbolt/icm.c SourceLine:1854] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_running SourceFile:drivers/thunderbolt/icm.c SourceLine:379] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_firmware_start SourceFile:drivers/thunderbolt/icm.c SourceLine:1879] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:icm_tgl_is_supported SourceFile:drivers/thunderbolt/icm.c SourceLine:1726] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_clear_interrupt SourceFile:drivers/thunderbolt/nhi.c SourceLine:66] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_clear_interrupt SourceFile:drivers/thunderbolt/nhi.c SourceLine:68] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_interrupt_work SourceFile:drivers/thunderbolt/nhi.c SourceLine:936] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mailbox_cmd SourceFile:drivers/thunderbolt/nhi.c SourceLine:875] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mailbox_cmd SourceFile:drivers/thunderbolt/nhi.c SourceLine:877] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mailbox_cmd SourceFile:drivers/thunderbolt/nhi.c SourceLine:880] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mailbox_cmd SourceFile:drivers/thunderbolt/nhi.c SourceLine:884] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mailbox_mode SourceFile:drivers/thunderbolt/nhi.c SourceLine:911] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mask_interrupt SourceFile:drivers/thunderbolt/nhi.c SourceLine:56] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mask_interrupt SourceFile:drivers/thunderbolt/nhi.c SourceLine:57] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_mask_interrupt SourceFile:drivers/thunderbolt/nhi.c SourceLine:59] map[ReferenceKind:writes ReferencingEntityKind:function ReferencingEntityName:nhi_pci_probe SourceFile:drivers/thunderbolt/pci.c SourceLine:469] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_pci_probe SourceFile:drivers/thunderbolt/pci.c SourceLine:470] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_probe SourceFile:drivers/thunderbolt/nhi.c SourceLine:1198] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_reset SourceFile:drivers/thunderbolt/nhi.c SourceLine:1137] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_reset SourceFile:drivers/thunderbolt/nhi.c SourceLine:1147] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:nhi_reset SourceFile:drivers/thunderbolt/nhi.c SourceLine:1152] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_clear_msix SourceFile:drivers/thunderbolt/nhi.c SourceLine:438] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_clear_msix SourceFile:drivers/thunderbolt/nhi.c SourceLine:440] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_desc_base SourceFile:drivers/thunderbolt/nhi.c SourceLine:173] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:106] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:113] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:115] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:127] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:131] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_interrupt_active SourceFile:drivers/thunderbolt/nhi.c SourceLine:147] map[ReferenceKind:reads ReferencingEntityKind:function ReferencingEntityName:ring_options_base SourceFile:drivers/thunderbolt/nhi.c SourceLine:181]] TruncatedOutput:false]

128/4 2026/08/10 08:33 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 43818
							output: 39
							thoughts: 114
						

Thoughts:
**My Journey Through `tb_nhi::iobase`**

Wow, this is incredible! The `codesearch-find-references` tool has just provided me with a precise list of all functions that interact with `tb_nhi::iobase`. My immediate thought is to meticulously examine each one to understand its role in the system.

My first target is `__ring_interrupt_mask` located in `drivers/thunderbolt/nhi.c`. I need to dive into its implementation to see exactly how it's manipulating `tb_nhi::iobase`. My current understanding is that it's performing read and write operations on `ring->nhi->iobase + reg`. The crucial next step is to figure out what `reg` represents – its value and context are key to understanding the precise memory locations being accessed within `tb_nhi::iobase`. I'm already mentally tracing the data flow and potential side effects.


129/4 2026/08/10 08:33 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:__ring_interrupt_mask]

Results:
map[SourceCode: 380:	static void __ring_interrupt_mask(struct tb_ring *ring, bool mask)
 381:	{
 382:		int idx = ring_interrupt_index(ring);
 383:		int reg = REG_RING_INTERRUPT_BASE + idx / 32 * 4;
 384:		int bit = idx % 32;
 385:		u32 val;
 386:	
 387:		val = ioread32(ring->nhi->iobase + reg);
 388:		if (mask)
 389:			val &= ~BIT(bit);
 390:		else
 391:			val |= BIT(bit);
 392:		iowrite32(val, ring->nhi->iobase + reg);
 393:	}
 SourceFile:drivers/thunderbolt/nhi.c]

130/4 2026/08/10 08:33 llm codeexpert
1m Model:
gemini-3.5-flash

Tokens:
							input: 44203
							output: 41
							thoughts: 213
						

Thoughts:
**My Thought Process Regarding Ring Interrupt Register Calculation and `icm_ar_get_mode`**

Okay, so when I'm looking at this `reg` expression, `REG_RING_INTERRUPT_BASE + idx / 32 * 4`, my first instinct is to break down the components. I know `REG_RING_INTERRUPT_BASE` is a fixed offset, `0x38200` in this case. The `idx` value, which is related to `hop_count`, is the variable part I need to pay attention to. I'm doing a quick mental check on the potential range of `idx`. The text mentions `idx` is at most `2 * hop_count`, and I recall `hop_count` can be quite large, maybe up to 256 in typical scenarios. However, I also see a note that `hop_count` can actually go up to 2048. So, I'm performing a quick calculation: if `idx` is at its maximum, `2 * 2048 = 4096`. Then, `4096 / 32 * 4` simplifies to `128 * 4`, which is `512`. Adding this to the base address, `0x38200 + 512` gives me `0x38200 + 0x200 = 0x38400`. I'm mentally confirming that this calculated address (`0x38400`) is indeed well within the expected range, specifically below the upper bound of `0x39640` mentioned in my internal knowledge base or the context I'm working with. This calculation is crucial for me to ensure I'm not going to hit any out-of-bounds memory access or unexpected behavior. It's a sanity check to confirm the register mapping is as anticipated.

Following that, my attention shifts to the function call: `icm_ar_get_mode` in `drivers/thunderbolt/icm.c`. My next step is naturally to dive into the implementation of this specific function. I need to understand exactly what `icm_ar_get_mode` does, what parameters it takes, what it returns, and how it interacts with the system. This is where I'd typically start looking at the source code itself to trace its execution path and understand its purpose within the Thunderbolt driver context. I'm anticipating that this function likely plays a role in determining or querying some mode or state related to the "ar" component, and its output might be relevant to how the ring interrupts are configured or managed.


131/4 2026/08/10 08:34 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/icm.c Name:icm_ar_get_mode]

Results:
map[SourceCode:1509:	static int icm_ar_get_mode(struct tb *tb)
1510:	{
1511:		struct tb_nhi *nhi = tb->nhi;
1512:		int retries = 60;
1513:		u32 val;
1514:	
1515:		do {
1516:			val = ioread32(nhi->iobase + REG_FW_STS);
1517:			if (val & REG_FW_STS_NVM_AUTH_DONE)
1518:				break;
1519:			msleep(50);
1520:		} while (--retries);
1521:	
1522:		if (!retries) {
1523:			dev_err(nhi->dev, "ICM firmware not authenticated\n");
1524:			return -ENODEV;
1525:		}
1526:	
1527:		return nhi_mailbox_mode(nhi);
1528:	}
 SourceFile:drivers/thunderbolt/icm.c]

132/4 2026/08/10 08:34 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 44748
							output: 40
							thoughts: 60
						

Thoughts:
**My Thought Process Regarding Firmware Reset and Status Register Access**

Alright, so my current line of thinking is to delve into the specifics of how the firmware reset process is handled, particularly in relation to how the system monitors and potentially interacts with the firmware's state.

My investigation has led me to a specific point of interest: the `icm_firmware_reset` function, located within the `drivers/thunderbolt/icm.c` file. This seems like a crucial entry point for understanding the reset mechanism itself.

Before I dive headfirst into the `icm_firmware_reset` code, I'm making a mental note, or rather, actively recalling, that as part of this reset procedure, the system is going to be accessing the `REG_FW_STS` register. I know this register is situated at a particular memory offset, `0x39944`. This access to the firmware status register is significant because it implies that the system isn't just blindly initiating a reset; it's likely going to be checking the firmware's status *before* or *after* the reset, or perhaps even *during* the process, to gauge its state, confirm successful reset, or detect any issues. Understanding what `REG_FW_STS` actually signifies and what values it might hold will be paramount to fully grasping the firmware reset flow.

So, my immediate next step, mentally speaking, is to examine the implementation of `icm_firmware_reset` in `drivers/thunderbolt/icm.c` to see precisely *how* it uses or interacts with that `REG_FW_STS` register and what other actions it performs during a firmware reset.


133/4 2026/08/10 08:34 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/icm.c Name:icm_firmware_reset]

Results:
map[SourceCode:1837:	static int icm_firmware_reset(struct tb *tb, struct tb_nhi *nhi)
1838:	{
1839:		struct icm *icm = tb_priv(tb);
1840:		u32 val;
1841:	
1842:		if (!icm->upstream_port)
1843:			return -ENODEV;
1844:	
1845:		/* Put ARC to wait for CIO reset event to happen */
1846:		val = ioread32(nhi->iobase + REG_FW_STS);
1847:		val |= REG_FW_STS_CIO_RESET_REQ;
1848:		iowrite32(val, nhi->iobase + REG_FW_STS);
1849:	
1850:		/* Re-start ARC */
1851:		val = ioread32(nhi->iobase + REG_FW_STS);
1852:		val |= REG_FW_STS_ICM_EN_INVERT;
1853:		val |= REG_FW_STS_ICM_EN_CPU;
1854:		iowrite32(val, nhi->iobase + REG_FW_STS);
1855:	
1856:		/* Trigger CIO reset now */
1857:		return icm->cio_reset(tb);
1858:	}
 SourceFile:drivers/thunderbolt/icm.c]

134/4 2026/08/10 08:34 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 45230
							output: 40
							thoughts: 60
						

Thoughts:
**My Thought Process on Firmware Status Checking**

Alright, so my current line of inquiry is focused on how this system verifies that the firmware is actually up and running, which is a pretty fundamental aspect of device operation. My first step in this particular thought sequence was to zero in on a specific piece of hardware: the `REG_FW_STS` register. I know this register, located at offset `0x39944` within the memory map, is the designated location for firmware status information. It's the immediate, low-level indicator I'd expect to interact with.

Following that initial hardware pointer, my thoughts naturally gravitated towards the software implementation that would be reading from this register. I immediately thought, "Where in the code is this `REG_FW_STS` being accessed?" This led me directly to a function named `icm_firmware_running`, situated within the `drivers/thunderbolt/icm.c` file. This function name is highly suggestive; it strongly implies that its purpose is precisely to determine if the ICM (which I understand to be the relevant component here) firmware is in an operational state. Therefore, my next logical step, and indeed the core of my current investigation, is to thoroughly examine the implementation of `icm_firmware_running` to understand *how* it's utilizing the `REG_FW_STS` register to achieve its stated goal. I need to see the precise read operations, any masking or interpretation of the register's bits, and the logic that ultimately leads to the function returning a "true" or "false" indication of firmware status.


135/4 2026/08/10 08:34 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/icm.c Name:icm_firmware_running]

Results:
map[SourceCode: 375:	static bool icm_firmware_running(const struct tb_nhi *nhi)
 376:	{
 377:		u32 val;
 378:	
 379:		val = ioread32(nhi->iobase + REG_FW_STS);
 380:		return !!(val & REG_FW_STS_ICM_EN);
 381:	}
 SourceFile:drivers/thunderbolt/icm.c]

136/4 2026/08/10 08:34 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 45454
							output: 40
							thoughts: 60
						

Thoughts:
**My Thought Process on Firmware Initialization**

Alright, so the first thing that catches my eye is this direct access to `REG_FW_STS` at offset `0x39944`. This immediately tells me we're dealing with some low-level hardware register manipulation, likely for status reporting or control related to the firmware itself. The fact that it's named `REG_FW_STS` strongly suggests it's a firmware status register, which is crucial for understanding the operational state of the Thunderbolt controller's integrated firmware.

Then, my attention shifts to the function call: `icm_firmware_start` in `drivers/thunderbolt/icm.c`. This is the core of what I need to understand. The name itself implies this is the entry point for initiating the firmware's boot sequence or its operational start. My immediate instinct is to dive into its implementation. I need to see *how* it accesses `REG_FW_STS` and *what* it's doing with that information. Is it reading the status to ensure the firmware is ready, or is it writing a command to initiate a start sequence? Understanding the context of that register access within this specific function is key to grasping the overall firmware initialization flow. I'm anticipating seeing checks for readiness, perhaps some initial configuration steps, and then potentially signaling the firmware to begin its own internal processes.


137/4 2026/08/10 08:34 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/icm.c Name:icm_firmware_start]

Results:
map[SourceCode:1860:	static int icm_firmware_start(struct tb *tb, struct tb_nhi *nhi)
1861:	{
1862:		unsigned int retries = 10;
1863:		int ret;
1864:		u32 val;
1865:	
1866:		/* Check if the ICM firmware is already running */
1867:		if (icm_firmware_running(nhi))
1868:			return 0;
1869:	
1870:		dev_dbg(nhi->dev, "starting ICM firmware\n");
1871:	
1872:		ret = icm_firmware_reset(tb, nhi);
1873:		if (ret)
1874:			return ret;
1875:	
1876:		/* Wait until the ICM firmware tells us it is up and running */
1877:		do {
1878:			/* Check that the ICM firmware is running */
1879:			val = ioread32(nhi->iobase + REG_FW_STS);
1880:			if (val & REG_FW_STS_NVM_AUTH_DONE)
1881:				return 0;
1882:	
1883:			msleep(300);
1884:		} while (--retries);
1885:	
1886:		return -ETIMEDOUT;
1887:	}
 SourceFile:drivers/thunderbolt/icm.c]

138/4 2026/08/10 08:34 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 45955
							output: 42
							thoughts: 64
						

Thoughts:
**My Thought Process Regarding Thunderbolt ICM TGL Support**

Alright, let's dive into this. My primary objective here is to understand how the system determines whether ICM (Intel® Converged Management Engine) is supported on Tiger Lake (TGL) platforms, specifically within the context of Thunderbolt drivers.

First off, I need to pinpoint the exact mechanism for checking this support. I've identified that the crucial piece of information is likely stored in a specific hardware register. My investigation leads me to `REG_FW_STS`, which resides at offset `0x39944`. This register, I presume, holds firmware status flags, and I'm specifically looking for a bit or a field within it that indicates ICM TGL support.

Having established the hardware interface, the next logical step is to examine the software implementation that reads and interprets this hardware status. I'm focusing on the function `icm_tgl_is_supported` within the `drivers/thunderbolt/icm.c` file. This function is precisely where the logic for this check should reside. My intention is to scrutinize its implementation thoroughly. I want to see *how* it accesses `REG_FW_STS` and *what specific condition* it checks within that register to return a true or false value for ICM TGL support. Understanding this function's internals is key to confirming and perhaps even debugging any issues related to this feature.


139/4 2026/08/10 08:34 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/icm.c Name:icm_tgl_is_supported]

Results:
map[SourceCode:1719:	static bool icm_tgl_is_supported(struct tb *tb)
1720:	{
1721:		unsigned long end = jiffies + msecs_to_jiffies(10);
1722:	
1723:		do {
1724:			u32 val;
1725:	
1726:			val = ioread32(tb->nhi->iobase + REG_FW_STS);
1727:			if (val & REG_FW_STS_NVM_AUTH_DONE)
1728:				return true;
1729:			usleep_range(100, 500);
1730:		} while (time_before(jiffies, end));
1731:	
1732:		return false;
1733:	}
 SourceFile:drivers/thunderbolt/icm.c]

140/4 2026/08/10 08:34 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 46296
							output: 39
							thoughts: 58
						

Thoughts:
**My Thought Process**

Alright, so I'm digging into this firmware status register, `REG_FW_STS`, which is located at offset `0x39944`. This is the first concrete data point I'm seeing about the system's state. My immediate next step is to understand how this register is being interacted with, specifically in terms of clearing interrupts. I'm going to jump over to the `drivers/thunderbolt/nhi.c` file and examine the `nhi_clear_interrupt` function. I need to see *exactly* what operations it performs on that `REG_FW_STS` register, or any related registers, to ensure interrupts are being properly acknowledged and cleared within the Thunderbolt host controller. This is crucial for reliable interrupt handling and preventing spurious wake-ups or missed events.


141/4 2026/08/10 08:35 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_clear_interrupt]

Results:
map[SourceCode:  63:	static void nhi_clear_interrupt(struct tb_nhi *nhi, int ring)
  64:	{
  65:		if (nhi->quirks & QUIRK_AUTO_CLEAR_INT)
  66:			ioread32(nhi->iobase + REG_RING_NOTIFY_BASE + ring);
  67:		else
  68:			iowrite32(~0, nhi->iobase + REG_RING_INT_CLEAR + ring);
  69:	}
 SourceFile:drivers/thunderbolt/nhi.c]

142/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 46533
							output: 24
							thoughts: 130
						

Thoughts:
**My Thought Process on Interrupt Handling**

Okay, so when I'm looking at how interrupts are being cleared, I'm seeing a couple of potential memory-mapped locations that are being accessed. It's either going to be at `REG_RING_NOTIFY_BASE` plus an offset defined by `ring`, or it's going to be at `REG_RING_INT_CLEAR` plus the same `ring` offset. The base address for the notification register is `0x37800`, and for the interrupt clear register, it's `0x37808`.

Now, I need to be precise about what this `ring` value actually represents in the context of the offset calculation. I see a formula `ring_interrupt_index(ring) / 32 * 4`. This suggests that `ring` itself isn't directly the byte offset, but rather it's used to derive it, likely by first determining which group of 32 interrupts it falls into (`ring_interrupt_index(ring) / 32`) and then scaling that by 4, presumably because each interrupt control register block is 4 bytes wide.

However, I'm not entirely sure about the exact value of the `ring` argument that gets passed *into* the `nhi_clear_interrupt` function. Before I commit to the offset calculation, I really need to trace back the calls and find all the places where `nhi_clear_interrupt` is actually invoked. That's the next crucial step to ensure I'm targeting the correct hardware register for clearing the interrupt.


143/4 2026/08/10 08:35 tool codesearch-find-references
0m Args:
map[Name:nhi_clear_interrupt]

Results:
map[References:[map[ReferenceKind:calls ReferencingEntityKind:function ReferencingEntityName:nhi_disable_interrupts SourceFile:drivers/thunderbolt/nhi.c SourceLine:166]] TruncatedOutput:false]

144/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 46730
							output: 40
							thoughts: 27
						

Thoughts:
**My Thought Process on Interrupt Handling in the NHI Driver**

My current focus is on understanding the precise flow of interrupt management within the NHI driver, specifically how the `nhi_clear_interrupt` function is invoked. To achieve this, I'm going to delve into the `nhi_disable_interrupts` function's implementation. My expectation is that as part of the process of disabling interrupts, the driver will also need to acknowledge and clear any pending interrupt conditions. Therefore, examining `nhi_disable_interrupts` should reveal the mechanism by which `nhi_clear_interrupt` is utilized, providing me with a clear picture of the interrupt clearing routine within this context.


145/4 2026/08/10 08:35 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_disable_interrupts]

Results:
map[SourceCode: 152:	/*
 153:	 * nhi_disable_interrupts() - disable interrupts for all rings
 154:	 *
 155:	 * Use only during init and shutdown.
 156:	 */
 157:	void nhi_disable_interrupts(struct tb_nhi *nhi)
 158:	{
 159:		int i = 0;
 160:		/* disable interrupts */
 161:		for (i = 0; i < RING_INTERRUPT_REG_COUNT(nhi); i++)
 162:			nhi_mask_interrupt(nhi, ~0, 4 * i);
 163:	
 164:		/* clear interrupt status bits */
 165:		for (i = 0; i < RING_NOTIFY_REG_COUNT(nhi); i++)
 166:			nhi_clear_interrupt(nhi, 4 * i);
 167:	}
 SourceFile:drivers/thunderbolt/nhi.c]

146/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 47061
							output: 39
							thoughts: 206
						

Thoughts:
**My Thought Process Regarding Register Offsets and Interrupt Handling**

Okay, so my initial thought here is about understanding the offset calculation for a `ring` within a register block. I've identified that `ring` is fundamentally `4 * i`, which tells me it's a pointer to a specific register's offset. This is important for understanding how I'll access these registers.

Then, I need to consider the context of `RING_NOTIFY_REG_COUNT(nhi)`. I've calculated that for a `hop_count` of 256, this value comes out to be 24. Now, knowing that `ring` is `4 * i` and `i` can go up to this calculated count, I can determine the maximum offset. So, `4 * i` will be at most `4 * 24 = 96`.

This maximum offset is crucial when I consider the base address, `REG_RING_NOTIFY_BASE`. If I add the maximum offset of 96 to this base address, I get `0x37800 + 96 = 0x37860`. My check confirms this value is well within the expected range, specifically below `0x39640`, which gives me confidence in the calculation and the memory mapping.

Moving on, the next step in my thought process is to examine the `nhi_interrupt_work` function, located in `drivers/thunderbolt/nhi.c`. This is where the actual interrupt handling logic resides, and I need to dive into its implementation to fully understand how the system reacts to interrupts and how it utilizes the register offsets I've been analyzing.


147/4 2026/08/10 08:35 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_interrupt_work]

Results:
map[SourceCode: 918:	void nhi_interrupt_work(struct work_struct *work)
 919:	{
 920:		struct tb_nhi *nhi = container_of(work, typeof(*nhi), interrupt_work);
 921:		int value = 0; /* Suppress uninitialized usage warning. */
 922:		int bit;
 923:		int hop = -1;
 924:		int type = 0; /* current interrupt type 0: TX, 1: RX, 2: RX overflow */
 925:		struct tb_ring *ring;
 926:	
 927:		spin_lock_irq(&nhi->lock);
 928:	
 929:		/*
 930:		 * Starting at REG_RING_NOTIFY_BASE there are three status bitfields
 931:		 * (TX, RX, RX overflow). We iterate over the bits and read a new
 932:		 * dwords as required. The registers are cleared on read.
 933:		 */
 934:		for (bit = 0; bit < 3 * nhi->hop_count; bit++) {
 935:			if (bit % 32 == 0)
 936:				value = ioread32(nhi->iobase
 937:						 + REG_RING_NOTIFY_BASE
 938:						 + 4 * (bit / 32));
 939:			if (++hop == nhi->hop_count) {
 940:				hop = 0;
 941:				type++;
 942:			}
 943:			if ((value & (1 << (bit % 32))) == 0)
 944:				continue;
 945:			if (type == 2) {
 946:				dev_warn(nhi->dev, "RX overflow for ring %d\n", hop);
 947:				continue;
 948:			}
 949:			if (type == 0)
 950:				ring = nhi->tx_rings[hop];
 951:			else
 952:				ring = nhi->rx_rings[hop];
 953:			if (ring == NULL) {
 954:				dev_warn(nhi->dev,
 955:					 "got interrupt for inactive %s ring %d\n",
 956:					 type ? "RX" : "TX",
 957:					 hop);
 958:				continue;
 959:			}
 960:	
 961:			spin_lock(&ring->lock);
 962:			__ring_interrupt(ring);
 963:			spin_unlock(&ring->lock);
 964:		}
 965:		spin_unlock_irq(&nhi->lock);
 966:	}
 SourceFile:drivers/thunderbolt/nhi.c]

148/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 48063
							output: 39
							thoughts: 165
						

Thoughts:
**My Thought Process Regarding Register Access in the Thunderbolt NHI Driver**

When I see the expression `REG_RING_NOTIFY_BASE + 4 * (bit / 32)`, my immediate concern is understanding the bounds of the memory access it represents. I know that `bit` has a maximum value defined by `3 * nhi->hop_count`. Given the context where `hop_count` can be as large as 256, this means `bit` can reach up to 768.

Now, I need to calculate the maximum offset `4 * (bit / 32)`. If `bit` is 768, then `bit / 32` is 24. Multiplying that by 4 gives me a maximum offset of 96.

Therefore, the highest address I could possibly access through `REG_RING_NOTIFY_BASE + 4 * (bit / 32)` would be `REG_RING_NOTIFY_BASE + 96`. The text explicitly states that `REG_RING_NOTIFY_BASE` is `0x37860`. Adding 96 to this value, I arrive at `0x378F0`. Crucially, this calculated maximum address, `0x378F0`, is comfortably within the range, as it's well below `0x39640`. This confirms to me that the register access is safe and will not go out of bounds, at least based on this particular calculation.

Following this, my attention shifts to the specific function `nhi_mailbox_cmd` in `drivers/thunderbolt/nhi.c`. My next logical step is to dive into the implementation of `nhi_mailbox_cmd` itself. I need to understand exactly how it uses the register access I just analyzed, and what other operations it performs. This is where I'll look for further details about its behavior and potential interactions with the hardware.


149/4 2026/08/10 08:35 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_mailbox_cmd]

Results:
map[SourceCode: 860:	/**
 861:	 * nhi_mailbox_cmd() - Send a command through NHI mailbox
 862:	 * @nhi: Pointer to the NHI structure
 863:	 * @cmd: Command to send
 864:	 * @data: Data to be send with the command
 865:	 *
 866:	 * Sends mailbox command to the firmware running on NHI.
 867:	 *
 868:	 * Return: %0 on success, negative errno otherwise.
 869:	 */
 870:	int nhi_mailbox_cmd(struct tb_nhi *nhi, enum nhi_mailbox_cmd cmd, u32 data)
 871:	{
 872:		ktime_t timeout;
 873:		u32 val;
 874:	
 875:		iowrite32(data, nhi->iobase + REG_INMAIL_DATA);
 876:	
 877:		val = ioread32(nhi->iobase + REG_INMAIL_CMD);
 878:		val &= ~(REG_INMAIL_CMD_MASK | REG_INMAIL_ERROR);
 879:		val |= REG_INMAIL_OP_REQUEST | cmd;
 880:		iowrite32(val, nhi->iobase + REG_INMAIL_CMD);
 881:	
 882:		timeout = ktime_add_ms(ktime_get(), NHI_MAILBOX_TIMEOUT);
 883:		do {
 884:			val = ioread32(nhi->iobase + REG_INMAIL_CMD);
 885:			if (!(val & REG_INMAIL_OP_REQUEST))
 886:				break;
 887:			usleep_range(10, 20);
 888:		} while (ktime_before(ktime_get(), timeout));
 889:	
 890:		if (val & REG_INMAIL_OP_REQUEST)
 891:			return -ETIMEDOUT;
 892:		if (val & REG_INMAIL_ERROR)
 893:			return -EIO;
 894:	
 895:		return 0;
 896:	}
 SourceFile:drivers/thunderbolt/nhi.c]

150/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 48872
							output: 39
							thoughts: 80
						

Thoughts:
**My Thought Process Regarding Thunderbolt Mailbox Interaction**

Alright, let's break down how this system handles mailbox operations for the Thunderbolt Network Interface Host (NHI). My immediate focus is on how the NHI interacts with its command and data registers. I've identified two key memory-mapped I/O (MMIO) regions that are central to this: `REG_INMAIL_DATA` at offset `0x39900` and `REG_INMAIL_CMD` at offset `0x39904`. This is where the actual exchange of information and commands between the host system and the Thunderbolt controller will occur.

Now, to understand the *logic* behind these accesses, I need to look at the code. My next step is to investigate the `nhi_mailbox_mode` function within the `drivers/thunderbolt/nhi.c` file. This is where the higher-level firmware or driver logic will orchestrate the use of those low-level MMIO registers. I'm expecting to see how these registers are used to send commands, receive data, and manage the state of the mailbox communication. Essentially, I'm tracing the path from the abstract concept of a "mailbox command" down to the concrete register reads and writes.


151/4 2026/08/10 08:35 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_mailbox_mode]

Results:
map[SourceCode: 898:	/**
 899:	 * nhi_mailbox_mode() - Return current firmware operation mode
 900:	 * @nhi: Pointer to the NHI structure
 901:	 *
 902:	 * The function reads current firmware operation mode using NHI mailbox
 903:	 * registers and returns it to the caller.
 904:	 *
 905:	 * Return: &enum nhi_fw_mode.
 906:	 */
 907:	enum nhi_fw_mode nhi_mailbox_mode(struct tb_nhi *nhi)
 908:	{
 909:		u32 val;
 910:	
 911:		val = ioread32(nhi->iobase + REG_OUTMAIL_CMD);
 912:		val &= REG_OUTMAIL_CMD_OPMODE_MASK;
 913:		val >>= REG_OUTMAIL_CMD_OPMODE_SHIFT;
 914:	
 915:		return (enum nhi_fw_mode)val;
 916:	}
 SourceFile:drivers/thunderbolt/nhi.c]

152/4 2026/08/10 08:35 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 49284
							output: 39
							thoughts: 60
						

Thoughts:
**My Thought Process for Understanding the Thunderbolt Interrupt Masking**

Okay, so my first step in analyzing this interrupt masking behavior within the Thunderbolt driver is to pinpoint the exact register involved. I see the system is accessing `REG_OUTMAIL_CMD` at offset `0x3990c`. This is crucial information – it tells me precisely where the command to manipulate outbound mail is located within the hardware's memory map. Knowing this register allows me to understand the physical mechanism being used to signal or de-signal interrupts.

Following this, my attention is drawn to a specific function: `nhi_mask_interrupt` located in `drivers/thunderbolt/nhi.c`. This is the software interface that's actually *calling* the hardware operation I just identified. My immediate instinct, as an expert in this domain, is to dive into the implementation of `nhi_mask_interrupt` itself. I need to see *how* this function utilizes `REG_OUTMAIL_CMD`. Does it write a specific value? Does it perform a bitwise operation? What are the specific bits within `REG_OUTMAIL_CMD` that correspond to masking or unmasking different types of interrupts? Understanding the logic within `nhi_mask_interrupt` is key to grasping the full picture of how the driver controls interrupt visibility. I'm essentially tracing the flow from the high-level function call down to the low-level hardware register manipulation to fully comprehend the interrupt masking mechanism.


153/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_mask_interrupt]

Results:
map[SourceCode:  51:	static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
  52:	{
  53:		if (nhi->quirks & QUIRK_AUTO_CLEAR_INT) {
  54:			u32 val;
  55:	
  56:			val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  57:			iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  58:		} else {
  59:			iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
  60:		}
  61:	}
 SourceFile:drivers/thunderbolt/nhi.c]

154/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 49597
							output: 37
							thoughts: 193
						

Thoughts:
**My Thought Process Regarding NHI Register Access**

My current line of thinking is focused on understanding how interrupt handling is managed within the NHI (Thunderbolt Network Interface) controller. Specifically, I'm investigating the memory-mapped registers involved in this process and ensuring that the addresses I'm dealing with are within expected bounds.

I've observed that the system accesses specific interrupt-related registers. These are either the interrupt base register, calculated as `REG_RING_INTERRUPT_BASE + ring`, or the interrupt mask clear register, calculated as `REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`. I know that `REG_RING_INTERRUPT_BASE` is fixed at `0x38200` and `REG_RING_INTERRUPT_MASK_CLEAR_BASE` is at `0x38208`.

The variable `ring` is derived from `4 * i`. My analysis indicates that the maximum value `i` can take is constrained by `RING_INTERRUPT_REG_COUNT(nhi)`, which is defined as `(31 + 2 * nhi->hop_count) / 32`. Given this formula, the maximum value for `i` is 16. Therefore, the maximum possible value for `ring` is `4 * 16 = 64`.

This leads me to conclude that the calculated register addresses, even at their maximum, will be `0x38200 + 64` and `0x38208 + 64`. These values are demonstrably well below `0x39640`, which I understand to be a higher, perhaps boundary or supervisory, address in this memory region. This confirms that the register accesses are within the expected and safe range for the NHI controller's interrupt management.

Moving forward, I want to delve deeper into the actual implementation of this interrupt handling. To do that, my next step is to examine the `nhi_probe` function within the `drivers/thunderbolt/nhi.c` file. I'll be looking at how `nhi_probe` utilizes these registers and what logic it employs to configure and manage interrupts.


155/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_probe]

Results:
map[SourceCode:1186:	int nhi_probe(struct tb_nhi *nhi)
1187:	{
1188:		struct device *dev = nhi->dev;
1189:		struct tb *tb;
1190:		int res;
1191:	
1192:		if (!nhi->ops)
1193:			return dev_err_probe(dev, -EINVAL, "NHI ops not set\n");
1194:	
1195:		if (!nhi->ops->init_interrupts)
1196:			return dev_err_probe(dev, -EINVAL, "missing required NHI ops\n");
1197:	
1198:		nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
1199:		dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
1200:	
1201:		nhi->tx_rings = devm_kcalloc(dev, nhi->hop_count,
1202:					     sizeof(*nhi->tx_rings), GFP_KERNEL);
1203:		nhi->rx_rings = devm_kcalloc(dev, nhi->hop_count,
1204:					     sizeof(*nhi->rx_rings), GFP_KERNEL);
1205:		if (!nhi->tx_rings || !nhi->rx_rings)
1206:			return -ENOMEM;
1207:	
1208:		nhi_reset(nhi);
1209:	
1210:		/* In case someone left them on. */
1211:		nhi_disable_interrupts(nhi);
1212:	
1213:		res = nhi->ops->init_interrupts(nhi);
1214:		if (res)
1215:			return dev_err_probe(dev, res, "cannot enable interrupts, aborting\n");
1216:	
1217:		spin_lock_init(&nhi->lock);
1218:	
1219:		res = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64));
1220:		if (res)
1221:			return dev_err_probe(dev, res, "failed to set DMA mask\n");
1222:	
1223:		if (nhi->ops->init) {
1224:			res = nhi->ops->init(nhi);
1225:			if (res)
1226:				return dev_err_probe(dev, res, "NHI specific init failed\n");
1227:		}
1228:	
1229:		tb = nhi_select_cm(nhi);
1230:		if (!tb)
1231:			return dev_err_probe(dev, -ENODEV,
1232:				"failed to determine connection manager, aborting\n");
1233:	
1234:		dev_dbg(dev, "NHI initialized, starting thunderbolt\n");
1235:	
1236:		init_completion(&nhi->domain_released);
1237:	
1238:		res = tb_domain_add(tb, host_reset);
1239:		if (res) {
1240:			/*
1241:			 * At this point the RX/TX rings might already have been
1242:			 * activated. Do a proper shutdown.
1243:			 */
1244:			tb_domain_put(tb);
1245:			wait_for_completion(&nhi->domain_released);
1246:			nhi_shutdown(nhi);
1247:			return dev_err_probe(dev, res, "failed to add domain\n");
1248:		}
1249:		dev_set_drvdata(dev, tb);
1250:	
1251:		device_wakeup_enable(dev);
1252:	
1253:		pm_runtime_allow(dev);
1254:		pm_runtime_set_autosuspend_delay(dev, TB_AUTOSUSPEND_DELAY);
1255:		pm_runtime_use_autosuspend(dev);
1256:		pm_runtime_put_autosuspend(dev);
1257:	
1258:		return 0;
1259:	}
 SourceFile:drivers/thunderbolt/nhi.c]

156/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 51010
							output: 37
							thoughts: 54
						

Thoughts:
**My Thought Process for Analyzing the Thunderbolt `nhi_reset` Function**

Alright, so my current focus is on understanding the `nhi_reset` function within the Thunderbolt driver, specifically located at `drivers/thunderbolt/nhi.c`. To truly grasp what's happening when this function is invoked, I need to delve into its internal workings. My immediate inclination is to examine the implementation of `nhi_reset` itself.

Before I even dive into the code, a critical piece of context is that this function will likely need to interact with hardware registers. Based on the surrounding code or prior knowledge, I'm anticipating that it will access `REG_CAPS`, which I know resides at the memory offset `0x39640`. This register is almost certainly going to hold vital capability information or status flags related to the Thunderbolt Network Interface Host (NHI), and manipulating or reading from it will be fundamental to a reset operation. My next step is to meticulously go through the `nhi_reset` function's code, tracing its execution flow and observing precisely how it reads from, and potentially writes to, `REG_CAPS` (at `0x39640`) as part of its reset procedure. This will be the core of my understanding.


157/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_reset]

Results:
map[SourceCode:1132:	static void nhi_reset(struct tb_nhi *nhi)
1133:	{
1134:		ktime_t timeout;
1135:		u32 val;
1136:	
1137:		val = ioread32(nhi->iobase + REG_CAPS);
1138:		/* Reset only v2 and later routers */
1139:		if (FIELD_GET(REG_CAPS_VERSION_MASK, val) < REG_CAPS_VERSION_2)
1140:			return;
1141:	
1142:		if (!host_reset) {
1143:			dev_dbg(nhi->dev, "skipping host router reset\n");
1144:			return;
1145:		}
1146:	
1147:		iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
1148:		msleep(100);
1149:	
1150:		timeout = ktime_add_ms(ktime_get(), 500);
1151:		do {
1152:			val = ioread32(nhi->iobase + REG_RESET);
1153:			if (!(val & REG_RESET_HRR)) {
1154:				dev_warn(nhi->dev, "host router reset successful\n");
1155:				return;
1156:			}
1157:			usleep_range(10, 20);
1158:		} while (ktime_before(ktime_get(), timeout));
1159:	
1160:		dev_warn(nhi->dev, "timeout resetting host router\n");
1161:	}
 SourceFile:drivers/thunderbolt/nhi.c]

158/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 51580
							output: 39
							thoughts: 75
						

Thoughts:
**My Thought Process Regarding MSI-X Handling in the Thunderbolt NHI Driver**

Alright, so my investigation has led me to the `drivers/thunderbolt/nhi.c` file, specifically focusing on the `ring_clear_msix` function. My goal here is to understand precisely how this function interacts with hardware registers to manage Message Signaled Interrupt Extensions (MSI-X).

My current understanding is that this function is directly involved in clearing or acknowledging MSI-X interrupts. To achieve this, it needs to communicate with specific hardware control registers. Based on the context of interrupt handling and hardware interaction, I anticipate that it will involve reading from and potentially writing to certain memory-mapped I/O (MMIO) addresses.

Specifically, my analysis points to two key registers:

*   `REG_CAPS` (at offset `0x39640`): I assume this register likely holds capabilities related to the interrupt controller or the device's interrupt handling features. Accessing this would allow me to determine what MSI-X functionalities are supported or currently configured. It's a crucial piece of information for understanding the operational state.
*   `REG_RESET` (at offset `0x39898`): This register strongly suggests an interface for resetting or re-initializing interrupt-related mechanisms. In the context of `ring_clear_msix`, I would expect this register to be involved in acknowledging an interrupt, potentially clearing a pending interrupt status, or perhaps even resetting the interrupt vector table entry associated with the MSI-X message.

Therefore, the `ring_clear_msix` function, in my mind, is the logical point where the driver asserts control over these hardware registers to ensure that an MSI-X interrupt is properly processed and cleared from the system's perspective. This is a fundamental step in robust interrupt management, preventing spurious re-triggers and ensuring that the system can react efficiently to new events.


159/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:ring_clear_msix]

Results:
map[SourceCode: 429:	static void ring_clear_msix(const struct tb_ring *ring)
 430:	{
 431:		int bit;
 432:	
 433:		if (ring->nhi->quirks & QUIRK_AUTO_CLEAR_INT)
 434:			return;
 435:	
 436:		bit = ring_interrupt_index(ring) & 31;
 437:		if (ring->is_tx)
 438:			iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR);
 439:		else
 440:			iowrite32(BIT(bit), ring->nhi->iobase + REG_RING_INT_CLEAR +
 441:				  4 * (ring->nhi->hop_count / 32));
 442:	}
 SourceFile:drivers/thunderbolt/nhi.c]

160/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 51941
							output: 38
							thoughts: 159
						

Thoughts:
**My Thought Process Regarding Register Access and Ring Descriptors**

Okay, let me walk through my reasoning here. I'm looking at the memory access for clearing ring interrupts. The text indicates it's accessing `REG_RING_INT_CLEAR`, which has an offset of `0x37808`. It's not a simple direct access, though; there's a dynamic component: `REG_RING_INT_CLEAR + 4 * (ring->nhi->hop_count / 32)`.

My immediate concern is the potential address range this calculation could lead to. I need to ensure this doesn't go out of bounds, specifically mentioning `0x39640` as an upper limit I'm keeping in mind.

I know that `hop_count` has a maximum value of 2048. So, let's plug that in to see the worst-case scenario for the offset calculation: `4 * (2048 / 32)`.
Breaking that down: `2048 / 32` is 64.
Then, `4 * 64` equals 256.

Adding this maximum offset to the base register: `0x37808 + 256`. This results in `0x37908`.
My mental check confirms that `0x37908` is indeed "well below" the `0x39640` boundary I was concerned about. This assures me that this particular interrupt clearing mechanism is operating within expected memory limits.

Following this, my next logical step is to investigate the `ring_desc_base` as mentioned in `drivers/thunderbolt/nhi.c`. I need to understand how this base address is implemented, as it's clearly a critical piece of information for managing ring descriptors, and likely related to the memory management I've just been analyzing. I need to delve into its definition to grasp its role and how it interacts with the overall ring buffer structure.


161/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:ring_desc_base]

Results:
map[SourceCode: 171:	static void __iomem *ring_desc_base(struct tb_ring *ring)
 172:	{
 173:		void __iomem *io = ring->nhi->iobase;
 174:		io += ring->is_tx ? REG_TX_RING_BASE : REG_RX_RING_BASE;
 175:		io += ring->hop * 16;
 176:		return io;
 177:	}
 SourceFile:drivers/thunderbolt/nhi.c]

162/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 52274
							output: 38
							thoughts: 168
						

Thoughts:
**My Thought Process Regarding Ring Base Address Calculation and Interrupt Handling**

Okay, let's break down my current line of thinking. I'm looking at how the ring base addresses are accessed and, more specifically, how this relates to potential interrupt handling.

My immediate focus is on the memory locations being probed. I see that `REG_TX_RING_BASE` (which is at offset `0x00000`) and `REG_RX_RING_BASE` (at offset `0x08000`) are being accessed. Crucially, the calculation involves adding `ring->hop * 16` to these base addresses.

Now, I'm considering the potential range of this `ring->hop` value. The text explicitly states that `hop` is at most `hop_count`, and gives an example of `hop_count` being `256`. This means that the `ring->hop * 16` portion can reach a maximum of `256 * 16`, which equals `4096`.

My next step is to evaluate the upper bound of these memory accesses. If I take the larger of the two base addresses, `0x08000` (for `REG_RX_RING_BASE`), and add the maximum offset of `4096`, I arrive at `0x08000 + 4096`. This sum is `0x09000`.

I'm then performing a quick sanity check against a known limit, `0x39640`. The calculated address of `0x09000` is comfortably *below* this limit. This is an important observation, as it suggests that the ring accesses, even at their maximum extent, are within an expected and valid memory region, not venturing into an area that would immediately raise a red flag for memory corruption or out-of-bounds access in this context.

Following this address analysis, my attention shifts to the function `ring_interrupt_active` located in `drivers/thunderbolt/nhi.c`. This is a natural progression because ring operations are intrinsically linked to interrupt mechanisms. I need to understand how this specific function is implemented to determine its role in the interrupt handling pipeline and how it interacts with the ring structures I was just examining. So, my next logical step is to delve into the source code of `ring_interrupt_active` to grasp its internal workings.


163/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:ring_interrupt_active]

Results:
map[SourceCode:  71:	/*
  72:	 * ring_interrupt_active() - activate/deactivate interrupts for a single ring
  73:	 *
  74:	 * ring->nhi->lock must be held.
  75:	 */
  76:	static void ring_interrupt_active(struct tb_ring *ring, bool active)
  77:	{
  78:		int index = ring_interrupt_index(ring) / 32 * 4;
  79:		int reg = REG_RING_INTERRUPT_BASE + index;
  80:		int interrupt_bit = ring_interrupt_index(ring) & 31;
  81:		int mask = 1 << interrupt_bit;
  82:		u32 old, new;
  83:	
  84:		if (ring->irq > 0) {
  85:			u32 step, shift, ivr, misc, itr;
  86:			void __iomem *ivr_base;
  87:			int auto_clear_bit;
  88:			int index;
  89:	
  90:			if (ring->is_tx)
  91:				index = ring->hop;
  92:			else
  93:				index = ring->hop + ring->nhi->hop_count;
  94:	
  95:			/*
  96:			 * Intel routers support a bit that isn't part of
  97:			 * the USB4 spec to ask the hardware to clear
  98:			 * interrupt status bits automatically since
  99:			 * we already know which interrupt was triggered.
 100:			 *
 101:			 * Other routers explicitly disable auto-clear
 102:			 * to prevent conditions that may occur where two
 103:			 * MSIX interrupts are simultaneously active and
 104:			 * reading the register clears both of them.
 105:			 */
 106:			misc = ioread32(ring->nhi->iobase + REG_DMA_MISC);
 107:			if (ring->nhi->quirks & QUIRK_AUTO_CLEAR_INT)
 108:				auto_clear_bit = REG_DMA_MISC_INT_AUTO_CLEAR;
 109:			else
 110:				auto_clear_bit = REG_DMA_MISC_DISABLE_AUTO_CLEAR;
 111:			if (!(misc & auto_clear_bit))
 112:				iowrite32(misc | auto_clear_bit,
 113:					  ring->nhi->iobase + REG_DMA_MISC);
 114:	
 115:			ivr_base = ring->nhi->iobase + REG_INT_VEC_ALLOC_BASE;
 116:			step = index / REG_INT_VEC_ALLOC_REGS * REG_INT_VEC_ALLOC_BITS;
 117:			shift = index % REG_INT_VEC_ALLOC_REGS * REG_INT_VEC_ALLOC_BITS;
 118:			ivr = ioread32(ivr_base + step);
 119:			ivr &= ~(REG_INT_VEC_ALLOC_MASK << shift);
 120:			if (active)
 121:				ivr |= ring->vector << shift;
 122:			iowrite32(ivr, ivr_base + step);
 123:	
 124:			/* Throttling is specified in 256ns increments */
 125:			itr = DIV_ROUND_UP(ring->interval_nsec, 256);
 126:			itr &= REG_INT_THROTTLING_RATE_INTERVAL_MASK;
 127:			iowrite32(itr, ring->nhi->iobase + REG_INT_THROTTLING_RATE +
 128:				  ring->vector * 4);
 129:		}
 130:	
 131:		old = ioread32(ring->nhi->iobase + reg);
 132:		if (active)
 133:			new = old | mask;
 134:		else
 135:			new = old & ~mask;
 136:	
 137:		dev_dbg(ring->nhi->dev,
 138:			"%s interrupt at register %#x bit %d (%#x -> %#x)\n",
 139:			active ? "enabling" : "disabling", reg, interrupt_bit, old, new);
 140:	
 141:		if (new == old)
 142:			dev_WARN(ring->nhi->dev, "interrupt for %s %d is already %s\n",
 143:				 RING_TYPE(ring), ring->hop,
 144:				 str_enabled_disabled(active));
 145:	
 146:		if (active)
 147:			iowrite32(new, ring->nhi->iobase + reg);
 148:		else
 149:			nhi_mask_interrupt(ring->nhi, mask, index);
 150:	}
 SourceFile:drivers/thunderbolt/nhi.c]

164/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 53810
							output: 38
							thoughts: 167
						

Thoughts:
**My Thought Process on Examining `ring_options_base`**

Ah, I'm looking into the `ring_options_base` function within `drivers/thunderbolt/nhi.c`. My immediate inclination is to understand precisely what memory-mapped registers this function interacts with, as this is critical for comprehending how the system manages ring buffer operations and interrupt handling.

My analysis shows that the function accesses several key registers. First, I see it's reading from `REG_DMA_MISC` located at offset `0x39864`. This register likely contains miscellaneous DMA-related configuration or status information, so understanding its contents will be important.

Next, I note an access to `REG_INT_VEC_ALLOC_BASE`, which is at offset `0x38c40`. What's particularly interesting here is that this base address is being combined with a `step` value. This suggests that `REG_INT_VEC_ALLOC_BASE` might be an array or a block of registers, and the `step` is used to select a specific entry within that block, likely for allocating or managing interrupt vectors. The fact that `step` is described as "small" implies it's an offset, not a large stride, further supporting the idea of accessing individual elements within a contiguous memory region.

Following that, I observe an interaction with `REG_INT_THROTTLING_RATE` at offset `0x38c00`. Here, the base address is modified by `ring->vector * 4`. This calculation implies that interrupt throttling rates are configurable on a per-vector basis. The multiplication by 4 strongly suggests that each vector's throttling rate information is stored in a 32-bit (4-byte) register. Again, the term "small" used for `ring->vector` indicates a direct lookup or a small calculation to pinpoint the relevant throttling setting for a particular interrupt vector associated with the `ring` structure.

Finally, I see an access to `REG_RING_INTERRUPT_BASE` located at offset `0x38200`, again combined with an `index`. This pattern is very common for accessing elements within a ring buffer or a set of associated interrupt control registers. The `index` is likely used to identify a specific ring's interrupt configuration. The description "small" for `index` reinforces the notion that it's a direct offset to select a specific ring's interrupt control parameters within the `REG_RING_INTERRUPT_BASE` region.

In summary, my initial thoughts are focused on mapping these register accesses to their functional roles in DMA, interrupt vector allocation, interrupt throttling, and ring buffer interrupt management. Each of these registers, when combined with the provided offsets and dynamic values (`step`, `ring->vector * 4`, `index`), tells a story about how the Thunderbolt NHI driver configures and controls hardware interactions.


165/4 2026/08/10 08:36 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:ring_options_base]

Results:
map[SourceCode: 179:	static void __iomem *ring_options_base(struct tb_ring *ring)
 180:	{
 181:		void __iomem *io = ring->nhi->iobase;
 182:		io += ring->is_tx ? REG_TX_OPTIONS_BASE : REG_RX_OPTIONS_BASE;
 183:		io += ring->hop * 32;
 184:		return io;
 185:	}
 SourceFile:drivers/thunderbolt/nhi.c]

166/4 2026/08/10 08:36 llm codeexpert
0m Model:
gemini-3.5-flash

Tokens:
							input: 54151
							output: 709
							thoughts: 1217
						

Thoughts:
**My Rigorous Investigation into Thunderbolt NHI Register Offsets**

My exploration into the memory-mapped I/O (MMIO) space utilized by the Thunderbolt NHI driver has yielded a definitive understanding of register accesses beyond a specific threshold. Initially, I considered accesses to `REG_TX_OPTIONS_BASE` or `REG_RX_OPTIONS_BASE` combined with a `ring->hop` offset. However, my calculations showed that `hop * 32`, with `hop` at its maximum of `hop_count` (e.g., 256), would result in an offset of at most `8192`. This means addresses like `0x29800 + 8192 = 0x2b800`, which are comfortably below the `0x39640` mark we are concerned with.

This initial assessment led me to a much deeper and more comprehensive analysis. I can confidently state that, yes, there are indeed registers accessed by the Thunderbolt NHI driver that possess offsets *larger* than `0x39640`. My rigorous verification process involved two key steps:

1.  **Exhaustive Source Code Search:** I meticulously scoured the *entire* Linux kernel source tree for all references to `nhi->iobase`, which represents the MMIO base pointer of the NHI. This ensured that I captured every single register access within the driver.
2.  **Definition Verification:** Simultaneously, I cross-referenced these accesses with all definitions present in `drivers/thunderbolt/nhi_regs.h`. This guarantees that the registers I identified are indeed formally defined and utilized by the driver.

Through this comprehensive process, I have identified the following registers with offsets exceeding `0x39640`:

*   **`REG_DMA_MISC`**: Located at offset **`0x39864`**. This register is crucial for configuring various DMA miscellaneous settings. For instance, it's used to control the automatic clearing of interrupt status bits. I found its usage primarily within the `ring_interrupt_active()` function in `drivers/thunderbolt/nhi.c`.

*   **`REG_RESET`**: Situated at offset **`0x39898`**. This register plays a vital role in initiating a host router reset (HRR), particularly for routers version 2 and later. Its access is clearly documented in the `nhi_reset()` function within `drivers/thunderbolt/nhi.c`.

*   **`REG_INMAIL_DATA`**: Found at offset **`0x39900`**. This register is dedicated to writing data associated with incoming mailbox commands. My investigation points to its utilization in the `nhi_mailbox_cmd()` function in `drivers/thunderbolt/nhi.c`.

*   **`REG_INMAIL_CMD`**: Located at offset **`0x39904`**. This register is used for both sending incoming mailbox commands and subsequently checking their completion status or any errors encountered. Similar to `REG_INMAIL_DATA`, its access is confirmed within `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

*   **`REG_OUTMAIL_CMD`**: Positioned at offset **`0x3990c`**. This register is instrumental in reading the current operational mode of the firmware from the outgoing mailbox command register. I've observed its use in the `nhi_mailbox_mode()` function within `drivers/thunderbolt/nhi.c`.

*   **`REG_FW_STS`**: The final register in this category, found at offset **`0x39944`**. This register is fundamental for querying the status of the firmware. It provides insights into whether the ICM firmware is actively running, if NVM authentication has been completed, and can even be used to request a CIO reset. My analysis shows its usage across several functions in `drivers/thunderbolt/icm.c`, including `icm_firmware_running()`, `icm_ar_get_mode()`, `icm_tgl_is_supported()`, `icm_firmware_reset()`, and `icm_firmware_start()`.

My confidence in this list is exceptionally high, as it stems from a thorough, step-by-step examination of the kernel's codebase, ensuring that no access or definition was overlooked.


167/4 2026/08/10 08:36 tool set-results
0m Args:
map[Answer:Yes, there are several other registers accessed by the thunderbolt NHI (Native Host Interface) driver that have offsets larger than `0x39640` (which is `REG_CAPS`). 

These registers are defined in `drivers/thunderbolt/nhi_regs.h` and accessed via the NHI MMIO base pointer (`nhi->iobase`) in `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/icm.c`:

1. **`REG_DMA_MISC`** (Offset: **`0x39864`**)
   - **Description:** Used to configure DMA miscellaneous settings, such as enabling or disabling automatic clearing of interrupt status bits (`REG_DMA_MISC_INT_AUTO_CLEAR` / `REG_DMA_MISC_DISABLE_AUTO_CLEAR`).
   - **Accessed in:** `ring_interrupt_active()` in `drivers/thunderbolt/nhi.c`.

2. **`REG_RESET`** (Offset: **`0x39898`**)
   - **Description:** Used to trigger and poll a host router reset (`REG_RESET_HRR`) for v2 and later routers.
   - **Accessed in:** `nhi_reset()` in `drivers/thunderbolt/nhi.c`.

3. **`REG_INMAIL_DATA`** (Offset: **`0x39900`**)
   - **Description:** Used to write data associated with an incoming mailbox command to the firmware.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

4. **`REG_INMAIL_CMD`** (Offset: **`0x39904`**)
   - **Description:** Used to send incoming mailbox commands to the firmware and check for completion or errors.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

5. **`REG_OUTMAIL_CMD`** (Offset: **`0x3990c`**)
   - **Description:** Used to read the current firmware operation mode from the outgoing mailbox command register.
   - **Accessed in:** `nhi_mailbox_mode()` in `drivers/thunderbolt/nhi.c`.

6. **`REG_FW_STS`** (Offset: **`0x39944`**)
   - **Description:** Used to check the firmware status, such as whether the ICM (Internal Connection Manager) firmware is running, NVM authentication is done, or to request a CIO reset.
   - **Accessed in:** Several functions in `drivers/thunderbolt/icm.c` (including `icm_firmware_running()`, `icm_ar_get_mode()`, `icm_tgl_is_supported()`, `icm_firmware_reset()`, and `icm_firmware_start()`).

All other registers accessed by the driver (such as ring bases, ring options, and interrupt/throttling registers) have offsets below `0x39640`.]

Results:
map[Answer:Yes, there are several other registers accessed by the thunderbolt NHI (Native Host Interface) driver that have offsets larger than `0x39640` (which is `REG_CAPS`). 

These registers are defined in `drivers/thunderbolt/nhi_regs.h` and accessed via the NHI MMIO base pointer (`nhi->iobase`) in `drivers/thunderbolt/nhi.c` and `drivers/thunderbolt/icm.c`:

1. **`REG_DMA_MISC`** (Offset: **`0x39864`**)
   - **Description:** Used to configure DMA miscellaneous settings, such as enabling or disabling automatic clearing of interrupt status bits (`REG_DMA_MISC_INT_AUTO_CLEAR` / `REG_DMA_MISC_DISABLE_AUTO_CLEAR`).
   - **Accessed in:** `ring_interrupt_active()` in `drivers/thunderbolt/nhi.c`.

2. **`REG_RESET`** (Offset: **`0x39898`**)
   - **Description:** Used to trigger and poll a host router reset (`REG_RESET_HRR`) for v2 and later routers.
   - **Accessed in:** `nhi_reset()` in `drivers/thunderbolt/nhi.c`.

3. **`REG_INMAIL_DATA`** (Offset: **`0x39900`**)
   - **Description:** Used to write data associated with an incoming mailbox command to the firmware.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

4. **`REG_INMAIL_CMD`** (Offset: **`0x39904`**)
   - **Description:** Used to send incoming mailbox commands to the firmware and check for completion or errors.
   - **Accessed in:** `nhi_mailbox_cmd()` in `drivers/thunderbolt/nhi.c`.

5. **`REG_OUTMAIL_CMD`** (Offset: **`0x3990c`**)
   - **Description:** Used to read the current firmware operation mode from the outgoing mailbox command register.
   - **Accessed in:** `nhi_mailbox_mode()` in `drivers/thunderbolt/nhi.c`.

6. **`REG_FW_STS`** (Offset: **`0x39944`**)
   - **Description:** Used to check the firmware status, such as whether the ICM (Internal Connection Manager) firmware is running, NVM authentication is done, or to request a CIO reset.
   - **Accessed in:** Several functions in `drivers/thunderbolt/icm.c` (including `icm_firmware_running()`, `icm_ar_get_mode()`, `icm_tgl_is_supported()`, `icm_firmware_reset()`, and `icm_firmware_start()`).

All other registers accessed by the driver (such as ring bases, ring options, and interrupt/throttling registers) have offsets below `0x39640`.]

168/2 2026/08/10 08:36 llm initial-researcher
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 60414
							output: 1734
							thoughts: 86
						

Thoughts:
**My Thought Process Regarding the BAR Size and Reproducer Strategy**

My immediate concern here is the BAR (Base Address Register) size. I've identified the maximum offset required, which is `0x39944`, corresponding to `REG_FW_STS`. This clearly dictates the minimum BAR size necessary to encompass this register without going out of bounds. Therefore, I've concluded that the BAR size *must* be at least `0x39948`. Given standard memory alignment practices, it's more likely to be `0x3a000` after rounding up, but the critical point is that any size smaller than `0x39948` will inevitably lead to an Out-Of-Bounds (OOB) access.

With this crucial understanding of the BAR size requirement established, I'm confident in the reproducer strategy I've devised. It seems sound and directly addresses the identified vulnerability. I can now proceed to finalize and present the findings.


169/1 2026/08/10 08:37 loop
10m
170/2 2026/08/10 08:37 iteration 0
3m
171/3 2026/08/10 08:37 action If
0m Args:
map[OracleFeedback:]

172/3 2026/08/10 08:37 action merge-strategy
0m Results:
map[CurrentReproStrategy:An analysis of the bug report and the kernel source code reveals that the crash is caused by an out-of-bounds memory access during the PCI probe of the Thunderbolt Native Host Interface (NHI) driver.

### Root Cause Analysis

1. **Missing BAR Size Validation**: 
   In `nhi_pci_probe()` (`drivers/thunderbolt/pci.c`), the driver maps the device's PCI BAR 0 using `pcim_iomap_region(pdev, 0, "thunderbolt")`. However, it never checks if the size of BAR 0 is large enough to cover the MMIO registers it expects to access.

2. **Out-of-Bounds Access**:
   The NHI driver expects a BAR size of at least `0x39948` bytes (to cover registers up to `REG_FW_STS` at `0x39944`). If a device with a small BAR 0 (e.g., 4KB) is bound to the driver, `ioremap` will only map that small region.
   When `nhi_probe()` is subsequently called, it attempts to read `REG_CAPS` at offset `0x39640`:
   ```c
   nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
   ```
   Because `0x39640` is far beyond the mapped 4KB region, this constitutes an out-of-bounds access.

3. **Crash Context**:
   In the syzkaller report, the initial OOB read at `0x39640` likely fell into another coincidentally mapped vmalloc page, returning garbage data. This garbage data allowed the driver to proceed to `nhi_reset()` (which timed out, printing `"timeout resetting host router"`) and then to `nhi_disable_interrupts()`. 
   `nhi_disable_interrupts()` then attempted to write to `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at offset `0x38208`. This offset fell into an unmapped vmalloc page, triggering the `#PF: supervisor write access in kernel mode` page fault in `iowrite32()`.

### Reproduction Strategy

To reproduce this bug, we need to trick the `thunderbolt` driver into probing a PCI device that has a memory BAR 0 smaller than `0x3a000`. We can achieve this from a standalone C program by abusing the sysfs `new_id` and `bind` interfaces to force the driver to bind to an existing, non-Thunderbolt PCI device with a small BAR.

1. **Scan PCI Devices**: Iterate through `/sys/bus/pci/devices/` to find a candidate PCI device.
2. **Filter Candidates**: 
   - Skip critical devices like Host/ISA bridges (Class `0x06xxxx`) and Mass Storage controllers (Class `0x01xxxx`) to prevent freezing the system or unmounting the rootfs.
   - Read the `resource` file to ensure BAR 0 is a memory BAR (`flags & IORESOURCE_MEM`) and its size is greater than 0 but strictly less than `0x39640`.
3. **Force Bind**:
   - Write the candidate device's name to its current driver's `unbind` file.
   - Write the candidate's Vendor and Device ID to `/sys/bus/pci/drivers/thunderbolt/new_id`.
   - Write the candidate's device name to `/sys/bus/pci/drivers/thunderbolt/bind`.
4. **Trigger**: The `thunderbolt` driver will probe the device, map its small BAR 0, and immediately perform an out-of-bounds MMIO access when reading/writing high-offset registers, reproducing the crash.

### Minimal C Reproducer Outline

```c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>

int main() {
    // Ensure the thunderbolt module is loaded
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) return 1;

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        fscanf(f, "%x", &class_code);
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start, end, flags;
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        if (size > 0 && size < 0x39640) {
            unsigned int vendor, device;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &vendor); fclose(f);

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &device); fclose(f);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            f = fopen(path, "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }

            // 2. Add ID to thunderbolt driver
            f = fopen("/sys/bus/pci/drivers/thunderbolt/new_id", "w");
            if (f) { fprintf(f, "%x %x", vendor, device); fclose(f); }

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            f = fopen("/sys/bus/pci/drivers/thunderbolt/bind", "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }
            
            // The kernel should panic here.
            break;
        }
    }
    closedir(dir);
    return 0;
}
```]

173/3 2026/08/10 08:37 agent repro-generator
0m Model:
best-expensive

Results:
map[IsProbe:true RawCandidateReproC:#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}
]

Instruction:
You are a security researcher with deep Linux kernel background.
Your goal is to generate a minimal, standalone C program for the strictly defensive
purpose of verifying a bugfix in an isolated environment.

To ensure that we can diagnose why a program might fail to run on the test environment,
you MUST include detailed logging and error checking in the generated C program:
1. Use 'printf(...)' for all progress messages and error logs.
2. Every system call (e.g., socket, bind, listen, connect, ioctl, send) must check for a failure return value.
3. If a call fails, it must print a specific error message including the function name
   and the error string (use strerror(errno)), and then exit with a non-zero status.
4. The program must print a message after every successful major step.
5. Generate code that follows this pattern for all operations:
    int res = do_something();
    if (res < 0) {
        printf("[-] Failed to do_something: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] do_something successful.\n");
6. The compilation and development environment (including compilers, build
   systems, makefiles, and kernel build/header directories) is NOT available
   on the target test VM guest. Do NOT check for, build, or reference any
   compilation tools, build files, or kernel development directories.
7. Do NOT execute shell commands or run external binaries (e.g. by using
   functions like 'system()', 'popen()', or the 'exec' family such as
   'execve()'). All environment checks, capability probings, and reproduction
   steps must be performed directly using standard Linux system calls (such
   as 'open', 'socket', 'ioctl', 'stat', etc.).
8. When reproducing asynchronous kernel timeouts or warnings, always
   include a sufficient delay (using sleep or similar) after deleting
   or unregistering the device to allow the kernel's asynchronous
   timeout to trigger before program exit.


=== PHASE 1: CAPABILITY PROBING (GENERATION) ===
You MUST start by generating a simple 'probe' program first. This is a strict, non-negotiable requirement
to verify that the test environment has the necessary kernel capabilities and privileges.
This program's sole purpose is to verify subsystem availability and privileges by probing specific
device files, subsystems, or syscalls (for example: opening /dev/vhci to check if the virtual
Bluetooth controller is accessible, loading a minimal dummy BPF program, or making a specific
socket/ioctl call).

Print clear messages indicating success or failure of these probes, and exit with 0 only if
all checks pass.
Do NOT attempt complex logic, and do NOT try to trigger the actual bug/crash in this first version,
regardless of how simple the reproducer seems. You must wait until a successful probe run has been
confirmed in the environment (i.e., when CapabilitiesVerified becomes true).

Prefer calling several tools at the same time to save round-trips.


Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

Strategy: An analysis of the bug report and the kernel source code reveals that the crash is caused by an out-of-bounds memory access during the PCI probe of the Thunderbolt Native Host Interface (NHI) driver.

### Root Cause Analysis

1. **Missing BAR Size Validation**: 
   In `nhi_pci_probe()` (`drivers/thunderbolt/pci.c`), the driver maps the device's PCI BAR 0 using `pcim_iomap_region(pdev, 0, "thunderbolt")`. However, it never checks if the size of BAR 0 is large enough to cover the MMIO registers it expects to access.

2. **Out-of-Bounds Access**:
   The NHI driver expects a BAR size of at least `0x39948` bytes (to cover registers up to `REG_FW_STS` at `0x39944`). If a device with a small BAR 0 (e.g., 4KB) is bound to the driver, `ioremap` will only map that small region.
   When `nhi_probe()` is subsequently called, it attempts to read `REG_CAPS` at offset `0x39640`:
   ```c
   nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
   ```
   Because `0x39640` is far beyond the mapped 4KB region, this constitutes an out-of-bounds access.

3. **Crash Context**:
   In the syzkaller report, the initial OOB read at `0x39640` likely fell into another coincidentally mapped vmalloc page, returning garbage data. This garbage data allowed the driver to proceed to `nhi_reset()` (which timed out, printing `"timeout resetting host router"`) and then to `nhi_disable_interrupts()`. 
   `nhi_disable_interrupts()` then attempted to write to `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at offset `0x38208`. This offset fell into an unmapped vmalloc page, triggering the `#PF: supervisor write access in kernel mode` page fault in `iowrite32()`.

### Reproduction Strategy

To reproduce this bug, we need to trick the `thunderbolt` driver into probing a PCI device that has a memory BAR 0 smaller than `0x3a000`. We can achieve this from a standalone C program by abusing the sysfs `new_id` and `bind` interfaces to force the driver to bind to an existing, non-Thunderbolt PCI device with a small BAR.

1. **Scan PCI Devices**: Iterate through `/sys/bus/pci/devices/` to find a candidate PCI device.
2. **Filter Candidates**: 
   - Skip critical devices like Host/ISA bridges (Class `0x06xxxx`) and Mass Storage controllers (Class `0x01xxxx`) to prevent freezing the system or unmounting the rootfs.
   - Read the `resource` file to ensure BAR 0 is a memory BAR (`flags & IORESOURCE_MEM`) and its size is greater than 0 but strictly less than `0x39640`.
3. **Force Bind**:
   - Write the candidate device's name to its current driver's `unbind` file.
   - Write the candidate's Vendor and Device ID to `/sys/bus/pci/drivers/thunderbolt/new_id`.
   - Write the candidate's device name to `/sys/bus/pci/drivers/thunderbolt/bind`.
4. **Trigger**: The `thunderbolt` driver will probe the device, map its small BAR 0, and immediately perform an out-of-bounds MMIO access when reading/writing high-offset registers, reproducing the crash.

### Minimal C Reproducer Outline

```c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>

int main() {
    // Ensure the thunderbolt module is loaded
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) return 1;

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        fscanf(f, "%x", &class_code);
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start, end, flags;
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        if (size > 0 && size < 0x39640) {
            unsigned int vendor, device;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &vendor); fclose(f);

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &device); fclose(f);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            f = fopen(path, "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }

            // 2. Add ID to thunderbolt driver
            f = fopen("/sys/bus/pci/drivers/thunderbolt/new_id", "w");
            if (f) { fprintf(f, "%x %x", vendor, device); fclose(f); }

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            f = fopen("/sys/bus/pci/drivers/thunderbolt/bind", "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }
            
            // The kernel should panic here.
            break;
        }
    }
    closedir(dir);
    return 0;
}
```




174/4 2026/08/10 08:37 llm repro-generator
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7925
							output: 329
							thoughts: 2284
						

Thoughts:
**Phase 1: Constructing the Initial Probe Program**

My immediate objective is to craft a minimal, standalone C program. This program's singular purpose, as per the strict instructions, is to verify the test environment's capabilities and privileges before I even contemplate attempting to trigger the actual kernel bug. This is a non-negotiable prerequisite, a foundational step to ensure I'm not wasting time on a futile endeavor.

The primary constraint here is to avoid any complex logic or attempts to exploit the bug itself. The probe must be simple, focusing solely on environmental checks. My thought process then turned to what specific capabilities this probe needs to ascertain.

First and foremost, I need to confirm that I have the necessary privileges. In a Linux kernel context, this almost always means root access. So, a check for `getuid() == 0` is essential.

Secondly, the bug is rooted in PCI device MMIO access, specifically within the Thunderbolt driver. This immediately brings `sysfs` to mind as the interface for interacting with PCI devices and drivers. Therefore, I must verify access to the PCI subsystem in `sysfs`. This involves checking if `/sys/bus/pci/devices` exists and is readable, signifying the presence of PCI devices on the system. I also need to confirm access to the broader `/sys/bus/pci/drivers` directory.

A critical point of discussion in my internal monologue was how to check for the presence of the `thunderbolt` driver. The instructions explicitly forbid external commands like `system()` or `popen()`. While I initially considered checking for `/sys/bus/pci/drivers/thunderbolt/new_id`, I realized that this file might not exist if the driver isn't loaded. The challenge then became: how can I load the `thunderbolt` module if it's not loaded, without using forbidden system calls? Syzkaller often relies on built-in kernel options (`CONFIG_THUNDERBOLT=y`) or automatic module loading. Since I cannot actively load it without `init_module` or similar, the most robust approach for this *probe* phase is to simply verify that the PCI subsystem is generally accessible and that I have root privileges. If the `thunderbolt` driver isn't present or loadable, the subsequent phases will inherently fail, but this initial probe must focus on the environment's fundamental readiness.

Therefore, my refined probe program focuses on these core checks:
1.  **Root Privilege Check:** Ensuring `getuid() == 0`.
2.  **PCI Devices Directory Access:** Verifying read access to `/sys/bus/pci/devices`.
3.  **PCI Drivers Directory Access:** Confirming accessibility to `/sys/bus/pci/drivers`.

The output of this program needs to be clear, indicating success or failure for each check. Critically, it must exit with a status code of `0` *only* if all these essential probes pass. Any failure should result in a non-zero exit code, signaling that the environment is not ready.

After constructing and refining this simple C code, I am confident it meets the stringent requirements for Phase 1. I will then proceed to submit this probe, along with the necessary metadata, to `set-results` with `IsProbe: true`.


175/4 2026/08/10 08:37 tool set-results
0m Args:
map[IsProbe:true RawCandidateReproC:#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}
]

Results:
map[IsProbe:true RawCandidateReproC:#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}
]

176/3 2026/08/10 08:37 loop
0m
177/4 2026/08/10 08:37 iteration 0
0m
178/5 2026/08/10 08:37 action merge-repro-c
0m Results:
map[CurrentCandidateReproC:#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}
]

179/5 2026/08/10 08:37 action compile-c-prog
0m Results:
map[CompilerError: FormattedReproC:#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}
]

180/5 2026/08/10 08:37 action If
0m Args:
map[CompilerError:]

181/3 2026/08/10 08:37 action run-c-repro
2m Results:
map[CandidateBugTitle: CandidateCrashReport: CandidateReproduced:false ConsoleOutput:[   72.479975][ T1385] ieee802154 phy0 wpan0: encryption failed: -22
[   72.482008][ T1385] ieee802154 phy1 wpan1: encryption failed: -22
Warning: Permanently added '[localhost]:55238' (ED25519) to the list of known hosts.
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
[   82.725531][   T32] cfg80211: failed to load regulatory.db
 OtherCrashReports:<nil> StraceOutput:/strace -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f /syz-executor2454214732

<...>
Warning: Permanently added '[localhost]:12232' (ED25519) to the list of known hosts.
execve("/syz-executor2454214732", ["/syz-executor2454214732"], 0x7fff55435670 /* 11 vars */) = 0
brk(NULL)                               = 0x55555dce0000
brk(0x55555dce0d80)                     = 0x55555dce0d80
arch_prctl(ARCH_SET_FS, 0x55555dce0400) = 0
set_tid_address(0x55555dce06d0)         = 5901
set_robust_list(0x55555dce06e0, 24)     = 0
rseq({cpu_id_start=0, cpu_id=RSEQ_CPU_ID_UNINITIALIZED, rseq_cs=NULL, flags=0, node_id=0, mm_cid=0, slice_ctrl={request=0, granted=0, __reserved=0}, __reserved=0}, 33, 0, 0x53053053) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0
readlinkat(AT_FDCWD, "/proc/self/exe", "/syz-executor2454214732", 4096) = 23
getrandom("\xa8\xd1\xd3\x65\x22\x1e\xc7\xc6", 8, GRND_NONBLOCK) = 8
brk(NULL)                               = 0x55555dce0d80
brk(0x55555dd01d80)                     = 0x55555dd01d80
brk(0x55555dd02000)                     = 0x55555dd02000
mprotect(0x7f3c34947000, 20480, PROT_READ) = 0
fstat(1, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
getuid()                                = 0
openat(AT_FDCWD, "/sys/bus/pci/devices", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
fstat(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
close(3)                                = 0
access("/sys/bus/pci/drivers", F_OK)    = 0
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
write(1, "[*] Starting capability probe...\n[+] Running as root.\n[+] /sys/bus/pci/devices opened successfully.\n"..., 176) = 176
exit_group(0)                           = ?
+++ exited with 0 +++
[   71.661040][ T1382] ieee802154 phy0 wpan0: encryption failed: -22
[   71.663161][ T1382] ieee802154 phy1 wpan1: encryption failed: -22
 TestError:]

182/3 2026/08/10 08:40 action truncate-log
0m Results:
map[TruncatedConsoleOutput:[   72.479975][ T1385] ieee802154 phy0 wpan0: encryption failed: -22
[   72.482008][ T1385] ieee802154 phy1 wpan1: encryption failed: -22
Warning: Permanently added '[localhost]:55238' (ED25519) to the list of known hosts.
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
[   82.725531][   T32] cfg80211: failed to load regulatory.db
 TruncatedCrashReport: TruncatedStraceOutput:/strace -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f /syz-executor2454214732

<...>
Warning: Permanently added '[localhost]:12232' (ED25519) to the list of known hosts.
execve("/syz-executor2454214732", ["/syz-executor2454214732"], 0x7fff55435670 /* 11 vars */) = 0
brk(NULL)                               = 0x55555dce0000
brk(0x55555dce0d80)                     = 0x55555dce0d80
arch_prctl(ARCH_SET_FS, 0x55555dce0400) = 0
set_tid_address(0x55555dce06d0)         = 5901
set_robust_list(0x55555dce06e0, 24)     = 0
rseq({cpu_id_start=0, cpu_id=RSEQ_CPU_ID_UNINITIALIZED, rseq_cs=NULL, flags=0, node_id=0, mm_cid=0, slice_ctrl={request=0, granted=0, __reserved=0}, __reserved=0}, 33, 0, 0x53053053) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0
readlinkat(AT_FDCWD, "/proc/self/exe", "/syz-executor2454214732", 4096) = 23
getrandom("\xa8\xd1\xd3\x65\x22\x1e\xc7\xc6", 8, GRND_NONBLOCK) = 8
brk(NULL)                               = 0x55555dce0d80
brk(0x55555dd01d80)                     = 0x55555dd01d80
brk(0x55555dd02000)                     = 0x55555dd02000
mprotect(0x7f3c34947000, 20480, PROT_READ) = 0
fstat(1, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
getuid()                                = 0
openat(AT_FDCWD, "/sys/bus/pci/devices", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
fstat(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
close(3)                                = 0
access("/sys/bus/pci/drivers", F_OK)    = 0
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
write(1, "[*] Starting capability probe...\n[+] Running as root.\n[+] /sys/bus/pci/devices opened successfully.\n"..., 176) = 176
exit_group(0)                           = ?
+++ exited with 0 +++
[   71.661040][ T1382] ieee802154 phy0 wpan0: encryption failed: -22
[   71.663161][ T1382] ieee802154 phy1 wpan1: encryption failed: -22
]

183/3 2026/08/10 08:40 agent repro-oracle
0m Model:
best-expensive

Results:
map[Feedback:The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer. ProbePassed:true TerminalError: TitleMatches:false]

Instruction:
You are a security researcher with deep Linux kernel background.
Analyze the results of running the generated program.

=== CRITICAL ENVIRONMENT & TARGET CLASSIFICATION ===
Set 'TerminalError' to a descriptive error message ONLY if:
1. The execution failed due to missing hardware device nodes, subsystems, kernel modules, or privilege limits
   that cannot be loaded, created, or bypassed by user-space C code edits in the VM guest.
2. The target source files or functions described in the bug description do not exist in the checked-out codebase,
   meaning the codebase version is mismatched and the target code is absent.

=== CRITICAL PROHIBITIONS ===
- Do NOT classify a run as a terminal failure or assume a bug is fixed based on git log entries, commit titles,
  or commit messages. Reproducibility can ONLY be determined by executing reproducer candidates in the VM.
- Do NOT suggest C code strategies, repairs, or namespace bypasses when setting 'TerminalError'.


=== PHASE 1: CAPABILITY PROBING (EVALUATION) ===
The executed program was a simple environment probe.
Use this to guide your classification and feedback:
1. If the execution was successful (all environment/subsystem probes passed and program exited with 0),
   set the field 'ProbePassed' to true and provide feedback explicitly indicating that the environment
   is ready and the agent should now proceed to generate the full reproducer in the next iteration.
2. If the probe failed (e.g., missing permissions, missing devices, or sandbox restrictions),
   set the field 'ProbePassed' to false, and explain what failed in the 'Feedback'
   field so the generator can adjust its setups.

Prefer calling several tools at the same time to save round-trips.


Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

IsProbe: true
Reproduced: false
Console Output: [   72.479975][ T1385] ieee802154 phy0 wpan0: encryption failed: -22
[   72.482008][ T1385] ieee802154 phy1 wpan1: encryption failed: -22
Warning: Permanently added '[localhost]:55238' (ED25519) to the list of known hosts.
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
[   82.725531][   T32] cfg80211: failed to load regulatory.db

Strace Output: /strace -e \!wait4,clock_nanosleep,nanosleep -s 100 -x -f /syz-executor2454214732

<...>
Warning: Permanently added '[localhost]:12232' (ED25519) to the list of known hosts.
execve("/syz-executor2454214732", ["/syz-executor2454214732"], 0x7fff55435670 /* 11 vars */) = 0
brk(NULL)                               = 0x55555dce0000
brk(0x55555dce0d80)                     = 0x55555dce0d80
arch_prctl(ARCH_SET_FS, 0x55555dce0400) = 0
set_tid_address(0x55555dce06d0)         = 5901
set_robust_list(0x55555dce06e0, 24)     = 0
rseq({cpu_id_start=0, cpu_id=RSEQ_CPU_ID_UNINITIALIZED, rseq_cs=NULL, flags=0, node_id=0, mm_cid=0, slice_ctrl={request=0, granted=0, __reserved=0}, __reserved=0}, 33, 0, 0x53053053) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0
readlinkat(AT_FDCWD, "/proc/self/exe", "/syz-executor2454214732", 4096) = 23
getrandom("\xa8\xd1\xd3\x65\x22\x1e\xc7\xc6", 8, GRND_NONBLOCK) = 8
brk(NULL)                               = 0x55555dce0d80
brk(0x55555dd01d80)                     = 0x55555dd01d80
brk(0x55555dd02000)                     = 0x55555dd02000
mprotect(0x7f3c34947000, 20480, PROT_READ) = 0
fstat(1, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
getuid()                                = 0
openat(AT_FDCWD, "/sys/bus/pci/devices", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
fstat(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
close(3)                                = 0
access("/sys/bus/pci/drivers", F_OK)    = 0
[*] Starting capability probe...
[+] Running as root.
[+] /sys/bus/pci/devices opened successfully.
[+] /sys/bus/pci/drivers is accessible.
[+] All probes passed successfully.
write(1, "[*] Starting capability probe...\n[+] Running as root.\n[+] /sys/bus/pci/devices opened successfully.\n"..., 176) = 176
exit_group(0)                           = ?
+++ exited with 0 +++
[   71.661040][ T1382] ieee802154 phy0 wpan0: encryption failed: -22
[   71.663161][ T1382] ieee802154 phy1 wpan1: encryption failed: -22

Crash Report: 


184/4 2026/08/10 08:40 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7292
							output: 51
							thoughts: 223
						

Thoughts:
**Capability Probe Analysis**

My primary task here is to interpret the outcome of a capability probe that was just executed. I need to meticulously analyze the results to determine the next steps.

Upon reviewing the probe's output, I see the confirmation: `[+] All probes passed successfully.` and the clean exit code `exit_group(0)`. This is unambiguous. It means the probe completed its intended checks without encountering any issues. Therefore, my immediate conclusion is that I must reflect this success in my internal state. I will set the `ProbePassed` flag to `true`.

Concurrently, I need to assess the other relevant parameters. Since the probe passed, there's no indication of a terminal error, so I will ensure `TerminalError` is cleared, setting it to an empty state. The probe's purpose was to test certain capabilities, not to trigger a crash that would directly match a bug's title. Hence, I'll set `TitleMatches` to `false`, as no crash occurred that would align with the bug description.

Now, I need to formulate the user-facing feedback. Given the successful probe, my message should clearly communicate this positive outcome and guide the user accordingly. I'll inform them that the capability probe was successful, indicating that the environment is in a ready state. Crucially, I'll then instruct them to proceed with generating the full reproducer, as this is the logical next step after a successful capability validation.


185/4 2026/08/10 08:40 tool set-results
0m Args:
map[Feedback:The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer. ProbePassed:true TerminalError: TitleMatches:false]

Results:
map[Feedback:The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer. ProbePassed:true TerminalError: TitleMatches:false]

186/3 2026/08/10 08:40 action loop-controller
0m Results:
map[CapabilitiesVerified:true ContinueSignal:continue EquivalenceAnalysis: OracleFeedback:The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer. ReproC: Reproduced:false ReproducedBugTitle: ReproducedCrashReport:]

187/2 2026/08/10 08:40 iteration 1
6m
188/3 2026/08/10 08:40 action If
0m Args:
map[OracleFeedback:The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer.]

189/4 2026/08/10 08:40 agent strategy-refiner
0m Model:
best-expensive

Instruction:
You are an expert in Linux kernel debugging.
Refine the reproduction strategy based on feedback from previous attempts.
Analyze the technical diagnosis provided in the oracle feedback and translate it into concrete,
step-by-step instructions for the repro-generator on how to modify the code structure, alignments,
offsets, or parameters of the candidate program.

=== TOOL SELECTION GUIDELINES ===
- Prefer codesearch-definition-source and codesearch-struct-layout first for symbol lookups.
- Fall back to read-file or grepper for macros, headers, or if symbol lookup fails.

=== CRITICAL PROHIBITIONS ===
- Do NOT repeat searches for the same symbols or files. Use information you have already gathered.
- Do NOT write long explanations. Keep your reasoning short and focused on actionable changes.
- Do NOT assume a bug is fixed based on git commit history.
- If you are stuck, try a different approach or proceed to generate a candidate reproducer.
Prefer calling several tools at the same time to save round-trips.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

Current Strategy: An analysis of the bug report and the kernel source code reveals that the crash is caused by an out-of-bounds memory access during the PCI probe of the Thunderbolt Native Host Interface (NHI) driver.

### Root Cause Analysis

1. **Missing BAR Size Validation**: 
   In `nhi_pci_probe()` (`drivers/thunderbolt/pci.c`), the driver maps the device's PCI BAR 0 using `pcim_iomap_region(pdev, 0, "thunderbolt")`. However, it never checks if the size of BAR 0 is large enough to cover the MMIO registers it expects to access.

2. **Out-of-Bounds Access**:
   The NHI driver expects a BAR size of at least `0x39948` bytes (to cover registers up to `REG_FW_STS` at `0x39944`). If a device with a small BAR 0 (e.g., 4KB) is bound to the driver, `ioremap` will only map that small region.
   When `nhi_probe()` is subsequently called, it attempts to read `REG_CAPS` at offset `0x39640`:
   ```c
   nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
   ```
   Because `0x39640` is far beyond the mapped 4KB region, this constitutes an out-of-bounds access.

3. **Crash Context**:
   In the syzkaller report, the initial OOB read at `0x39640` likely fell into another coincidentally mapped vmalloc page, returning garbage data. This garbage data allowed the driver to proceed to `nhi_reset()` (which timed out, printing `"timeout resetting host router"`) and then to `nhi_disable_interrupts()`. 
   `nhi_disable_interrupts()` then attempted to write to `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at offset `0x38208`. This offset fell into an unmapped vmalloc page, triggering the `#PF: supervisor write access in kernel mode` page fault in `iowrite32()`.

### Reproduction Strategy

To reproduce this bug, we need to trick the `thunderbolt` driver into probing a PCI device that has a memory BAR 0 smaller than `0x3a000`. We can achieve this from a standalone C program by abusing the sysfs `new_id` and `bind` interfaces to force the driver to bind to an existing, non-Thunderbolt PCI device with a small BAR.

1. **Scan PCI Devices**: Iterate through `/sys/bus/pci/devices/` to find a candidate PCI device.
2. **Filter Candidates**: 
   - Skip critical devices like Host/ISA bridges (Class `0x06xxxx`) and Mass Storage controllers (Class `0x01xxxx`) to prevent freezing the system or unmounting the rootfs.
   - Read the `resource` file to ensure BAR 0 is a memory BAR (`flags & IORESOURCE_MEM`) and its size is greater than 0 but strictly less than `0x39640`.
3. **Force Bind**:
   - Write the candidate device's name to its current driver's `unbind` file.
   - Write the candidate's Vendor and Device ID to `/sys/bus/pci/drivers/thunderbolt/new_id`.
   - Write the candidate's device name to `/sys/bus/pci/drivers/thunderbolt/bind`.
4. **Trigger**: The `thunderbolt` driver will probe the device, map its small BAR 0, and immediately perform an out-of-bounds MMIO access when reading/writing high-offset registers, reproducing the crash.

### Minimal C Reproducer Outline

```c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>

int main() {
    // Ensure the thunderbolt module is loaded
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) return 1;

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        fscanf(f, "%x", &class_code);
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start, end, flags;
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        if (size > 0 && size < 0x39640) {
            unsigned int vendor, device;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &vendor); fclose(f);

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); fscanf(f, "%x", &device); fclose(f);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            f = fopen(path, "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }

            // 2. Add ID to thunderbolt driver
            f = fopen("/sys/bus/pci/drivers/thunderbolt/new_id", "w");
            if (f) { fprintf(f, "%x %x", vendor, device); fclose(f); }

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            f = fopen("/sys/bus/pci/drivers/thunderbolt/bind", "w");
            if (f) { fprintf(f, "%s", ent->d_name); fclose(f); }
            
            // The kernel should panic here.
            break;
        }
    }
    closedir(dir);
    return 0;
}
```
Feedback: The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer.

Reply:
```c
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        write(fd, data, strlen(data));
        close(fd);
    }
}

int main(void) {
    // Ensure the thunderbolt module is loaded (if it's not built-in)
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        perror("opendir");
        return 1;
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%x %x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
        }
    }
    closedir(dir);
    return 0;
}
```

190/5 2026/08/10 08:40 llm strategy-refiner
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7385
							output: 1037
							thoughts: 5691
						

Thoughts:
**My Thoughts on Recreating the Thunderbolt Driver Crash**

Alright, let's think through this bug. We've got a report about a crash in `iowrite32` during `nhi_disable_interrupts` within the Thunderbolt driver. The core issue, as I understand it, stems from how the Thunderbolt driver probes PCI devices. Specifically, `nhi_pci_probe` maps BAR 0 (the first Base Address Register) but *fails to check if it's sufficiently large*. The driver expects this BAR to be at least `0x39948` bytes in size. If a device that's smaller than this expected size gets bound to the Thunderbolt driver, it maps a too-small memory region. Subsequent attempts to access registers, like `REG_CAPS` at offset `0x39640` and `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at `0x38208`, then go out of bounds, leading to the crash.

The proposed method for reproducing this is pretty straightforward: find an existing PCI device on the system that happens to have a small memory BAR 0. Then, I need to unbind it from its current driver, tell the Thunderbolt driver to recognize this device's vendor and device IDs (by writing to `new_id`), and finally, bind it to the Thunderbolt driver. The feedback I've received is encouraging: "The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer." This tells me the setup is good to go for the next step.

So, my task now is to craft a C program that automates this reproduction strategy. I need to be systematic about it.

Here's how I'm planning to structure the reproducer:

1.  **Iterate through PCI Devices:** I'll start by looking at all devices listed under `/sys/bus/pci/devices/`. This is the standard way to interact with PCI devices through sysfs.

2.  **Filter Critical Devices:** To avoid destabilizing the system unnecessarily, I need to be careful about which devices I unbind. I'll check the device's `class` code. Specifically, I want to skip over critical system components like bridges (class `0x06`) and mass storage controllers (class `0x01`), as unbinding these could easily lead to a hang or data loss.

3.  **Analyze BAR 0:** For each device that passes the class filter, I'll examine its `resource` file. This file contains information about the device's memory and I/O regions. I'm specifically interested in BAR 0. I need to confirm:
    *   It's a *memory* BAR (indicated by the `flags` field, specifically the `IORESOURCE_MEM` bit, which is `0x200`).
    *   Its size is less than the required `0x39640` bytes, and also greater than zero (a zero-sized BAR wouldn't be useful). The size is derived from `end - start + 1`.

4.  **Read Vendor and Device IDs:** If a device meets the BAR criteria, I'll read its vendor and device IDs from `/sys/bus/pci/devices/<device_name>/vendor` and `/sys/bus/pci/devices/<device_name>/device`.

5.  **Unbind from Current Driver:** This is a crucial step. I'll write the device's name to its current driver's `unbind` file (e.g., `/sys/bus/pci/devices/<device_name>/driver/unbind`). This effectively detaches the device from whatever driver is currently managing it.

6.  **Inform Thunderbolt Driver:** Next, I need to make the Thunderbolt driver aware of this device's IDs. I'll format the vendor and device IDs into a string like "vendor device" and write it to `/sys/bus/pci/drivers/thunderbolt/new_id`. This tells the PCI core to consider this device for the Thunderbolt driver.

7.  **Bind to Thunderbolt Driver:** Finally, I'll explicitly tell the Thunderbolt driver to bind to the device by writing the device's name to `/sys/bus/pci/drivers/thunderbolt/bind`. This action should trigger the driver's probe routine, which is where the out-of-bounds access is expected to occur.

A quick thought: what if the `thunderbolt` module isn't loaded? Syzkaller environments often have modules built-in or loaded, but to be robust, I can try `system("modprobe thunderbolt");` at the beginning. If the driver is already loaded or built-in, this command will either succeed harmlessly or fail gracefully. The key is that `/sys/bus/pci/drivers/thunderbolt` should exist if the driver is available.

I've refined the logic for reading the `resource` file. It's formatted as `start end flags`, and I need to parse these as unsigned 64-bit hexadecimal values using `%llx`. The `flags` field is critical for identifying memory BARs (`0x200`).

I'm aiming for a C program that directly manipulates these sysfs entries. I've already drafted some C code that seems to cover these steps. I'll use `opendir`, `readdir`, `fopen`, `fscanf`, `open`, `write`, `close`, and `system` for the necessary operations. I'll make sure my `write_file` helper function is robust, opening files in `O_WRONLY` mode and writing the data.

I'm also considering which class codes to absolutely avoid. Beyond the essential `0x01` (Storage) and `0x06` (Bridge), I'm debating if I should skip network controllers (`0x02`) or display controllers (`0x03`). While unbinding a network controller might disrupt SSH, syzkaller usually captures console output, so the crash report should still be visible. For now, I'll stick to skipping `0x01` and `0x06` to minimize system instability. If that doesn't yield a reproducible crash, I can be more aggressive with class filtering.

The overall flow would be: load module (if needed), iterate devices, filter by class, check BAR 0 size and type, read IDs, unbind, register ID with thunderbolt driver, and then bind to it. This sequence should reliably trigger the buggy probe logic and the subsequent out-of-bounds memory access.

Here's the refined C reproducer code I've put together based on these thoughts:

```c
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>

// Helper function to write data to a file descriptor.
void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            // Handle write error if necessary, but for reproducer, usually skip.
        }
        close(fd);
    } else {
        // Handle open error if necessary.
    }
}

int main(void) {
    // Attempt to load the thunderbolt module if it's not already loaded.
    // This might be built-in or loaded by other means in some environments,
    // so this call is often harmless or succeeds.
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        // If we can't even open the devices directory, something is fundamentally wrong.
        return 1;
    }

    struct dirent *ent;
    // Iterate through all PCI devices found in sysfs.
    while ((ent = readdir(dir)) != NULL) {
        // Skip . and .. entries.
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        // Construct path to the 'class' file for the current device.
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue; // If we can't open the class file, skip this device.
        // Read the class code (e.g., 0x060401).
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue; // Failed to parse class code.
        }
        fclose(f);
        
        // Extract the base class code (bits 23-15).
        unsigned int base_class = (class_code >> 16) & 0xFF;
        
        // Skip critical device classes to prevent system instability.
        // 0x01: Mass Storage Controller
        // 0x06: Bridge device
        if (base_class == 0x01 || base_class == 0x06) continue;

        // Construct path to the 'resource' file for the current device.
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue; // If resource file isn't available, skip.

        unsigned long long start = 0, end = 0, flags = 0;
        // The 'resource' file lists regions. We're interested in the first one (BAR 0).
        // Format: start_address end_address flags
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue; // Failed to parse resource line.
        }
        fclose(f);

        // Check if it's a Memory BAR. IORESOURCE_MEM is 0x200.
        if (!(flags & 0x200)) continue;

        // Calculate the size of the BAR. If end is 0 (disabled BAR), size is 0.
        unsigned long long size = end ? (end - start + 1) : 0;
        
        // This is the core check: does the BAR size fall below what the thunderbolt driver expects?
        // The driver expects at least 0x39948. Accessing 0x39640 means the BAR must be at least 0x39644 in size.
        // So, any BAR with size strictly less than 0x39640 will cause an out-of-bounds access at offset 0x39640.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            // Read Vendor ID.
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            FILE *vendor_f = fopen(path, "r"); 
            if (vendor_f) { fscanf(vendor_f, "%x", &vendor); fclose(vendor_f); }

            // Read Device ID.
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            FILE *device_f = fopen(path, "r"); 
            if (device_f) { fscanf(device_f, "%x", &device); fclose(device_f); }

            // If we failed to read IDs, skip.
            if (!vendor || !device) continue;

            // --- Begin Reproducer Steps ---
            
            // 1. Unbind the device from its current driver.
            // This is typically done by writing the device name to the driver's unbind file.
            char unbind_path[256];
            snprintf(unbind_path, sizeof(unbind_path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(unbind_path, ent->d_name);

            // 2. Add the device's Vendor and Device ID to the thunderbolt driver's 'new_id' file.
            // This makes the PCI core aware that the thunderbolt driver might handle this device.
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%x %x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind the device to the thunderbolt driver.
            // This step should trigger the thunderbolt driver's probe function,
            // which will then attempt to map the small BAR and perform the out-of-bounds access.
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // We don't break here because we want to try this process for all matching devices,
            // in case the first attempt doesn't result in the desired crash due to environmental factors
            // or other driver interactions. The goal is to maximize the chances of hitting the bug.
        }
    }
    closedir(dir); // Clean up the directory handle.
    return 0; // Exit successfully, assuming the kernel will crash if the reproducer worked.
}
```


191/3 2026/08/10 08:41 action merge-strategy
0m Results:
map[CurrentReproStrategy:```c
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        write(fd, data, strlen(data));
        close(fd);
    }
}

int main(void) {
    // Ensure the thunderbolt module is loaded (if it's not built-in)
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        perror("opendir");
        return 1;
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%x %x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
        }
    }
    closedir(dir);
    return 0;
}
```]

192/3 2026/08/10 08:41 agent repro-generator
0m Model:
best-expensive

Results:
map[IsProbe:false RawCandidateReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
]

Instruction:
You are a security researcher with deep Linux kernel background.
Your goal is to generate a minimal, standalone C program for the strictly defensive
purpose of verifying a bugfix in an isolated environment.

To ensure that we can diagnose why a program might fail to run on the test environment,
you MUST include detailed logging and error checking in the generated C program:
1. Use 'printf(...)' for all progress messages and error logs.
2. Every system call (e.g., socket, bind, listen, connect, ioctl, send) must check for a failure return value.
3. If a call fails, it must print a specific error message including the function name
   and the error string (use strerror(errno)), and then exit with a non-zero status.
4. The program must print a message after every successful major step.
5. Generate code that follows this pattern for all operations:
    int res = do_something();
    if (res < 0) {
        printf("[-] Failed to do_something: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] do_something successful.\n");
6. The compilation and development environment (including compilers, build
   systems, makefiles, and kernel build/header directories) is NOT available
   on the target test VM guest. Do NOT check for, build, or reference any
   compilation tools, build files, or kernel development directories.
7. Do NOT execute shell commands or run external binaries (e.g. by using
   functions like 'system()', 'popen()', or the 'exec' family such as
   'execve()'). All environment checks, capability probings, and reproduction
   steps must be performed directly using standard Linux system calls (such
   as 'open', 'socket', 'ioctl', 'stat', etc.).
8. When reproducing asynchronous kernel timeouts or warnings, always
   include a sufficient delay (using sleep or similar) after deleting
   or unregistering the device to allow the kernel's asynchronous
   timeout to trigger before program exit.


=== PHASE 2: BUG REPRODUCTION (GENERATION) ===
You must now generate a full reproducer candidate attempting to trigger the target bug/crash.
Do NOT generate a probe program. Focus directly on triggering the bug/crash described in the description.
You can assume that all necessary kernel capabilities and privileges (e.g., access to /dev/vhci,
ability to load BPF programs, etc.) have already been verified and are available in the environment.

Do not spend too much time analyzing or trying to generate a perfect one-shot reproducer.
Instead, follow an iterative approach: generate a simple candidate, execute it, analyze the results,
and improve it. Keep your reasoning steps short and focused on the next logical experiment.

Prefer calling several tools at the same time to save round-trips.


Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

Strategy: ```c
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        write(fd, data, strlen(data));
        close(fd);
    }
}

int main(void) {
    // Ensure the thunderbolt module is loaded (if it's not built-in)
    system("modprobe thunderbolt");
    
    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        perror("opendir");
        return 1;
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%x %x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
        }
    }
    closedir(dir);
    return 0;
}
```


Previous Reproducer Attempt:
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>

int main(void) {
    printf("[*] Starting capability probe...\n");

    if (getuid() != 0) {
        printf("[-] Not running as root, uid=%d\n", getuid());
        exit(1);
    }
    printf("[+] Running as root.\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/devices opened successfully.\n");
    closedir(dir);

    if (access("/sys/bus/pci/drivers", F_OK) != 0) {
        printf("[-] Failed to access /sys/bus/pci/drivers: %s\n", strerror(errno));
        exit(1);
    }
    printf("[+] /sys/bus/pci/drivers is accessible.\n");

    printf("[+] All probes passed successfully.\n");
    return 0;
}




Execution Results & Debugging Feedback:
The capability probe passed successfully. The environment is ready. Please proceed to generate the full reproducer.

193/4 2026/08/10 08:41 llm repro-generator
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 7522
							output: 1231
							thoughts: 5574
						

Thoughts:
**Reproducing the `BUG: unable to handle kernel paging request in iowrite32` in the Thunderbolt Driver**

My primary objective is to reproduce a specific kernel bug: `BUG: unable to handle kernel paging request in iowrite32`. The crash trace points to the Thunderbolt (`thunderbolt`) driver, specifically in the `nhi_mask_interrupt`, `nhi_disable_interrupts`, and `nhi_probe` functions, ultimately stemming from a PCI probe.

My analysis of the crash trace reveals the following call chain:
`nhi_mask_interrupt` -> `nhi_disable_interrupts` -> `nhi_probe` -> `nhi_pci_probe`. This strongly suggests that the issue occurs during the initialization and probing of a Thunderbolt Network Interface Host (NHI) controller.

The core of the problem, as I've deduced, lies in how the `thunderbolt` driver interacts with PCI devices, specifically their memory BARs (Base Address Registers). The driver expects to map a significant portion of memory for its registers, particularly around `REG_RING_INTERRUPT_BASE` (which is at offset `0x38200`). When it attempts to map this region using `pci_iomap` (or its underlying mechanisms like `pcim_iomap_regions`), if the device's BAR0 is too small, only a truncated region will be mapped. Subsequent attempts to write to addresses beyond this small mapped region using `iowrite32` will result in an out-of-bounds access, leading to a page fault and the observed kernel panic.

Therefore, my strategy is to:

1.  **Identify a suitable PCI device:** I need to find a PCI device that has a memory BAR0 with a size that is smaller than what the `thunderbolt` driver expects (specifically, less than `0x39640` bytes, as the driver accesses up to `0x39944`).
2.  **Isolate the device:** I will unbind the identified device from its current driver. This is crucial to allow another driver to claim it.
3.  **Introduce the `thunderbolt` driver's interest:** I will programmatically add the vendor and device ID of the chosen PCI device to the `thunderbolt` driver's `new_id` interface. This tells the kernel that the `thunderbolt` driver might be able to manage this device.
4.  **Trigger the probe:** I will then attempt to bind the device to the `thunderbolt` driver. This action should initiate the `nhi_pci_probe` function, leading to the `nhi_probe` call, the problematic `pci_iomap` operation with a small BAR, and ultimately, the `iowrite32` out-of-bounds access causing the crash.

To implement this strategy, I've developed a C program. This program iterates through all PCI devices listed under `/sys/bus/pci/devices/`. For each device, it:

*   Reads its `class` code to filter out devices like Mass Storage (base class `0x01`) and Bridges (base class `0x06`), as these can sometimes cause system instability or are not relevant to our target.
*   Reads its `resource` file to get information about its BARs. I specifically look for the first BAR (BAR0) and check if it's a memory resource (`IORESOURCE_MEM`, represented by flag `0x200`).
*   Calculates the `size` of BAR0 (`end - start + 1`).
*   If the BAR0 is a memory resource and its `size` is less than `0x39640`, I consider it a candidate.
*   For candidate devices, I extract their `vendor` and `device` IDs.
*   Then, I perform the three critical steps:
    *   **Unbind:** I write the device's PCI address (e.g., `0000:01:00.0`) to `/sys/bus/pci/devices/<device_id>/driver/unbind`.
    *   **Add ID:** I format the vendor and device IDs into a string (e.g., `xxxx xxxx`) and write it to `/sys/bus/pci/drivers/thunderbolt/new_id`.
    *   **Bind:** I write the device's PCI address to `/sys/bus/pci/drivers/thunderbolt/bind`.

I've also considered potential issues:
*   The `thunderbolt` driver might not be loaded. The provided code assumes it's either built into the kernel (`CONFIG_THUNDERBOLT=y`) or already loaded. If it's a module and not loaded, attempting to write to `/sys/bus/pci/drivers/thunderbolt/new_id` would fail. However, standard fuzzing environments (like Syzkaller) often have such drivers pre-loaded or built-in, so I proceed with this assumption.
*   The `write_file` helper function is designed to handle errors gracefully, printing messages to `stderr` but not aborting the program, allowing the loop to continue searching for other candidate devices.
*   A small `sleep(1)` is included after initiating the bind to allow asynchronous probing or the crash to manifest.

In essence, my thought process is to systematically search for a PCI device that exhibits the specific memory resource characteristic (a small BAR0) that, when exposed to the `thunderbolt` driver's probing mechanism, will trigger the exact out-of-bounds memory access leading to the reported kernel bug.


194/4 2026/08/10 08:42 tool set-results
0m Args:
map[IsProbe:false RawCandidateReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
]

Results:
map[IsProbe:false RawCandidateReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
]

195/3 2026/08/10 08:42 loop
0m
196/4 2026/08/10 08:42 iteration 0
0m
197/5 2026/08/10 08:42 action merge-repro-c
0m Results:
map[CurrentCandidateReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
]

198/5 2026/08/10 08:42 action compile-c-prog
0m Results:
map[CompilerError: FormattedReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
]

199/5 2026/08/10 08:42 action If
0m Args:
map[CompilerError:]

200/3 2026/08/10 08:42 action run-c-repro
1m Results:
map[CandidateBugTitle:BUG: unable to handle kernel paging request in ioread32 CandidateCrashReport:thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb
 CandidateReproduced:true ConsoleOutput:Warning: Permanently added '[localhost]:23425' (ED25519) to the list of known hosts.
[   66.772482][ T5875] thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
[   66.775529][ T5875] thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
[   66.826037][ T5875] BUG: unable to handle page fault for address: ffffc90003c99640
[   66.828437][ T5875] #PF: supervisor read access in kernel mode
[   66.830400][ T5875] #PF: error_code(0x0000) - not-present page
[   66.832891][ T5875] PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
[   66.835274][ T5875] Oops: Oops: 0000 [#1] SMP KASAN NOPTI
[   66.837011][ T5875] CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
[   66.839954][ T5875] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   66.843041][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.844520][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.850386][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.852268][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.854693][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.857141][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.859572][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.861996][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.864420][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.867133][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.869171][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.871646][ T5875] Call Trace:
[   66.872712][ T5875]  <TASK>
[   66.873653][ T5875]  nhi_probe+0xcc/0x880
[   66.874976][ T5875]  nhi_pci_probe+0x46b/0x580
[   66.876413][ T5875]  ? __pfx_nhi_pci_probe+0x10/0x10
[   66.877999][ T5875]  ? __pfx__raw_spin_lock_bh+0x10/0x10
[   66.879672][ T5875]  ? lockdep_hardirqs_on+0x7a/0x110
[   66.881280][ T5875]  ? _raw_spin_unlock_irqrestore+0x4c/0x80
[   66.883097][ T5875]  pci_device_probe+0x431/0xc90
[   66.884604][ T5875]  ? up_write+0x19f/0x4a0
[   66.885972][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.887632][ T5875]  ? kernfs_put+0x7b9/0x820
[   66.889066][ T5875]  ? kernfs_create_link+0x187/0x200
[   66.890669][ T5875]  ? sysfs_do_create_link_sd+0xe0/0x110
[   66.892376][ T5875]  ? driver_sysfs_add+0x1fe/0x210
[   66.893955][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.895602][ T5875]  really_probe+0x254/0xae0
[   66.897041][ T5875]  __driver_probe_device+0x1e8/0x360
[   66.898677][ T5875]  device_driver_attach+0xe0/0x1d0
[   66.900291][ T5875]  bind_store+0x1d0/0x220
[   66.901653][ T5875]  ? __pfx_sysfs_kf_write+0x10/0x10
[   66.903281][ T5875]  kernfs_fop_write_iter+0x3a4/0x540
[   66.904930][ T5875]  vfs_write+0x612/0xba0
[   66.906261][ T5875]  ? __pfx_vfs_write+0x10/0x10
[   66.907770][ T5875]  ? do_sys_openat2+0x14e/0x200
[   66.909303][ T5875]  ? kmem_cache_free+0x182/0x650
[   66.910842][ T5875]  ? fd_install+0x94/0x3d0
[   66.912256][ T5875]  ksys_write+0x150/0x270
[   66.913611][ T5875]  ? __pfx_ksys_write+0x10/0x10
[   66.915138][ T5875]  ? entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.917020][ T5875]  do_syscall_64+0x174/0x580
[   66.918461][ T5875]  ? trace_irq_disable+0x3b/0x140
[   66.920041][ T5875]  ? clear_bhb_loop+0x40/0x90
[   66.921531][ T5875]  entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.923389][ T5875] RIP: 0033:0x7fbbd4aa6bf7
[   66.924790][ T5875] Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
[   66.930709][ T5875] RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
[   66.933505][ T5875] RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
[   66.935940][ T5875] RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
[   66.938367][ T5875] RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
[   66.940794][ T5875] R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
[   66.943248][ T5875] R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
[   66.945680][ T5875]  </TASK>
[   66.946655][ T5875] Modules linked in:
[   66.947873][ T5875] CR2: ffffc90003c99640
[   66.949193][ T5875] ---[ end trace 0000000000000000 ]---
[   66.950883][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.952388][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.958286][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.960158][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.962600][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.965046][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.967489][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.969936][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.972357][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.975080][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.977094][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.979549][ T5875] Kernel panic - not syncing: Fatal exception
[   66.982122][ T5875] Kernel Offset: disabled
[   66.983467][ T5875] Rebooting in 86400 seconds..
 OtherCrashReports:<nil> StraceOutput: TestError:]

201/3 2026/08/10 08:43 action truncate-log
0m Results:
map[TruncatedConsoleOutput:Warning: Permanently added '[localhost]:23425' (ED25519) to the list of known hosts.
[   66.772482][ T5875] thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
[   66.775529][ T5875] thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
[   66.826037][ T5875] BUG: unable to handle page fault for address: ffffc90003c99640
[   66.828437][ T5875] #PF: supervisor read access in kernel mode
[   66.830400][ T5875] #PF: error_code(0x0000) - not-present page
[   66.832891][ T5875] PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
[   66.835274][ T5875] Oops: Oops: 0000 [#1] SMP KASAN NOPTI
[   66.837011][ T5875] CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
[   66.839954][ T5875] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   66.843041][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.844520][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.850386][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.852268][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.854693][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.857141][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.859572][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.861996][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.864420][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.867133][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.869171][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.871646][ T5875] Call Trace:
[   66.872712][ T5875]  <TASK>
[   66.873653][ T5875]  nhi_probe+0xcc/0x880
[   66.874976][ T5875]  nhi_pci_probe+0x46b/0x580
[   66.876413][ T5875]  ? __pfx_nhi_pci_probe+0x10/0x10
[   66.877999][ T5875]  ? __pfx__raw_spin_lock_bh+0x10/0x10
[   66.879672][ T5875]  ? lockdep_hardirqs_on+0x7a/0x110
[   66.881280][ T5875]  ? _raw_spin_unlock_irqrestore+0x4c/0x80
[   66.883097][ T5875]  pci_device_probe+0x431/0xc90
[   66.884604][ T5875]  ? up_write+0x19f/0x4a0
[   66.885972][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.887632][ T5875]  ? kernfs_put+0x7b9/0x820
[   66.889066][ T5875]  ? kernfs_create_link+0x187/0x200
[   66.890669][ T5875]  ? sysfs_do_create_link_sd+0xe0/0x110
[   66.892376][ T5875]  ? driver_sysfs_add+0x1fe/0x210
[   66.893955][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.895602][ T5875]  really_probe+0x254/0xae0
[   66.897041][ T5875]  __driver_probe_device+0x1e8/0x360
[   66.898677][ T5875]  device_driver_attach+0xe0/0x1d0
[   66.900291][ T5875]  bind_store+0x1d0/0x220
[   66.901653][ T5875]  ? __pfx_sysfs_kf_write+0x10/0x10
[   66.903281][ T5875]  kernfs_fop_write_iter+0x3a4/0x540
[   66.904930][ T5875]  vfs_write+0x612/0xba0
[   66.906261][ T5875]  ? __pfx_vfs_write+0x10/0x10
[   66.907770][ T5875]  ? do_sys_openat2+0x14e/0x200
[   66.909303][ T5875]  ? kmem_cache_free+0x182/0x650
[   66.910842][ T5875]  ? fd_install+0x94/0x3d0
[   66.912256][ T5875]  ksys_write+0x150/0x270
[   66.913611][ T5875]  ? __pfx_ksys_write+0x10/0x10
[   66.915138][ T5875]  ? entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.917020][ T5875]  do_syscall_64+0x174/0x580
[   66.918461][ T5875]  ? trace_irq_disable+0x3b/0x140
[   66.920041][ T5875]  ? clear_bhb_loop+0x40/0x90
[   66.921531][ T5875]  entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.923389][ T5875] RIP: 0033:0x7fbbd4aa6bf7
[   66.924790][ T5875] Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
[   66.930709][ T5875] RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
[   66.933505][ T5875] RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
[   66.935940][ T5875] RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
[   66.938367][ T5875] RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
[   66.940794][ T5875] R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
[   66.943248][ T5875] R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
[   66.945680][ T5875]  </TASK>
[   66.946655][ T5875] Modules linked in:
[   66.947873][ T5875] CR2: ffffc90003c99640
[   66.949193][ T5875] ---[ end trace 0000000000000000 ]---
[   66.950883][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.952388][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.958286][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.960158][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.962600][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.965046][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.967489][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.969936][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.972357][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.975080][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.977094][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.979549][ T5875] Kernel panic - not syncing: Fatal exception
[   66.982122][ T5875] Kernel Offset: disabled
[   66.983467][ T5875] Rebooting in 86400 seconds..
 TruncatedCrashReport:thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb
 TruncatedStraceOutput:]

202/3 2026/08/10 08:43 agent repro-oracle
3m Model:
best-expensive

Results:
map[Feedback:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. ProbePassed:false TerminalError: TitleMatches:true]

Instruction:
You are a security researcher with deep Linux kernel background.
Analyze the results of running the generated program.

=== CRITICAL ENVIRONMENT & TARGET CLASSIFICATION ===
Set 'TerminalError' to a descriptive error message ONLY if:
1. The execution failed due to missing hardware device nodes, subsystems, kernel modules, or privilege limits
   that cannot be loaded, created, or bypassed by user-space C code edits in the VM guest.
2. The target source files or functions described in the bug description do not exist in the checked-out codebase,
   meaning the codebase version is mismatched and the target code is absent.

=== CRITICAL PROHIBITIONS ===
- Do NOT classify a run as a terminal failure or assume a bug is fixed based on git log entries, commit titles,
  or commit messages. Reproducibility can ONLY be determined by executing reproducer candidates in the VM.
- Do NOT suggest C code strategies, repairs, or namespace bypasses when setting 'TerminalError'.


=== PHASE 2: BUG REPRODUCTION (EVALUATION) ===
The executed program was a full reproducer candidate attempting to trigger the target bug/crash.
Use this to guide your classification and feedback:
1. If a crash was triggered (Reproduced is true):
   - Determine if the triggered crash matches the expected bug.
   - If you conclude they represent the same underlying bug (the same root cause)
     despite different titles, crash signatures, or call traces, set TitleMatches
     to true and provide a detailed, technical, and verbose explanation of the
     equivalence in the 'Feedback' field.
   - If they do not represent the same bug (a completely unrelated crash/collision),
     set TitleMatches to false and explain the collision in 'Feedback'.
   - If they match exactly, set TitleMatches to true and provide a brief confirmation in 'Feedback'.
2. If the execution was successful (exit 0) WITHOUT a crash (Reproduced is false):
   - The reproduction attempt failed to trigger the bug. Analyze the console/strace output
     to understand why the bug did not trigger (e.g., timing, input arguments, environment setup)
     and provide feedback on how to improve the reproducer logic to trigger the crash.

Critical Diagnostic Rule for Reproduction Failures:
If the reproduction attempt fails (e.g., a system call returns an error, or a
warning/error message appears in the console log), you MUST:
1. Identify the failing system call from the execution trace or strace output.
2. Identify any corresponding warning or error messages in the console log.
3. Immediately search the kernel source tree for the warning message strings or
   the code of the failing system call/subsystem to locate the validation logic.
4. Trace the kernel's validation logic to diagnose the exact constraint violation
   or input mismatch in the generated program.
5. Provide a technical diagnosis in the feedback explaining the exact kernel constraint that was violated and why.

Prefer calling several tools at the same time to save round-trips.


Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.

Prompt:
Bug Description: BUG: unable to handle kernel paging request in iowrite32

thunderbolt 0000:00:07.0: timeout resetting host router
BUG: unable to handle page fault for address: ffffc90000f70208
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1b000067 P4D 1b000067 PUD 1c2b9067 PMD 30b6b067 PTE 0
Oops: Oops: 0002 [#1] SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 5323 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f59e119e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f59dd5f4fe8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f59e1425fa0 RCX: 00007f59e119e019
RDX: 000000000000000d RSI: 00002000000001c0 RDI: 0000000000000004
RBP: 00007f59e123500c R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f59e1426038 R14: 00007f59e1425fa0 R15: 00007fffc2eb28b8
 </TASK>
Modules linked in:
CR2: ffffc90000f70208
---[ end trace 0000000000000000 ]---
RIP: 0010:writel arch/x86/include/asm/io.h:67 [inline]
RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 f3 89 fd e8 00 ad e7 fc 48 81 fb 00 00 04 00 72 09 e8 f2 ac e7 fc <89> 2b eb 52 48 81 fb 01 00 01 00 72 0c e8 e0 ac e7 fc 89 e8 89 da
RSP: 0018:ffffc9000f73f7f0 EFLAGS: 00010287
RAX: ffffffff84df75ce RBX: ffffc90000f70208 RCX: 0000000000100000
RDX: ffffc9000ee92000 RSI: 00000000000b3ba8 RDI: 00000000000b3ba9
RBP: 00000000ffffffff R08: ffffc9000f73f3a7 R09: 1ffff92001ee7e74
R10: dffffc0000000000 R11: fffff52001ee7e75 R12: 1ffff110025ead11
R13: ffffc90000f70208 R14: 0000000000000000 R15: 0000000000000001
FS:  00007f59dd5f56c0(0000) GS:ffff88808c540000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90000f70208 CR3: 00000000430ad000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	f3 0f 1e fa          	endbr64
  10:	55                   	push   %rbp
  11:	53                   	push   %rbx
  12:	48 89 f3             	mov    %rsi,%rbx
  15:	89 fd                	mov    %edi,%ebp
  17:	e8 00 ad e7 fc       	call   0xfce7ad1c
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 f2 ac e7 fc       	call   0xfce7ad1c
* 2a:	89 2b                	mov    %ebp,(%rbx) <-- trapping instruction
  2c:	eb 52                	jmp    0x80
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0c                	jb     0x43
  37:	e8 e0 ac e7 fc       	call   0xfce7ad1c
  3c:	89 e8                	mov    %ebp,%eax
  3e:	89 da                	mov    %ebx,%edx

IsProbe: false
Reproduced: true
Console Output: Warning: Permanently added '[localhost]:23425' (ED25519) to the list of known hosts.
[   66.772482][ T5875] thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
[   66.775529][ T5875] thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
[   66.826037][ T5875] BUG: unable to handle page fault for address: ffffc90003c99640
[   66.828437][ T5875] #PF: supervisor read access in kernel mode
[   66.830400][ T5875] #PF: error_code(0x0000) - not-present page
[   66.832891][ T5875] PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
[   66.835274][ T5875] Oops: Oops: 0000 [#1] SMP KASAN NOPTI
[   66.837011][ T5875] CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
[   66.839954][ T5875] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   66.843041][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.844520][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.850386][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.852268][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.854693][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.857141][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.859572][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.861996][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.864420][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.867133][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.869171][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.871646][ T5875] Call Trace:
[   66.872712][ T5875]  <TASK>
[   66.873653][ T5875]  nhi_probe+0xcc/0x880
[   66.874976][ T5875]  nhi_pci_probe+0x46b/0x580
[   66.876413][ T5875]  ? __pfx_nhi_pci_probe+0x10/0x10
[   66.877999][ T5875]  ? __pfx__raw_spin_lock_bh+0x10/0x10
[   66.879672][ T5875]  ? lockdep_hardirqs_on+0x7a/0x110
[   66.881280][ T5875]  ? _raw_spin_unlock_irqrestore+0x4c/0x80
[   66.883097][ T5875]  pci_device_probe+0x431/0xc90
[   66.884604][ T5875]  ? up_write+0x19f/0x4a0
[   66.885972][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.887632][ T5875]  ? kernfs_put+0x7b9/0x820
[   66.889066][ T5875]  ? kernfs_create_link+0x187/0x200
[   66.890669][ T5875]  ? sysfs_do_create_link_sd+0xe0/0x110
[   66.892376][ T5875]  ? driver_sysfs_add+0x1fe/0x210
[   66.893955][ T5875]  ? __pfx_pci_device_probe+0x10/0x10
[   66.895602][ T5875]  really_probe+0x254/0xae0
[   66.897041][ T5875]  __driver_probe_device+0x1e8/0x360
[   66.898677][ T5875]  device_driver_attach+0xe0/0x1d0
[   66.900291][ T5875]  bind_store+0x1d0/0x220
[   66.901653][ T5875]  ? __pfx_sysfs_kf_write+0x10/0x10
[   66.903281][ T5875]  kernfs_fop_write_iter+0x3a4/0x540
[   66.904930][ T5875]  vfs_write+0x612/0xba0
[   66.906261][ T5875]  ? __pfx_vfs_write+0x10/0x10
[   66.907770][ T5875]  ? do_sys_openat2+0x14e/0x200
[   66.909303][ T5875]  ? kmem_cache_free+0x182/0x650
[   66.910842][ T5875]  ? fd_install+0x94/0x3d0
[   66.912256][ T5875]  ksys_write+0x150/0x270
[   66.913611][ T5875]  ? __pfx_ksys_write+0x10/0x10
[   66.915138][ T5875]  ? entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.917020][ T5875]  do_syscall_64+0x174/0x580
[   66.918461][ T5875]  ? trace_irq_disable+0x3b/0x140
[   66.920041][ T5875]  ? clear_bhb_loop+0x40/0x90
[   66.921531][ T5875]  entry_SYSCALL_64_after_hwframe+0x77/0x7f
[   66.923389][ T5875] RIP: 0033:0x7fbbd4aa6bf7
[   66.924790][ T5875] Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
[   66.930709][ T5875] RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
[   66.933505][ T5875] RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
[   66.935940][ T5875] RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
[   66.938367][ T5875] RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
[   66.940794][ T5875] R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
[   66.943248][ T5875] R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
[   66.945680][ T5875]  </TASK>
[   66.946655][ T5875] Modules linked in:
[   66.947873][ T5875] CR2: ffffc90003c99640
[   66.949193][ T5875] ---[ end trace 0000000000000000 ]---
[   66.950883][ T5875] RIP: 0010:ioread32+0x1c/0x80
[   66.952388][ T5875] Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
[   66.958286][ T5875] RSP: 0018:ffffc900046df850 EFLAGS: 00010293
[   66.960158][ T5875] RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
[   66.962600][ T5875] RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
[   66.965046][ T5875] RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
[   66.967489][ T5875] R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
[   66.969936][ T5875] R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
[   66.972357][ T5875] FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
[   66.975080][ T5875] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   66.977094][ T5875] CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
[   66.979549][ T5875] Kernel panic - not syncing: Fatal exception
[   66.982122][ T5875] Kernel Offset: disabled
[   66.983467][ T5875] Rebooting in 86400 seconds..

Strace Output: 
Crash Report: thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb



203/4 2026/08/10 08:43 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 13935
							output: 37
							thoughts: 359
						

Thoughts:
**My Thought Process on Investigating the Reproduced Bug**

Alright, so the core task here is to figure out what's going on with this newly generated program and its crash. The ultimate goal is to see if it actually reproduces the original bug we were tracking, which was a `BUG: unable to handle kernel paging request in iowrite32`.

I've been given the crash trace from the original bug, and I can see it points to a page fault occurring within `iowrite32`, which was invoked by `nhi_disable_interrupts`, and ultimately that chain leads back to `nhi_probe` in `drivers/thunderbolt/nhi.c`. This gives me a clear starting point for the original problem.

Now, I have the crash trace from the *reproduced* bug. It's also a `BUG: unable to handle page fault`, which is promising, but the details are slightly different. The address it's faulting on is `fffc900003c99640`, and it's a `supervisor read access in kernel mode` with an `error_code(0x0000) - not-present page`. Crucially, the `RIP` is showing `ioread32+0x1c/0x80`.

Comparing the two, I can see the original bug was in `iowrite32`, but this new one is in `ioread32`. Both are I/O read/write operations, and both are happening in kernel mode due to a page fault. The call trace for the reproduced bug shows `ioread32` being called directly from `nhi_probe`, which then leads to `nhi_pci_probe`. This is a bit different from the original, where it went through `nhi_disable_interrupts` first.

So, the immediate next step is to dive into the `nhi_probe` function itself. I need to understand its logic, especially around how it handles I/O operations, and see if there's a path that could lead to `ioread32` being called in a way that causes a page fault, particularly in the context of what the original bug might have been triggered by. I'm going to use my `codesearch-definition-source` tool to get the source code definition for `nhi_probe` in `drivers/thunderbolt/nhi.c`. This will allow me to scrutinize the function's implementation and identify any potential areas of concern that might explain this new page fault.


204/4 2026/08/10 08:44 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_probe]

Results:
map[SourceCode:1186:	int nhi_probe(struct tb_nhi *nhi)
1187:	{
1188:		struct device *dev = nhi->dev;
1189:		struct tb *tb;
1190:		int res;
1191:	
1192:		if (!nhi->ops)
1193:			return dev_err_probe(dev, -EINVAL, "NHI ops not set\n");
1194:	
1195:		if (!nhi->ops->init_interrupts)
1196:			return dev_err_probe(dev, -EINVAL, "missing required NHI ops\n");
1197:	
1198:		nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;
1199:		dev_dbg(dev, "total paths: %d\n", nhi->hop_count);
1200:	
1201:		nhi->tx_rings = devm_kcalloc(dev, nhi->hop_count,
1202:					     sizeof(*nhi->tx_rings), GFP_KERNEL);
1203:		nhi->rx_rings = devm_kcalloc(dev, nhi->hop_count,
1204:					     sizeof(*nhi->rx_rings), GFP_KERNEL);
1205:		if (!nhi->tx_rings || !nhi->rx_rings)
1206:			return -ENOMEM;
1207:	
1208:		nhi_reset(nhi);
1209:	
1210:		/* In case someone left them on. */
1211:		nhi_disable_interrupts(nhi);
1212:	
1213:		res = nhi->ops->init_interrupts(nhi);
1214:		if (res)
1215:			return dev_err_probe(dev, res, "cannot enable interrupts, aborting\n");
1216:	
1217:		spin_lock_init(&nhi->lock);
1218:	
1219:		res = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64));
1220:		if (res)
1221:			return dev_err_probe(dev, res, "failed to set DMA mask\n");
1222:	
1223:		if (nhi->ops->init) {
1224:			res = nhi->ops->init(nhi);
1225:			if (res)
1226:				return dev_err_probe(dev, res, "NHI specific init failed\n");
1227:		}
1228:	
1229:		tb = nhi_select_cm(nhi);
1230:		if (!tb)
1231:			return dev_err_probe(dev, -ENODEV,
1232:				"failed to determine connection manager, aborting\n");
1233:	
1234:		dev_dbg(dev, "NHI initialized, starting thunderbolt\n");
1235:	
1236:		init_completion(&nhi->domain_released);
1237:	
1238:		res = tb_domain_add(tb, host_reset);
1239:		if (res) {
1240:			/*
1241:			 * At this point the RX/TX rings might already have been
1242:			 * activated. Do a proper shutdown.
1243:			 */
1244:			tb_domain_put(tb);
1245:			wait_for_completion(&nhi->domain_released);
1246:			nhi_shutdown(nhi);
1247:			return dev_err_probe(dev, res, "failed to add domain\n");
1248:		}
1249:		dev_set_drvdata(dev, tb);
1250:	
1251:		device_wakeup_enable(dev);
1252:	
1253:		pm_runtime_allow(dev);
1254:		pm_runtime_set_autosuspend_delay(dev, TB_AUTOSUSPEND_DELAY);
1255:		pm_runtime_use_autosuspend(dev);
1256:		pm_runtime_put_autosuspend(dev);
1257:	
1258:		return 0;
1259:	}
 SourceFile:drivers/thunderbolt/nhi.c]

205/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 15514
							output: 40
							thoughts: 205
						

Thoughts:
**My Thought Process Unraveling the Kernel Crash**

Alright, let's dive into this. I've got two crash reports here, and they both seem to be pointing to the same underlying problem. The first crash, the one I'm seeing now, is happening at `nhi_probe+0xcc/0x880`, specifically on line 1198: `nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;`. The original crash, the one I was initially looking at, was at `nhi_probe+0x2be/0x880`, which corresponds to line 1211: `nhi_disable_interrupts(nhi);`. Digging a bit deeper, that call chain leads to `nhi_mask_interrupt`, and within that, I see an `iowrite32` operation.

Now, the crucial observation here is that both these crashes manifest as page faults. This immediately tells me that we're trying to access memory that isn't valid or hasn't been mapped correctly. Looking at the specific operations, both the `ioread32` and the `iowrite32` operations are attempting to interact with memory addresses derived from `nhi->iobase`. Therefore, the common thread, the absolute root cause, is that `nhi->iobase` is being accessed when it's not a valid, mapped memory address. It's an invalid pointer.

To figure out *why* `nhi->iobase` is invalid, my next logical step is to trace its origin. I need to understand how and where `nhi->iobase` gets its value. This means I'm going to meticulously examine the `nhi_pci_probe` function. That's where the PCI device is initialized and where I expect `nhi->iobase` to be populated. By stepping through `nhi_pci_probe`, I'm confident I'll find the point where the allocation or mapping of I/O memory for this device either fails or is incorrectly handled, leading to this invalid address being assigned.


206/4 2026/08/10 08:44 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

207/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 16376
							output: 37
							thoughts: 1286
						

Thoughts:
**My Thought Process Unraveling a PCI Driver Crash**

I've been diving into a rather perplexing crash scenario involving a PCI driver. It all started when I observed that `pcim_iomap_region`, a function crucial for mapping PCI BARs, returns a pointer. The question that immediately arose was: what happens if the PCI device has a BAR0 of zero length? Does `pcim_iomap_region` still return a valid-looking pointer, or does it fail gracefully?

Then, I noticed the crash itself, manifesting as a page fault at specific addresses like `ffffc90003c99640` or `ffffc90000f70208`. These addresses strongly suggested `vmalloc` or `ioremap` regions, which are expected to be valid. This led me to ponder why a fault would occur in such a context. Several possibilities came to mind:

*   Perhaps the PCI device was removed unexpectedly.
*   Or maybe the memory space it was trying to access had been disabled.
*   Another thought was that `pcim_iomap_region` might successfully map the region, but the PCI device itself might not actually respond to memory accesses, or its memory space simply wasn't enabled in the first place.

I recalled that `pcim_enable_device` is responsible for enabling the device, which in turn should enable its memory space if BARs are present. However, I then considered more complex interactions:

*   Could the `syzkaller` reproducer be modifying the PCI configuration space, perhaps via `sysfs`, to disable the memory space (by clearing the Memory Space Enable bit in the Command register) concurrently with the driver's operations?
*   Or, if it's a virtual device like `syz_pci`, it might not truly back the BAR with memory, or it could unmap it altogether.

The reproducer itself was a key piece of information. I noted that it specifically uses `sysfs` to bind the device to the thunderbolt driver. This observation was crucial when I compared the original crash path with the reproduced one. Both showed the exact same sequence: `bind_store` calling into `kernfs_fop_write_iter`.

The distinction, however, lay in *where* within that path the crash occurred. In the original crash, the fault happened in `iowrite32` within `nhi_disable_interrupts`. In the reproduced crash, it was in `ioread32` within `nhi_probe`, which occurs earlier in the same function chain. This discrepancy made me wonder:

*   Did the first `ioread32` in the original crash succeed, but a later `iowrite32` failed?
*   Or was the memory space being disabled concurrently by another thread in the original scenario?

I then looked closer at the reproducer's behavior. While it binds the driver, I needed to ascertain if it was also concurrently writing to PCI configuration space.

The reproduced crash output then offered a significant clue:

```
[   66.772482][ T5875] thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
[   66.775529][ T5875] thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
```

This indicated that the probe for `0000:00:03.0` had failed *before* the page fault. This was a critical realization. If the probe failed, `nhi_probe` would return an error, and `really_probe` would then perform cleanup.

However, the stack trace of the crash itself showed the fault occurring *within* `nhi_probe`:

```
 nhi_probe+0xcc/0x880
 nhi_pci_probe+0x46b/0x580
 pci_device_probe+0x431/0xc90
 really_probe+0x254/0xae0
 __driver_probe_device+0x1e8/0x360
 device_driver_attach+0xe0/0x1d0
 bind_store+0x1d0/0x220
```

This presented a seeming contradiction: the console log stated the probe failed, yet the crash stack trace placed it *during* the probe. This led me to question:

*   Was the crash occurring on `0000:00:03.0`, or was it possibly a different device altogether?
*   Could the reproducer be binding multiple devices, or perhaps attempting to bind the same device multiple times?
*   Was it possible that `0000:00:03.0` failed its probe, and then the reproducer proceeded to bind `0000:00:04.0` or even attempt to bind `0000:00:03.0` again, leading to the crash?

I then recalled the original crash, which involved `thunderbolt 0000:00:07.0: timeout resetting host router`, followed by a page fault. The "timeout resetting host router" error originates from `nhi_reset`, and I specifically noted that `nhi_reset` performs `iowrite32` operations. This detail prompted me to revisit the `nhi_reset` function to examine its behavior more closely.


208/4 2026/08/10 08:44 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_reset]

Results:
map[SourceCode:1132:	static void nhi_reset(struct tb_nhi *nhi)
1133:	{
1134:		ktime_t timeout;
1135:		u32 val;
1136:	
1137:		val = ioread32(nhi->iobase + REG_CAPS);
1138:		/* Reset only v2 and later routers */
1139:		if (FIELD_GET(REG_CAPS_VERSION_MASK, val) < REG_CAPS_VERSION_2)
1140:			return;
1141:	
1142:		if (!host_reset) {
1143:			dev_dbg(nhi->dev, "skipping host router reset\n");
1144:			return;
1145:		}
1146:	
1147:		iowrite32(REG_RESET_HRR, nhi->iobase + REG_RESET);
1148:		msleep(100);
1149:	
1150:		timeout = ktime_add_ms(ktime_get(), 500);
1151:		do {
1152:			val = ioread32(nhi->iobase + REG_RESET);
1153:			if (!(val & REG_RESET_HRR)) {
1154:				dev_warn(nhi->dev, "host router reset successful\n");
1155:				return;
1156:			}
1157:			usleep_range(10, 20);
1158:		} while (ktime_before(ktime_get(), timeout));
1159:	
1160:		dev_warn(nhi->dev, "timeout resetting host router\n");
1161:	}
 SourceFile:drivers/thunderbolt/nhi.c]

209/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 18178
							output: 41
							thoughts: 1238
						

Thoughts:
**My Thought Process on the Thunderbolt Driver Crash**

Ah, this original crash log looks incredibly familiar and highly suggestive. I'm seeing `thunderbolt 0000:00:07.0: timeout resetting host router` immediately followed by `BUG: unable to handle page fault for address: ffffc90000f70208`. This sequence strongly indicates that the `nhi_reset` function, which is responsible for resetting the host router, is indeed timing out and returning that specific error message. The subsequent page fault then happens *after* `nhi_reset` has completed, during the execution of `nhi_disable_interrupts` within `nhi_probe`.

The critical question for me is *why* this page fault is occurring in `nhi_disable_interrupts`. My initial thought leans towards the PCI device becoming unavailable. If the device has been removed or its memory space has been disabled, the memory region previously mapped using `ioremap` would no longer be valid. However, simply accessing a disabled memory space via `ioread32` typically results in a return value of `0xffffffff` (all ones), not a page fault, unless the underlying page table entry (PTE) has been completely unmapped.

So, the core of my investigation becomes: under what circumstances could a PTE for an `ioremap`'d address become unmapped while the `nhi_probe` function is still actively executing and holding the device lock?

If the device were hot-removed, the PCI subsystem would likely call functions like `pci_disable_device`, `pci_release_regions`, or `iounmap`. But since `nhi_probe` is still running and holds the device lock, it seems highly improbable that another thread could be performing these unmapping operations. This lock acquisition suggests exclusive access to the device's resources during the probing phase.

My mind then drifts to how `pcim_iomap_region` manages its mappings. It uses the device resource management (`devres`) framework. If `pcim_iomap_region` is used, the mapped region is automatically unmapped when the device is unbound. But here, we are in the *middle* of the binding process (the probe itself). So, the unbinding shouldn't have happened yet.

Could there be a scenario where the device is removed via sysfs, specifically the `remove` file? I recall `pci_stop_and_remove_bus_device` is involved in such operations. A quick check reveals that `pci_stop_and_remove_bus_device` eventually calls `device_release_driver`, which *does* acquire the device lock. This means that a sysfs removal attempt from another context would likely block until `nhi_probe` completes, thus preventing it from causing the unmapping during the probe.

What about virtual PCI devices? For devices like `syz_pci` or `vkms`, the memory backing their I/O regions might be managed differently and could potentially be freed. In QEMU, a hot-unplugged PCI device could have its memory region removed from the guest's physical address space. However, I'd expect this to result in a machine check exception or a `0xffffffff` read, not a kernel page fault indicating a "not-present page" in the kernel's page tables.

The specific error `BUG: unable to handle page fault for address: ffffc90003c99640` with a "not-present page" PTE points very strongly to `vunmap` or `iounmap` having been called. The question remains: who is calling `iounmap` during probe? The likely candidate is `pcim_iomap_release`, which is invoked during device unbinding or when probe fails.

But the crash is *during* the probe! This creates a paradox. Could `pcim_iomap_release` be called prematurely within the probe itself? It wouldn't be called if `pcim_iomap_region` *failed* to map, but the initial log suggests `nhi_reset` was called, implying the probe had progressed beyond the initial mapping stage. And `pci_disable_device` isn't the culprit here.

Then I look at the reproduced crash log carefully:
```
[   66.772482][ T5875] thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
[   66.775529][ T5875] thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
[   66.826037][ T5875] BUG: unable to handle page fault for address: ffffc90003c99640
...
[   66.871646][ T5875] Call Trace:
[   66.872712][ T5875]  <TASK>
[   66.873653][ T5875]  nhi_probe+0xcc/0x880
```
This specific reproduced crash occurs during the probe of `0000:00:03.0`, failing with `-EINVAL` (cannot enable interrupts), and *then* a page fault happens. The page fault is occurring within `nhi_probe` at the line `ioread32(nhi->iobase + REG_CAPS)`.

Now, here's a crucial point: the *probe for `0000:00:03.0` failed*. But the page fault occurs afterwards. Is this page fault happening on the *same device* that just failed its probe, or a *different* one? If the reproducer mechanism binds the device, it fails, and then attempts to bind it *again*, that would trigger `nhi_pci_probe` once more.

If the device is bound again, `pcim_iomap_region` is called again. And because `pcim_iomap_region` uses `devres`, any previous successful mapping for this device during the first probe would have been cleaned up by `devres` upon probe failure, which includes calling `iounmap`. So, the second call to `pcim_iomap_region` would be attempting to map the I/O region again.

The key question now is: why would this *second* attempt to map and then access the memory cause a page fault, even if `pcim_iomap_region` is called again and it might return the same virtual address? If it was successfully mapped again, the PTE should be valid! Unless... `pcim_iomap_region` itself is encountering an issue or not actually establishing the mapping correctly on the second attempt, or some other race condition is occurring during the re-probing process. I need to delve into the specifics of `pcim_iomap_region`'s behavior in this context.


210/4 2026/08/10 08:44 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/pci/pci.c Name:pcim_iomap_region]

Results:
map[SourceCode: 593:	/**
 594:	 * pcim_iomap_region - Request and iomap a PCI BAR
 595:	 * @pdev: PCI device to map IO resources for
 596:	 * @bar: Index of a BAR to map
 597:	 * @name: Name of the driver requesting the resource
 598:	 *
 599:	 * Returns: __iomem pointer on success, an IOMEM_ERR_PTR on failure.
 600:	 *
 601:	 * Mapping and region will get automatically released on driver detach. If
 602:	 * desired, release manually only with pcim_iounmap_region().
 603:	 */
 604:	void __iomem *pcim_iomap_region(struct pci_dev *pdev, int bar,
 605:					       const char *name)
 606:	{
 607:		int ret;
 608:		struct pcim_addr_devres *res;
 609:	
 610:		if (!pci_bar_index_is_valid(bar))
 611:			return IOMEM_ERR_PTR(-EINVAL);
 612:	
 613:		res = pcim_addr_devres_alloc(pdev);
 614:		if (!res)
 615:			return IOMEM_ERR_PTR(-ENOMEM);
 616:	
 617:		res->type = PCIM_ADDR_DEVRES_TYPE_REGION_MAPPING;
 618:		res->bar = bar;
 619:	
 620:		ret = pci_request_region(pdev, bar, name);
 621:		if (ret != 0)
 622:			goto err_region;
 623:	
 624:		res->baseaddr = pci_iomap(pdev, bar, 0);
 625:		if (!res->baseaddr) {
 626:			ret = -EINVAL;
 627:			goto err_iomap;
 628:		}
 629:	
 630:		devres_add(&pdev->dev, res);
 631:		return res->baseaddr;
 632:	
 633:	err_iomap:
 634:		pci_release_region(pdev, bar);
 635:	err_region:
 636:		pcim_addr_devres_free(res);
 637:	
 638:		return IOMEM_ERR_PTR(ret);
 639:	}
 SourceFile:drivers/pci/devres.c]

211/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 20170
							output: 38
							thoughts: 182
						

Thoughts:
**My Thought Process Regarding `pcim_iomap_region` and Error Handling**

Okay, let's break down what's going through my head right now, and it all centers around this specific piece of code related to PCI resource mapping. I'm looking at the `nhi_pci_probe` function, and I've just noticed something about how it handles the return value of `pcim_iomap_region`.

My initial thought is a bit of a "wait a minute..." moment. I see that `pcim_iomap_region` is supposed to return an I/O memory address, but crucially, the documentation or my understanding tells me it returns `IOMEM_ERR_PTR(ret)` when something goes wrong. This `IOMEM_ERR_PTR` macro is the key here. It's a common pattern in the kernel for functions that can return either a valid pointer or an error code wrapped in a pointer-sized integer.

Then, I look at how this return value is used. The code immediately following the call to `pcim_iomap_region` is:

```c
	res = PTR_ERR_OR_ZERO(nhi->iobase);
	if (res)
		return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
```

This is where my brain really kicks into gear. I know that `PTR_ERR_OR_ZERO` is designed to take a pointer that *might* be an error pointer, and if it is, it extracts the actual error code. If it's a valid pointer, it returns zero. This seems perfectly sensible on the surface.

However, my critical observation is this: `pcim_iomap_region` *explicitly* returns `IOMEM_ERR_PTR(ret)` on failure. This means `nhi->iobase` in the failure case *will* be a pointer that has been constructed using `IOMEM_ERR_PTR`.

So, my question becomes: what exactly *is* `IOMEM_ERR_PTR`? Is it simply wrapping a standard error number like `-ENOMEM` or `-ENODEV`? Or is it some other specific mechanism? The fact that `PTR_ERR_OR_ZERO` is used implies that `IOMEM_ERR_PTR` is designed to be compatible with the generic `PTR_ERR` mechanism (which `PTR_ERR_OR_ZERO` likely uses internally). If `IOMEM_ERR_PTR` just wraps a standard `ERRNO` value, then `PTR_ERR_OR_ZERO` should correctly identify it as an error and extract the `errno`. But I need to be absolutely sure about the exact implementation of `IOMEM_ERR_PTR` to confirm that `PTR_ERR_OR_ZERO` is indeed the correct and intended way to handle its failure return. My underlying concern is whether there's a subtle mismatch or an assumption being made about the error handling mechanism that might lead to unexpected behavior if `IOMEM_ERR_PTR` doesn't behave precisely as `PTR_ERR_OR_ZERO` expects.


212/4 2026/08/10 08:44 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:include/linux/err.h Name:IOMEM_ERR_PTR]

Results:
map[SourceCode: SourceFile:]

213/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 20395
							output: 23
							thoughts: 14
						

Thoughts:
**The Genesis of a Search:**

Alright, so I'm in the thick of it, wrestling with some sort of memory-related issue. I've been staring at this code, trying to pinpoint the source of a problem, and a specific string keeps popping into my head: `IOMEM_ERR_PTR`. It feels like a crucial piece of the puzzle, a potential indicator of where things are going awry. It's not just a random guess; my intuition, honed by years of experience in this domain, is telling me this identifier is likely tied to handling errors when accessing I/O memory. So, the most logical next step, the immediate imperative, is to **grep for `IOMEM_ERR_PTR`**. I need to see where this is being used, how it's being propagated, and what context it's appearing in. This search is the most direct path to uncovering the underlying behavior and hopefully, the root cause of the problem I'm facing.


214/4 2026/08/10 08:44 tool grepper
0m Args:
map[Expression:#define IOMEM_ERR_PTR]

Results:
map[Output:include/linux/err.h=39=static __always_inline void * __must_check ERR_PTR(long error)
--
include/linux/err.h-55-/* Cast an error pointer to __iomem. */
include/linux/err.h:56:#define IOMEM_ERR_PTR(error) (__force void __iomem *)ERR_PTR(error)
include/linux/err.h-57-
]

215/4 2026/08/10 08:44 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 20537
							output: 40
							thoughts: 255
						

Thoughts:
**My Thought Process Regarding `nhi_pci_probe` and Potential `ioread32` Faults**

Okay, so I'm digging into this `nhi_pci_probe` function and trying to understand how an `ioread32` could possibly page fault. My initial thought is that `IOMEM_ERR_PTR` is simply `ERR_PTR` cast to `void __iomem *`, and `PTR_ERR_OR_ZERO` handles it just fine. This means that if `pcim_iomap_region` fails, `nhi_pci_probe` correctly returns an error. Conversely, if `pcim_iomap_region` *succeeds*, then `nhi->iobase` *should* be a valid pointer.

This leads me to the core of my confusion: if `nhi->iobase` is indeed a valid pointer after `pcim_iomap_region` succeeds, then why would `ioread32` be causing a page fault? My first instinct is to suspect a race condition. Could `nhi->iobase` be freed by another thread concurrently? Specifically, what if the PCI device is unbound at the same time? However, I recall that `bind_store` acquires `device_lock`, which *should* prevent this kind of concurrent unbinding from invalidating `nhi->iobase`.

So, if it's not being freed, what else could be going wrong? My next hypothesis is that `nhi->iobase` might not be truly invalid, but rather the underlying PCI device itself is problematic. What if it's a virtual device, and its BAR (Base Address Register) is configured with a size of 0? Or, perhaps, even if it has a BAR, it's not actually mapped correctly into memory space by the kernel?

Then I remember that `pci_iomap` is the function responsible for mapping the BAR. This brings me back to the BAR length. If the BAR has a length of 0, what does `pci_iomap` do? Does it fail outright, or does it return some specific value that I'm not properly accounting for? I need to go and examine the implementation of `pci_iomap` to understand its behavior in such edge cases. That seems like the most logical next step to resolve this page fault mystery.


216/4 2026/08/10 08:45 tool codesearch-definition-source
0m Args:
map[ContextFile:lib/pci_iomap.c Name:pci_iomap]

Results:
map[SourceCode: 109:	/**
 110:	 * pci_iomap - create a virtual mapping cookie for a PCI BAR
 111:	 * @dev: PCI device that owns the BAR
 112:	 * @bar: BAR number
 113:	 * @maxlen: length of the memory to map
 114:	 *
 115:	 * Using this function you will get a __iomem address to your device BAR.
 116:	 * You can access it using ioread*() and iowrite*(). These functions hide
 117:	 * the details if this is a MMIO or PIO address space and will just do what
 118:	 * you expect from them in the correct way.
 119:	 *
 120:	 * @maxlen specifies the maximum length to map. If you want to get access to
 121:	 * the complete BAR without checking for its length first, pass %0 here.
 122:	 * */
 123:	void __iomem *pci_iomap(struct pci_dev *dev, int bar, unsigned long maxlen)
 124:	{
 125:		return pci_iomap_range(dev, bar, 0, maxlen);
 126:	}
 SourceFile:drivers/pci/iomap.c]

217/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 21170
							output: 42
							thoughts: 14
						

Thoughts:
**A Deep Dive into `pci_iomap_range` and Its Implications**

My immediate thought upon encountering this problem is to investigate the `pci_iomap_range` function. I need to understand its exact purpose, how it's intended to be used within the PCI subsystem, and more importantly, what potential issues or edge cases it might introduce or, conversely, mitigate. I'm thinking about its role in mapping I/O memory regions for PCI devices. This function likely deals with the complexities of address translation, bus mastering, and ensuring proper access to device-specific registers and memory. I'm particularly interested in its interaction with the underlying hardware and the operating system's memory management. Are there any known performance bottlenecks associated with its usage? Could there be race conditions if not handled carefully, especially in concurrent access scenarios? I'm also considering the implications for device drivers – what level of abstraction does `pci_iomap_range` provide, and what responsibilities are still left to the driver itself? Understanding the return values and potential error conditions will be crucial for robust driver development. I need to ascertain if it provides the necessary guarantees for reliable communication with the PCI device. The name itself, `iomap_range`, suggests a focus on mapping a specific range of I/O addresses. This implies that the function is probably responsible for setting up the necessary mappings in the system's I/O address space. I'm curious about how it handles alignment requirements, if any, and what happens if the requested range is invalid or overlaps with existing mappings. Furthermore, I need to consider its relationship with other PCI-related functions, such as those for device discovery and resource allocation. Does `pci_iomap_range` rely on prior successful resource allocation, or does it perform some of that validation itself? My objective is to gain a comprehensive understanding of its behavior and its place in the larger ecosystem of PCI device management, so that I can confidently assess its role in the current problem and identify any potential vulnerabilities or areas for optimization.


218/4 2026/08/10 08:45 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/pci/iomap.c Name:pci_iomap_range]

Results:
map[SourceCode:  14:	/**
  15:	 * pci_iomap_range - create a virtual mapping cookie for a PCI BAR
  16:	 * @dev: PCI device that owns the BAR
  17:	 * @bar: BAR number
  18:	 * @offset: map memory at the given offset in BAR
  19:	 * @maxlen: max length of the memory to map
  20:	 *
  21:	 * Using this function you will get a __iomem address to your device BAR.
  22:	 * You can access it using ioread*() and iowrite*(). These functions hide
  23:	 * the details if this is a MMIO or PIO address space and will just do what
  24:	 * you expect from them in the correct way.
  25:	 *
  26:	 * @maxlen specifies the maximum length to map. If you want to get access to
  27:	 * the complete BAR from offset to the end, pass %0 here.
  28:	 * */
  29:	void __iomem *pci_iomap_range(struct pci_dev *dev,
  30:				      int bar,
  31:				      unsigned long offset,
  32:				      unsigned long maxlen)
  33:	{
  34:		resource_size_t start, len;
  35:		unsigned long flags;
  36:	
  37:		if (!pci_bar_index_is_valid(bar))
  38:			return NULL;
  39:	
  40:		start = pci_resource_start(dev, bar);
  41:		len = pci_resource_len(dev, bar);
  42:		flags = pci_resource_flags(dev, bar);
  43:	
  44:		if (len <= offset || !start)
  45:			return NULL;
  46:	
  47:		len -= offset;
  48:		start += offset;
  49:		if (maxlen && len > maxlen)
  50:			len = maxlen;
  51:		if (flags & IORESOURCE_IO)
  52:			return __pci_ioport_map(dev, start, len);
  53:		if (flags & IORESOURCE_MEM)
  54:			return ioremap(start, len);
  55:		/* What? */
  56:		return NULL;
  57:	}
 SourceFile:drivers/pci/iomap.c]

219/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 21861
							output: 37
							thoughts: 334
						

Thoughts:
**The Curious Case of the `ioremap`ed Page Fault**

So, I'm thinking about this `ioremap` situation. The core of it is, if `ioremap` gives me a valid pointer, why would I get a page fault when I try to access it? It seems counterintuitive. My immediate thought is about the physical address `start` being invalid. But then I recall how `ioremap` works: it's supposed to map a physical address into the kernel's page tables. If the physical address isn't backed by anything, like on x86, I'd expect reads to just return all ones (effectively `0xffffffff`), and writes to be silently dropped. A page fault, specifically a "not-present page" fault (`error_code(0x0000)` or `error_code(0x0002)`), indicates that the page table entry *itself* is missing. How could that happen for an address that `ioremap` supposedly set up?

This leads me to consider a couple of scenarios. Firstly, perhaps the region was unmapped *after* `ioremap` but *before* the access. This would happen if `iounmap` was called in the interim. Secondly, I might be accessing an address *beyond* the region that was actually mapped. For instance, `ioremap` might have mapped only 4KB, but my current operation is attempting to read from an offset that's 8KB into the intended BAR.

This brings me to a crucial point: what *is* the size of this BAR? I know that if the BAR size is reported as 0, `pci_iomap_range` would have returned NULL. But if the size is, say, just 1 byte, `ioremap` will still map a full page, which is 4KB. So, even with a tiny BAR, the mapped region is substantial. The real question then becomes, if I'm accessing an offset beyond that initial 4KB (or whatever the mapped size is), that's where the problem might lie.

Looking at the `nhi_probe` function, I see this line: `nhi->hop_count = ioread32(nhi->iobase + REG_CAPS) & 0x3ff;`. This is where the potential issue arises. I need to understand what `REG_CAPS` represents and, more importantly, its offset relative to `nhi->iobase`. If `REG_CAPS` is located beyond the initial mapped region of the BAR, and the BAR itself was mapped with a size that doesn't encompass `REG_CAPS`, then I'd get that "not-present page" fault because the page table entry for that specific address would indeed be missing. That's the puzzle I'm trying to solve here.


220/4 2026/08/10 08:45 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:REG_CAPS]

Results:
map[SourceCode: SourceFile:]

221/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 22237
							output: 20
							thoughts: 11
						

Thoughts:
**My Thought Process on Approaching the `REG_CAPS` Search**

Alright, so my immediate impulse, as I'm scanning this text and looking to understand the context around `REG_CAPS`, is to see where this specific string appears. My mind automatically goes to the most direct and efficient method for finding exact occurrences of a pattern within a body of text, especially when I'm dealing with code or configuration-like data.

Therefore, my first internal step is to think: "How can I quickly locate every instance of `REG_CAPS`?" And that naturally leads me to the command-line utility `grep`. It's the go-to tool for this kind of pattern matching. So, in my head, the action is quite straightforward: "Let's grep for `REG_CAPS`." It's not a complex inference or a deep dive into semantics at this stage; it's a tactical decision driven by the need for precise identification of the target string. I'm not thinking about *why* it's there yet, or what its implications are, but simply *where* it is. This initial `grep` command is my first step in orienting myself within the data and understanding its distribution.


222/4 2026/08/10 08:45 tool grepper
0m Args:
map[Expression:#define REG_CAPS]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-113-/* The last 11 bits contain the number of hops supported by the NHI port. */
drivers/thunderbolt/nhi_regs.h:114:#define REG_CAPS			0x39640
drivers/thunderbolt/nhi_regs.h:115:#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
drivers/thunderbolt/nhi_regs.h:116:#define REG_CAPS_VERSION_2		0x40
drivers/thunderbolt/nhi_regs.h-117-
]

223/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 22443
							output: 40
							thoughts: 391
						

Thoughts:
**My Thought Process Unraveling the Crash**

Okay, so my initial thought upon seeing `REG_CAPS` with the value `0x39640` was to immediately translate that hexadecimal value into a more tangible byte count. I realized `0x39640` equates to 235072 bytes, which is roughly 229 KB. This number is significant because it represents a potential size requirement for a memory-mapped I/O (MMIO) region.

My next crucial realization was the potential for a mismatch between the required size (`REG_CAPS`) and the actual size of the Base Address Register (BAR) that gets `ioremap`ped. If the BAR is smaller than `0x39640 + 4` (I'm adding 4 for potential alignment or boundary considerations), then the `ioremap` call will effectively map a smaller region than what the device might expect.

This immediately raised a red flag: if the mapped region is smaller than what's needed, then an attempt to access `nhi->iobase + 0x39640` would very likely be *out of bounds* of the actually mapped region. Knowing that `ioremap` (and `vmalloc`) space is typically protected with guard pages, I understood that attempting to access memory beyond these boundaries would trigger a page fault, which aligns perfectly with the observed crash behavior.

To confirm this hypothesis, I turned my attention to the crash addresses. I noticed a striking similarity between the reproduced crash address (`CR2: ffffc90003c99640`, `RBX: ffffc90003c99640`) and the `REG_CAPS` value. Specifically, the lower bits of the reproduced crash address, `0x9640`, are a direct match to the tail end of `0x39640`. This led me to deduce that if `nhi->iobase` happened to be `ffffc90003c60000`, then `nhi->iobase + 0x39640` would precisely result in `ffffc90003c99640`, matching the `CR2` value reported in the crash. This was a strong indicator.

Then, I examined the *original* crash address (`CR2: ffffc90000f70208`, `RBX: ffffc90000f70208`). The lower bits here are `0x0208`. I recalled that the original crash occurred within the `iowrite32` function in `nhi_disable_interrupts`. While the exact origin of `0x0208` wasn't immediately obvious from the `REG_CAPS` value alone, the consistent pattern seen in the *reproduced* crash, coupled with the knowledge of the function where the original crash occurred, strongly suggested that the issue stemmed from the `REG_CAPS` offset being used to access memory that wasn't properly mapped due to BAR size limitations. The `0x0208` in the original crash likely represents a different offset or an earlier symptom of a similar underlying problem, but the reproduced crash data with the `0x9640` tail provided the smoking gun for my current line of investigation.


224/4 2026/08/10 08:45 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_disable_interrupts]

Results:
map[SourceCode: 152:	/*
 153:	 * nhi_disable_interrupts() - disable interrupts for all rings
 154:	 *
 155:	 * Use only during init and shutdown.
 156:	 */
 157:	void nhi_disable_interrupts(struct tb_nhi *nhi)
 158:	{
 159:		int i = 0;
 160:		/* disable interrupts */
 161:		for (i = 0; i < RING_INTERRUPT_REG_COUNT(nhi); i++)
 162:			nhi_mask_interrupt(nhi, ~0, 4 * i);
 163:	
 164:		/* clear interrupt status bits */
 165:		for (i = 0; i < RING_NOTIFY_REG_COUNT(nhi); i++)
 166:			nhi_clear_interrupt(nhi, 4 * i);
 167:	}
 SourceFile:drivers/thunderbolt/nhi.c]

225/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 23138
							output: 39
							thoughts: 12
						

Thoughts:
**My Thought Process Regarding `nhi_mask_interrupt`**

Right, so the immediate priority for me is to investigate `nhi_mask_interrupt`. I need to understand its functionality, its current state, and how it's interacting with the broader system. My initial instinct is to dive into the code itself, examining its definition and any associated configurations or dependencies. I'll be looking for clarity on what it actually *does* – is it a flag, a handler, a mechanism for selective interruption? Understanding its purpose is foundational. Then, I'll trace its execution path. Where is it called? What conditions trigger its invocation? Conversely, what conditions allow it to be bypassed or de-asserted? This will give me a sense of its operational context. Furthermore, I'll be scrutinizing its impact. Does it correctly enable or disable specific interrupts as intended? Are there any unintended side effects or potential race conditions that might arise from its use? My goal is to establish a definitive understanding of `nhi_mask_interrupt`'s behavior, its intended purpose, and its actual implementation, before moving on to any further analysis or modifications.


226/4 2026/08/10 08:45 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:nhi_mask_interrupt]

Results:
map[SourceCode:  51:	static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
  52:	{
  53:		if (nhi->quirks & QUIRK_AUTO_CLEAR_INT) {
  54:			u32 val;
  55:	
  56:			val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  57:			iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
  58:		} else {
  59:			iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
  60:		}
  61:	}
 SourceFile:drivers/thunderbolt/nhi.c]

227/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 23403
							output: 29
							thoughts: 18
						

Thoughts:
**My Thought Process Regarding `REG_RING_INTERRUPT_MASK_CLEAR_BASE`**

Okay, so my immediate mental leap is to dissect that identifier, `REG_RING_INTERRUPT_MASK_CLEAR_BASE`. It's clearly a macro or a constant defined within a hardware register context, and as an expert, I know these naming conventions are designed to be informative.

First, the `REG_` prefix immediately tells me I'm dealing with a hardware register. This isn't some arbitrary software variable; it's a specific memory location within a chip that controls or reflects the state of some hardware component.

Then comes `RING`. This is the key functional area. My mind immediately goes to ring buffers, circular buffers, or perhaps some kind of signaling ring architecture. In the context of interrupts, a ring buffer often implies a mechanism for accumulating and reporting events or data. It could be a descriptor ring for DMA, a completion ring for an accelerator, or a message passing ring. The "ring" nature suggests a cyclical, fixed-size structure where new items replace old ones or where a pointer moves around.

The next part, `INTERRUPT`, is self-explanatory. This register is directly involved with interrupt generation, masking, or handling. This means it's related to signaling the CPU or another processing unit that an event has occurred.

Now, `MASK_CLEAR`. This is where the action becomes clear. It's not just about *enabling* or *disabling* interrupts in a general sense, but specifically about *clearing* a mask. Interrupt masks are used to selectively ignore or acknowledge specific interrupt sources. So, `MASK_CLEAR` implies that I'm performing an operation that *unmasks* or *enables* a particular interrupt source that was previously masked. This is crucial for fine-grained control over interrupt flow, allowing specific events to be heard while others remain silent. The "clear" operation often implies writing a specific value (like a '1' to a bit position) to a mask register to de-assert a masking condition.

Finally, `BASE`. This is the clincher. The `BASE` suffix strongly suggests that this identifier represents the starting address or the base register for a block of registers related to the ring interrupt masking functionality. It's unlikely to be a single bit or a single register on its own. Instead, it's the entry point into a set of registers that collectively manage the interrupt masks for the ring. I'd expect to find related offsets from this `BASE` address for individual interrupt sources within the ring, or perhaps other control/status registers associated with this ring's interrupt handling. This `BASE` value is what I'd use to calculate the addresses of other related registers by adding offsets.

So, in essence, my thought process is: "This is a hardware register, specifically related to interrupt control for a ring-based component, and this particular identifier points to the base address for the register block responsible for *clearing* (i.e., unmasking) specific interrupt sources within that ring." It's a fundamental building block for enabling targeted interrupt notifications from a ring mechanism.


228/4 2026/08/10 08:45 tool grepper
0m Args:
map[Expression:#define REG_RING_INTERRUPT_MASK_CLEAR_BASE]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-101-
drivers/thunderbolt/nhi_regs.h:102:#define REG_RING_INTERRUPT_MASK_CLEAR_BASE	0x38208
drivers/thunderbolt/nhi_regs.h-103-
]

229/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 23546
							output: 42
							thoughts: 1802
						

Thoughts:
**It seems I've pinpointed the root cause of these crashes.** My initial thought was to look at the crash addresses themselves, specifically `0x38208`. I noticed that the lower bits, `8208`, seemed significant, and then I recalled the original crash address: `ffffc90000f70208`. By hypothesizing that `nhi->iobase` was `ffffc90000f38000`, I saw that `nhi->iobase + 0x38208` perfectly matched the crash address. This strongly suggested that the problem was an out-of-bounds MMIO access due to an undersized PCI BAR.

Then, I started to analyze the relationship between `0x38208` and `REG_CAPS` (which is `0x39640`). My initial logic was that if the BAR was large enough to cover `0x39640`, it should certainly cover the smaller `0x38208`. This led me to question why the original crash occurred at `0x38208` and not at `REG_CAPS`.

I re-examined the `nhi_probe` function and considered a BAR size, say `0x39000`. Under this assumption, `0x38208` would be within the BAR, but `0x39640` would be outside. This, however, contradicted the original crash, which *didn't* crash at `REG_CAPS`.

I then considered a BAR size of `0x38000`. With this, `0x38208` would be out of bounds. But again, `REG_CAPS` (`0x39640`) would *also* be out of bounds. The crucial insight here was how `ioremap` functions: it maps in page granularity (4KB). If the BAR size was `0x38000`, `ioremap` would map exactly that much. This means `0x38208` would fall into the *next* unmapped page, and `REG_CAPS` at `0x39640` would be in the page *after that*. So, if `0x38208` was unmapped, `0x39640` should also be unmapped. This still didn't explain why the `ioread32` at `REG_CAPS` in the original crash didn't fail.

I went back to the original crash trace, which showed the crash happening at line 1211 of `nhi.c`, which is `nhi_disable_interrupts(nhi);`. This confirmed that `ioread32(nhi->iobase + REG_CAPS)` at line 1198 had successfully executed. This was the critical point: `REG_CAPS` *was* accessible, but `0x38208` was not. This is counter-intuitive since `0x39640` is numerically larger than `0x38208`.

I then looked at the physical addresses involved. If `nhi->iobase` was `ffffc90000f38000`, then `nhi->iobase + 0x38208` results in `ffffc90000f70208`. The address for `REG_CAPS`, `nhi->iobase + 0x39640`, would be `ffffc90000f71640`. I realized these addresses fall into *different* memory pages (page `0x38000` for the former, and `0x39000` for the latter, relative to the mapped region).

My hypothesis is now that `ioremap` mapped a range that *included* the page containing `0x39640`, but *excluded* the page containing `0x38208`. This would happen if, for instance, `ioremap` was called with a length that ended *just before* the start of the page containing `0x38208`, but extended into the page containing `0x39640`. The fact that the original crash occurred at `0x38208` and the new one at `0x38208` further solidifies that this specific offset is the problem, and my reasoning that the BAR size is too small to encompass it is correct. The current analysis suggests that the BAR size is too small, leading to an unmapped region at `0x38208`, while `REG_CAPS` at `0x39640` might be in a mapped region, or its access is somehow more resilient or happens before the problematic access in a different scenario. The key is that `0x38208` is definitely out of bounds for the BAR. The fact that I'm now seeing the same issue at `0x38208` confirms it's the same underlying bug.


230/4 2026/08/10 08:45 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/nhi.c Name:RING_INTERRUPT_REG_COUNT]

Results:
map[SourceCode: SourceFile:]

231/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 25395
							output: 25
							thoughts: 16
						

Thoughts:
**My Thought Process for Investigating the `RING_INTERRUPT_REG_COUNT` Symbol**

Okay, so the immediate thought that comes to mind when presented with the task of summarizing this particular "thought" is a very direct one: I need to understand the *purpose* and *implication* of searching for a specific symbol like `RING_INTERRUPT_REG_COUNT` using a tool like `grep`. Given that I'm an expert in this domain, my mind naturally jumps to the underlying systems and contexts where such a symbol would appear.

My internal monologue would likely start with something like: "Alright, what does `RING_INTERRUPT_REG_COUNT` even mean? The name itself is a strong clue." I'd break it down:

*   **`RING`**: This immediately suggests some kind of circular buffer, queue, or ring buffer mechanism. In system programming and driver development, ring buffers are ubiquitous for efficient data transfer and interrupt handling. Think network packets, DMA operations, or event queues.
*   **`INTERRUPT`**: This is unambiguous. It points to an interrupt service routine (ISR) or some form of interrupt-driven notification. This means the system is reacting to an event, and this symbol is likely related to managing those events.
*   **`REG_COUNT`**: This part is interesting. `REG` could mean register, but in this context, given `COUNT`, it's more likely referring to the *number of registers* involved in some interrupt-related operation. Or, perhaps more pertinently, it's a *count* of something *related to interrupt registers*. The most plausible interpretation, especially in the context of ring buffers and interrupts, is that it signifies the number of entries or slots within a ring buffer that are *specifically designated for interrupt-related data or status*. This could be the number of interrupt status registers, the number of descriptors in an interrupt ring, or even the number of interrupt queues.

So, the initial hypothesis is that `RING_INTERRUPT_REG_COUNT` is a constant or a variable that defines the size or capacity of a ring buffer used for managing or reporting interrupt events.

Now, *why would I `grep` for it?*

My expertise tells me that `grep` is a fundamental tool for code searching. If I'm looking for this symbol, it means I'm trying to:

1.  **Locate its definition:** Where is this constant/variable declared and initialized? This is the most basic step. Knowing its definition will reveal its data type, its value, and potentially the scope in which it's used.
2.  **Understand its usage:** Where is this value being *read* from and *written* to? This is crucial for understanding the *behavior* of the system.
    *   **Reads:** If I see it being read, it's likely being used to:
        *   Initialize the size of a data structure (e.g., `allocate_ring_buffer(RING_INTERRUPT_REG_COUNT)`).
        *   Control loop iterations in an ISR or a polling mechanism that processes interrupts (`for (i = 0; i < RING_INTERRUPT_REG_COUNT; i++)`).
        *   Check bounds or validity of an index into an interrupt-related array or buffer.
        *   Configure hardware registers that might expect a count of interrupt sources or descriptors.
    *   **Writes:** If I see it being written to, it's less likely to be a "count" in the sense of a mutable counter, and more likely that its *value* is being *assigned* to something else, or perhaps a configuration register is being programmed with this count. However, if it *is* mutable, it could indicate dynamic adjustment of interrupt handling capacity, which would be a significant observation.
3.  **Identify related components:** By seeing where `RING_INTERRUPT_REG_COUNT` is used, I can pinpoint the specific modules, drivers, or subsystems that are responsible for interrupt handling and ring buffer management. This helps in understanding the architecture.
4.  **Debug or analyze behavior:** If I'm facing an issue related to interrupt processing, performance bottlenecks, or incorrect interrupt signaling, finding all occurrences of this symbol would be a primary debugging step. It would help me trace the flow of interrupt-related data and identify potential misconfigurations or logic errors.
5.  **Understand system configuration:** In some systems, constants like these might be configurable via build flags or configuration files. `grep` would help me find where these configurations are applied or referenced.

So, when I think "Let's grep for `RING_INTERRUPT_REG_COUNT`," it's not just a command; it's the initiation of a deep dive into the interrupt handling subsystem. It's about systematically uncovering how the system manages its interrupt events, what its capacity is, and how these parameters are applied throughout the code. It's a signal that I'm about to start mapping out a critical piece of the system's operational logic. The "thought" is the precursor to action, a strategic move in understanding complex software.


232/4 2026/08/10 08:45 tool grepper
0m Args:
map[Expression:#define RING_INTERRUPT_REG_COUNT]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-99-#define REG_RING_INTERRUPT_BASE	0x38200
drivers/thunderbolt/nhi_regs.h:100:#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
drivers/thunderbolt/nhi_regs.h-101-
]

233/4 2026/08/10 08:45 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 25559
							output: 24
							thoughts: 2318
						

Thoughts:
**The Unraveling of the Page Fault: A Deep Dive into Memory Mapping and Device State**

My mind is racing, trying to piece together this perplexing page fault. The initial thought process centered around `RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)`, which relies on `nhi->hop_count` read from `REG_CAPS`. My immediate concern was, if `REG_CAPS` was unmapped, `ioread32` would trigger a page fault. Yet, the original crash report indicated no page fault on `REG_CAPS`, suggesting it *was* mapped. This implied that the memory region starting from `nhi->iobase` up to `0x39640` (the offset for `REG_CAPS`) was indeed mapped.

This leads to a critical question: if this region was mapped, why did a later access, specifically `nhi->iobase + 0x38208 + 4*i` (where `0x38208` is `REG_RING_INTERRUPT_MASK_CLEAR_BASE`), cause a page fault? I initially reasoned that `i` being very large could be the culprit. If `nhi->hop_count` was its maximum value of `0x3ff` (1023), then `RING_INTERRUPT_REG_COUNT` becomes 64, meaning `i` could go up to 63. The maximum address accessed would be `0x38208 + 4 * 63 = 0x38304`. This address is still well within the same page as `0x38208` and importantly, *less* than `0x39640`. So, if `0x39640` was mapped, `0x38208` absolutely should have been.

I briefly entertained the idea that `nhi->iobase` might not be mapped contiguously, but quickly dismissed it, as `ioremap` guarantees contiguous mappings. Then, my attention shifted to the page fault error code: `#PF: supervisor write access in kernel mode` and `#PF: error_code(0x0002) - not-present page`. This indicates a write attempt to a page that's not present in the page tables. However, `ioremap` typically maps pages as read-write. So, why would a page be marked as "not-present" for writing, yet potentially present for reading? Or perhaps it wasn't present for reading either, and we just didn't attempt to read it in that specific erroneous sequence.

This brings me back to the original crash. If `REG_CAPS` (at `0x39640`) was mapped and readable, how could `REG_RING_INTERRUPT_MASK_CLEAR_BASE` (at `0x38208`) be unmapped? The offset `0x39640` is greater than `0x38208`. If the BAR encompasses `0x39640`, it *must* encompass `0x38208`.

Then, a crucial realization struck me: the original crash *didn't* page fault on `REG_CAPS`. The *reproduced* crash *did* page fault on `ioread32(nhi->iobase + REG_CAPS)`. This fundamentally changes the scenario. In the reproduced crash, the very *first* memory access to `REG_CAPS` caused the page fault. This means that at the moment `ioread32(nhi->iobase + REG_CAPS)` was executed, the page containing `REG_CAPS` was simply not mapped.

This leads to a new line of inquiry: if `REG_CAPS` was unmapped, how could any subsequent accesses be expected to succeed, especially if they are to addresses within the same BAR? The original crash, which faulted *later*, might have had a different BAR size initially, or the mapping was valid at the time of the `REG_CAPS` read, but became invalid for later accesses.

Considering the possibility of concurrent operations, could the device have been hot-unplugged or its memory unmapped concurrently? If `iounmap` happened *between* the successful read of `REG_CAPS` (in the original crash scenario, which is now in question) and the subsequent write, it would explain a later page fault. However, with the *reproduced* crash faulting on the *initial* `ioread32(REG_CAPS)`, the timing of an unmap is less relevant to that specific fault point, but it's still a strong contender for the *original* crash's behavior.

My current thought process is that the core issue is the dynamic nature of memory mapping and device state. The fact that `REG_CAPS` (at `0x39640`) and `REG_RING_INTERRUPT_MASK_CLEAR_BASE` (at `0x38208`) are at different offsets within the BAR is key. If the BAR size itself is smaller than `0x39640`, then *both* could be unmapped. But if `REG_CAPS` was read successfully in one instance, it implies it *was* mapped at that time. This suggests a race condition or a state change of the device's memory mapping. The most plausible explanation for a page fault on an `ioremap`-ed region is that `iounmap` was called. The crucial question becomes: how is `iounmap` being called concurrently or out of sync with driver operations, especially given the `device_lock`? Perhaps an alternative device removal path or a specific VF scenario is bypassing this lock. The fact that it's a write fault on a "not-present" page strongly points to the underlying physical memory no longer being mapped into the kernel's virtual address space.


234/4 2026/08/10 08:46 tool grepper
0m Args:
map[Expression:#define REG_RING_NOTIFY_BASE]

Results:
map[Output:drivers/thunderbolt/nhi_regs.h=34=struct ring_desc {
--
drivers/thunderbolt/nhi_regs.h-89- */
drivers/thunderbolt/nhi_regs.h:90:#define REG_RING_NOTIFY_BASE	0x37800
drivers/thunderbolt/nhi_regs.h-91-#define RING_NOTIFY_REG_COUNT(nhi) ((31 + 3 * nhi->hop_count) / 32)
]

235/4 2026/08/10 08:46 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 28021
							output: 40
							thoughts: 2447
						

Thoughts:
**The Curious Case of the Unmapped Register**

I've been trying to untangle this crash, and it's been a real journey of deduction. Initially, I was fixated on the addresses themselves. I noted that `0x37800` was smaller than `0x39640`, and by extension, all those registers I was looking at were smaller than `0x39640`. My thought process was, if `0x39640` is mapped, how could `0x38208` possibly be unmapped? This seemed like a contradiction that needed explaining.

Then I went back to the original crash trace, specifically the call stack:

```
 nhi_mask_interrupt drivers/thunderbolt/nhi.c:-1 [inline]
 nhi_disable_interrupts+0x150/0x350 drivers/thunderbolt/nhi.c:162
 nhi_probe+0x2be/0x880 drivers/thunderbolt/nhi.c:1211
```

The crash occurred in `nhi_mask_interrupt`, which looks like this:

```c
	static void nhi_mask_interrupt(struct tb_nhi *nhi, int mask, int ring)
	{
		if (nhi->quirks & QUIRK_AUTO_CLEAR_INT) {
			u32 val;
			val = ioread32(nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
			iowrite32(val & ~mask, nhi->iobase + REG_RING_INTERRUPT_BASE + ring);
		} else {
			iowrite32(mask, nhi->iobase + REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring);
		}
	}
```

I observed that if the `QUIRK_AUTO_CLEAR_INT` quirk was set, it accessed `REG_RING_INTERRUPT_BASE + ring`, which translates to `0x38200 + ring`. If it wasn't set (the `else` branch), it accessed `REG_RING_INTERRUPT_MASK_CLEAR_BASE + ring`, which is `0x38208 + ring`.

The crash address ended in `0208`, which meant it definitely accessed `0x38208`. This implied that `ring` was 0 and the code took the `else` branch, crashing on the very first iteration of the loop with `iowrite32(mask, nhi->iobase + 0x38208);`.

This led me to a crucial question: why did it crash on this `iowrite32` to `0x38208`, but *not* on the `ioread32(nhi->iobase + 0x39640)` that happened earlier in `nhi_probe`?

My initial thoughts were about the `nhi->iobase` pointer changing, but that's highly unlikely as it's a stable pointer within the `struct tb_nhi`. Then I considered if `ioread32` to an unmapped address might behave differently than `iowrite32` on certain architectures, but page faults generally occur for both on non-present pages.

The breakthrough came when I considered the possibility that the page table entry *was* present, but was marked READ-ONLY. If that were the case, `ioread32` would succeed, but `iowrite32` would indeed cause a page fault. However, the `ioremap` function typically maps pages as read-write (`PAGE_KERNEL_IO`), so a read-only mapping seemed improbable.

Then I looked at the error code from the crash: `#PF: error_code(0x0002) - not-present page`. The 'Present' bit (bit 0) was 0, confirming the page was not present. The 'Write' bit (bit 1) was 1, indicating a write access. If the page was truly not present, a *read* access to `REG_CAPS` (`0x39640`) should also have caused a page fault, with an error code of `0x0000`. This discrepancy was the key.

How could it survive the `ioread32(REG_CAPS)` if the page was not present? I started thinking about memory mapping and the virtual address space. `0x39640` falls into page `0x39000`, and `0x38208` falls into page `0x38000`. Could page `0x39000` be present, while page `0x38000` was not?

My understanding of `ioremap` is that it maps a *contiguous* physical range. It allocates a contiguous virtual range and then maps the physical pages. The idea of `ioremap` failing halfway or someone calling `vunmap` on a partial range seemed unlikely, as `ioremap` would return NULL, and `vunmap` unmaps the whole area.

Then I considered what happens if the physical address wraps around. But the `pci_iomap_range` function has a check: `if (len <= offset || !start) return NULL;`. So, if `start` is 0, it should return NULL, preventing mapping of physical address 0.

This led me to a new hypothesis, which feels quite plausible now. What if the issue isn't with memory being unmapped in the way I was thinking, but rather with the *size* of the mapped region? The crash trace shows `nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");`. This maps BAR 0. What if BAR 0 is unexpectedly small, say, only 4KB?

If the mapped region is only 4KB, then accessing `nhi->iobase + 0x39640` (which is 235KB into the mapping) would be out of bounds. Now, why wouldn't that cause a page fault on the `ioread32`? This is where the nature of the virtual memory system comes into play. The vmalloc space is densely packed, and there are guard pages between allocations. It's entirely possible that `nhi->iobase + 0x39640` *accidentally* fell into *another* valid vmalloc mapping that happened to be adjacent. In this scenario, `ioread32` would simply read garbage data from that unrelated mapping and *not* trigger a page fault.

However, `nhi->iobase + 0x38208` (230KB into the mapping) might have landed in a guard page or an unmapped hole between vmalloc regions. This would then cause the page fault on `iowrite32`, as observed. This would perfectly explain why the read succeeded but the write failed, and why the crash occurred later in the function.

The crucial missing piece, in my opinion, is that the driver never checks the *size* of the BAR it's mapping. If a malicious or virtual PCI device (like syz_pci) provides a BAR 0 with a tiny size, the driver proceeds assuming it's large enough, leading to these out-of-bounds accesses. The observed behavior seems to be a direct consequence of this missing BAR size validation.


236/4 2026/08/10 08:46 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

237/4 2026/08/10 08:46 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 31125
							output: 18
							thoughts: 191
						

Thoughts:
**My Thought Process Regarding PCI Resource Allocation**

It's become strikingly apparent to me that there's a critical oversight in the current driver implementation: the complete absence of a check for `pci_resource_len(pdev, 0)`. This is a significant vulnerability. The driver is operating under the dangerous assumption that the memory region allocated for BAR 0 is inherently large enough to accommodate all the registers it needs to access.

My immediate concern is to identify the absolute maximum register offset that the driver might attempt to access. Initially, I considered `REG_CAPS`, which has an offset of `0x39640`. However, I then recalled `RING_INTERRUPT_REG_COUNT`, which can be as large as 64. Coupled with `REG_RING_INTERRUPT_MASK_CLEAR_BASE` at `0x38208`, this immediately pushes the potential maximum to `0x38208 + 4 * 64 = 0x38308`. This is already close to `REG_CAPS`.

This leads me to question if there are other registers beyond these that I haven't yet considered. To get a definitive answer and ensure I'm not missing anything, my next step must be to meticulously examine `nhi_regs.h` to identify the absolute highest register offset defined within the driver's register map. This comprehensive review is essential for understanding the true extent of BAR 0's required size and to rectify this potentially exploitable flaw.


238/4 2026/08/10 08:46 tool grepper
0m Args:
map[Expression:#define REG_]

Results:
map[Output:
Full output is too long, showing 500 out of 22435 lines.
Use more precise expression if possible.

arch/alpha/kernel/pc873xx.h-8- */
arch/alpha/kernel/pc873xx.h:9:#define REG_FER	0x00
arch/alpha/kernel/pc873xx.h:10:#define REG_FAR	0x01
arch/alpha/kernel/pc873xx.h:11:#define REG_PTR	0x02
arch/alpha/kernel/pc873xx.h:12:#define REG_FCR	0x03
arch/alpha/kernel/pc873xx.h:13:#define REG_PCR	0x04
arch/alpha/kernel/pc873xx.h:14:#define REG_KRR	0x05
arch/alpha/kernel/pc873xx.h:15:#define REG_PMC	0x06
arch/alpha/kernel/pc873xx.h:16:#define REG_TUP	0x07
arch/alpha/kernel/pc873xx.h:17:#define REG_SID	0x08
arch/alpha/kernel/pc873xx.h:18:#define REG_ASC	0x09
arch/alpha/kernel/pc873xx.h:19:#define REG_IRC	0x0e
arch/alpha/kernel/pc873xx.h-20-
--
arch/arc/include/asm/disasm.h=22=enum flow {
--
arch/arc/include/asm/disasm.h-71-#define STATUS32_L		0x00000100
arch/arc/include/asm/disasm.h:72:#define REG_LIMM		62
arch/arc/include/asm/disasm.h-73-
--
arch/arc/kernel/ptrace.c=15=struct pt_regs_offset {
--
arch/arc/kernel/ptrace.c-19-
arch/arc/kernel/ptrace.c:20:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/arc/kernel/ptrace.c:21:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arc/kernel/ptrace.c-22-
--
arch/arc/kernel/ptrace.c=161=static int genregs_set(struct task_struct *target,
--
arch/arc/kernel/ptrace.c-169-
arch/arc/kernel/ptrace.c:170:#define REG_IN_CHUNK(FIRST, NEXT, PTR)	\
arch/arc/kernel/ptrace.c-171-	if (!ret)			\
--
arch/arc/kernel/ptrace.c-176-
arch/arc/kernel/ptrace.c:177:#define REG_IN_ONE(LOC, PTR)		\
arch/arc/kernel/ptrace.c-178-	if (!ret)			\
--
arch/arc/kernel/ptrace.c-183-
arch/arc/kernel/ptrace.c:184:#define REG_IGNORE_ONE(LOC)		\
arch/arc/kernel/ptrace.c-185-	if (!ret)			\
--
arch/arc/kernel/unwind.c=56=UNW_REGISTER_INFO};
--
arch/arc/kernel/unwind.c-61-#ifndef REG_INVALID
arch/arc/kernel/unwind.c:62:#define REG_INVALID(r) (reg_info[r].width == 0)
arch/arc/kernel/unwind.c-63-#endif
--
arch/arc/net/bpf_jit_arcv2.c=65=static const u8 bpf2arc[][2] = {
--
arch/arc/net/bpf_jit_arcv2.c-90-
arch/arc/net/bpf_jit_arcv2.c:91:#define REG_LO(r) (bpf2arc[(r)][0])
arch/arc/net/bpf_jit_arcv2.c:92:#define REG_HI(r) (bpf2arc[(r)][1])
arch/arc/net/bpf_jit_arcv2.c-93-
--
arch/arm/include/debug/brcmstb.S-6-/* Physical register offset and virtual register offset */
arch/arm/include/debug/brcmstb.S:7:#define REG_PHYS_BASE		0xf0000000
arch/arm/include/debug/brcmstb.S:8:#define REG_PHYS_BASE_V7	0x08000000
arch/arm/include/debug/brcmstb.S:9:#define REG_VIRT_BASE		0xfc000000
arch/arm/include/debug/brcmstb.S:10:#define REG_PHYS_ADDR(x)	((x) + REG_PHYS_BASE)
arch/arm/include/debug/brcmstb.S:11:#define REG_PHYS_ADDR_V7(x)	((x) + REG_PHYS_BASE_V7)
arch/arm/include/debug/brcmstb.S-12-
--
arch/arm/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/arm/kernel/perf_regs.c-18-
arch/arm/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_ARM_MAX) - 1))
arch/arm/kernel/perf_regs.c-20-
--
arch/arm/kernel/ptrace.c-32-
arch/arm/kernel/ptrace.c:33:#define REG_PC	15
arch/arm/kernel/ptrace.c:34:#define REG_PSR	16
arch/arm/kernel/ptrace.c-35-/*
--
arch/arm/kernel/ptrace.c=59=struct pt_regs_offset {
--
arch/arm/kernel/ptrace.c-63-
arch/arm/kernel/ptrace.c:64:#define REG_OFFSET_NAME(r) \
arch/arm/kernel/ptrace.c-65-	{.name = #r, .offset = offsetof(struct pt_regs, ARM_##r)}
arch/arm/kernel/ptrace.c:66:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arm/kernel/ptrace.c-67-
--
arch/arm/mach-exynos/firmware.c=216=void __init exynos_firmware_init(void)
--
arch/arm/mach-exynos/firmware.c-237-
arch/arm/mach-exynos/firmware.c:238:#define REG_CPU_STATE_ADDR	(sysram_ns_base_addr + 0x28)
arch/arm/mach-exynos/firmware.c-239-#define BOOT_MODE_MASK		0x1f
--
arch/arm/mach-exynos/suspend.c-35-
arch/arm/mach-exynos/suspend.c:36:#define REG_TABLE_END (-1U)
arch/arm/mach-exynos/suspend.c-37-
--
arch/arm/mach-hisi/platsmp.c=129=static const struct smp_operations hix5hd2_smp_ops __initconst = {
--
arch/arm/mach-hisi/platsmp.c-139-#define HIP01_BOOT_ADDRESS     0x80000000
arch/arm/mach-hisi/platsmp.c:140:#define REG_SC_CTRL            0x000
arch/arm/mach-hisi/platsmp.c-141-
--
arch/arm/mach-imx/anatop.c-15-
arch/arm/mach-imx/anatop.c:16:#define REG_SET		0x4
arch/arm/mach-imx/anatop.c:17:#define REG_CLR		0x8
arch/arm/mach-imx/anatop.c-18-
--
arch/arm/mach-omap2/omap_twl.c=40=static u8 smps_offset;
arch/arm/mach-omap2/omap_twl.c-41-
arch/arm/mach-omap2/omap_twl.c:42:#define REG_SMPS_OFFSET         0xE0
arch/arm/mach-omap2/omap_twl.c-43-
--
arch/arm/nwfpe/fpmodule.h-14-
arch/arm/nwfpe/fpmodule.h:15:#define REG_ORIG_R0	17
arch/arm/nwfpe/fpmodule.h:16:#define REG_CPSR	16
arch/arm/nwfpe/fpmodule.h:17:#define REG_PC		15
arch/arm/nwfpe/fpmodule.h:18:#define REG_LR		14
arch/arm/nwfpe/fpmodule.h:19:#define REG_SP		13
arch/arm/nwfpe/fpmodule.h:20:#define REG_IP		12
arch/arm/nwfpe/fpmodule.h:21:#define REG_FP		11
arch/arm/nwfpe/fpmodule.h:22:#define REG_R10		10
arch/arm/nwfpe/fpmodule.h:23:#define REG_R9		9
arch/arm/nwfpe/fpmodule.h:24:#define REG_R9		9
arch/arm/nwfpe/fpmodule.h:25:#define REG_R8		8
arch/arm/nwfpe/fpmodule.h:26:#define REG_R7		7
arch/arm/nwfpe/fpmodule.h:27:#define REG_R6		6
arch/arm/nwfpe/fpmodule.h:28:#define REG_R5		5
arch/arm/nwfpe/fpmodule.h:29:#define REG_R4		4
arch/arm/nwfpe/fpmodule.h:30:#define REG_R3		3
arch/arm/nwfpe/fpmodule.h:31:#define REG_R2		2
arch/arm/nwfpe/fpmodule.h:32:#define REG_R1		1
arch/arm/nwfpe/fpmodule.h:33:#define REG_R0		0
arch/arm/nwfpe/fpmodule.h-34-
--
arch/arm64/kernel/perf_regs.c=30=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/arm64/kernel/perf_regs.c-77-
arch/arm64/kernel/perf_regs.c:78:#define REG_RESERVED (~((1ULL << PERF_REG_ARM64_MAX) - 1))
arch/arm64/kernel/perf_regs.c-79-
--
arch/arm64/kernel/ptrace.c=48=struct pt_regs_offset {
--
arch/arm64/kernel/ptrace.c-52-
arch/arm64/kernel/ptrace.c:53:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/arm64/kernel/ptrace.c:54:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/arm64/kernel/ptrace.c-55-#define GPR_OFFSET_NAME(r) \
--
arch/arm64/kvm/sys_regs.h=62=struct sys_reg_desc {
--
arch/arm64/kvm/sys_regs.h-106-
arch/arm64/kvm/sys_regs.h:107:#define REG_HIDDEN		(1 << 0) /* hidden from userspace and guest */
arch/arm64/kvm/sys_regs.h:108:#define REG_RAZ			(1 << 1) /* RAZ from userspace and guest */
arch/arm64/kvm/sys_regs.h:109:#define REG_USER_WI		(1 << 2) /* WI from userspace only */
arch/arm64/kvm/sys_regs.h-110-
--
arch/csky/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/csky/kernel/perf_regs.c-18-
arch/csky/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_CSKY_MAX) - 1))
arch/csky/kernel/perf_regs.c-20-
--
arch/csky/kernel/ptrace.c=198=struct pt_regs_offset {
--
arch/csky/kernel/ptrace.c-202-
arch/csky/kernel/ptrace.c:203:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/csky/kernel/ptrace.c:204:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/csky/kernel/ptrace.c-205-
--
arch/loongarch/include/asm/asm.h-54-#if (SZREG == 4)
arch/loongarch/include/asm/asm.h:55:#define REG_L		ld.w
arch/loongarch/include/asm/asm.h:56:#define REG_S		st.w
arch/loongarch/include/asm/asm.h:57:#define REG_ADD		add.w
arch/loongarch/include/asm/asm.h:58:#define REG_SUB		sub.w
arch/loongarch/include/asm/asm.h-59-#else /* SZREG == 8 */
arch/loongarch/include/asm/asm.h:60:#define REG_L		ld.d
arch/loongarch/include/asm/asm.h:61:#define REG_S		st.d
arch/loongarch/include/asm/asm.h:62:#define REG_ADD		add.d
arch/loongarch/include/asm/asm.h:63:#define REG_SUB		sub.d
arch/loongarch/include/asm/asm.h-64-#endif
--
arch/loongarch/include/asm/loongarch.h-22-/* LoongArch Registers */
arch/loongarch/include/asm/loongarch.h:23:#define REG_ZERO	0x0
arch/loongarch/include/asm/loongarch.h:24:#define REG_RA		0x1
arch/loongarch/include/asm/loongarch.h:25:#define REG_TP		0x2
arch/loongarch/include/asm/loongarch.h:26:#define REG_SP		0x3
arch/loongarch/include/asm/loongarch.h:27:#define REG_A0		0x4 /* Reused as V0 for return value */
arch/loongarch/include/asm/loongarch.h:28:#define REG_A1		0x5 /* Reused as V1 for return value */
arch/loongarch/include/asm/loongarch.h:29:#define REG_A2		0x6
arch/loongarch/include/asm/loongarch.h:30:#define REG_A3		0x7
arch/loongarch/include/asm/loongarch.h:31:#define REG_A4		0x8
arch/loongarch/include/asm/loongarch.h:32:#define REG_A5		0x9
arch/loongarch/include/asm/loongarch.h:33:#define REG_A6		0xa
arch/loongarch/include/asm/loongarch.h:34:#define REG_A7		0xb
arch/loongarch/include/asm/loongarch.h:35:#define REG_T0		0xc
arch/loongarch/include/asm/loongarch.h:36:#define REG_T1		0xd
arch/loongarch/include/asm/loongarch.h:37:#define REG_T2		0xe
arch/loongarch/include/asm/loongarch.h:38:#define REG_T3		0xf
arch/loongarch/include/asm/loongarch.h:39:#define REG_T4		0x10
arch/loongarch/include/asm/loongarch.h:40:#define REG_T5		0x11
arch/loongarch/include/asm/loongarch.h:41:#define REG_T6		0x12
arch/loongarch/include/asm/loongarch.h:42:#define REG_T7		0x13
arch/loongarch/include/asm/loongarch.h:43:#define REG_T8		0x14
arch/loongarch/include/asm/loongarch.h:44:#define REG_U0		0x15 /* Kernel uses it as percpu base */
arch/loongarch/include/asm/loongarch.h:45:#define REG_FP		0x16
arch/loongarch/include/asm/loongarch.h:46:#define REG_S0		0x17
arch/loongarch/include/asm/loongarch.h:47:#define REG_S1		0x18
arch/loongarch/include/asm/loongarch.h:48:#define REG_S2		0x19
arch/loongarch/include/asm/loongarch.h:49:#define REG_S3		0x1a
arch/loongarch/include/asm/loongarch.h:50:#define REG_S4		0x1b
arch/loongarch/include/asm/loongarch.h:51:#define REG_S5		0x1c
arch/loongarch/include/asm/loongarch.h:52:#define REG_S6		0x1d
arch/loongarch/include/asm/loongarch.h:53:#define REG_S7		0x1e
arch/loongarch/include/asm/loongarch.h:54:#define REG_S8		0x1f
arch/loongarch/include/asm/loongarch.h-55-
--
arch/loongarch/kernel/ptrace.c=782=struct pt_regs_offset {
--
arch/loongarch/kernel/ptrace.c-786-
arch/loongarch/kernel/ptrace.c:787:#define REG_OFFSET_NAME(n, r) {.name = #n, .offset = offsetof(struct pt_regs, r)}
arch/loongarch/kernel/ptrace.c:788:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/loongarch/kernel/ptrace.c-789-
--
arch/loongarch/net/bpf_jit.c-25-
arch/loongarch/net/bpf_jit.c:26:#define REG_TCC		LOONGARCH_GPR_A6
arch/loongarch/net/bpf_jit.c:27:#define REG_ARENA	LOONGARCH_GPR_S6 /* For storing arena_vm_start */
arch/loongarch/net/bpf_jit.c-28-#define BPF_TAIL_CALL_CNT_PTR_STACK_OFF(stack) (round_up(stack, 16) - 80)
--
arch/loongarch/net/bpf_jit.c=629=static bool is_signed_bpf_cond(u8 cond)
--
arch/loongarch/net/bpf_jit.c-636-#define BPF_FIXUP_OFFSET_MASK	GENMASK(26, 0)
arch/loongarch/net/bpf_jit.c:637:#define REG_DONT_CLEAR_MARKER	0
arch/loongarch/net/bpf_jit.c-638-
--
arch/mips/bmips/setup.c-33-
arch/mips/bmips/setup.c:34:#define REG_BCM6328_OTP		((void __iomem *)CKSEG1ADDR(0x1000062c))
arch/mips/bmips/setup.c-35-#define BCM6328_TP1_DISABLED	BIT(9)
--
arch/mips/include/asm/asm.h=95=symbol		=	value
--
arch/mips/include/asm/asm.h-157-#if (_MIPS_SIM == _MIPS_SIM_ABI32)
arch/mips/include/asm/asm.h:158:#define REG_S		sw
arch/mips/include/asm/asm.h:159:#define REG_L		lw
arch/mips/include/asm/asm.h:160:#define REG_SUBU	subu
arch/mips/include/asm/asm.h:161:#define REG_ADDU	addu
arch/mips/include/asm/asm.h-162-#endif
arch/mips/include/asm/asm.h-163-#if (_MIPS_SIM == _MIPS_SIM_NABI32) || (_MIPS_SIM == _MIPS_SIM_ABI64)
arch/mips/include/asm/asm.h:164:#define REG_S		sd
arch/mips/include/asm/asm.h:165:#define REG_L		ld
arch/mips/include/asm/asm.h:166:#define REG_SUBU	dsubu
arch/mips/include/asm/asm.h:167:#define REG_ADDU	daddu
arch/mips/include/asm/asm.h-168-#endif
--
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h-1131-#define BCMPCI_REG_TIMERS		0x40
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1132:#define REG_TIMER_TRDY_SHIFT		0
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1133:#define REG_TIMER_TRDY_MASK		(0xff << REG_TIMER_TRDY_SHIFT)
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1134:#define REG_TIMER_RETRY_SHIFT		8
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h:1135:#define REG_TIMER_RETRY_MASK		(0xff << REG_TIMER_RETRY_SHIFT)
arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h-1136-
--
arch/mips/kernel/ptrace.c=848=struct pt_regs_offset {
--
arch/mips/kernel/ptrace.c-852-
arch/mips/kernel/ptrace.c:853:#define REG_OFFSET_NAME(reg, r) {					\
arch/mips/kernel/ptrace.c-854-	.name = #reg,							\
--
arch/mips/kernel/ptrace.c-857-
arch/mips/kernel/ptrace.c:858:#define REG_OFFSET_END {						\
arch/mips/kernel/ptrace.c-859-	.name = NULL,							\
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h=19=extern sci_handler yeeloong_report_lid_status;
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-52-/* temperature & fan registers */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:53:#define REG_TEMPERATURE_VALUE	0xF458
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:54:#define REG_FAN_AUTO_MAN_SWITCH 0xF459
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-55-#define BIT_FAN_AUTO		0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-56-#define BIT_FAN_MANUAL		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:57:#define REG_FAN_CONTROL		0xF4D2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-58-#define BIT_FAN_CONTROL_ON	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-59-#define BIT_FAN_CONTROL_OFF	(0 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:60:#define REG_FAN_STATUS		0xF4DA
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-61-#define BIT_FAN_STATUS_ON	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-62-#define BIT_FAN_STATUS_OFF	(0 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:63:#define REG_FAN_SPEED_HIGH	0xFE22
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:64:#define REG_FAN_SPEED_LOW	0xFE23
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:65:#define REG_FAN_SPEED_LEVEL	0xF4CC
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-66-/* fan speed divider */
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-69-/* battery registers */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:70:#define REG_BAT_DESIGN_CAP_HIGH		0xF77D
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:71:#define REG_BAT_DESIGN_CAP_LOW		0xF77E
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:72:#define REG_BAT_FULLCHG_CAP_HIGH	0xF780
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:73:#define REG_BAT_FULLCHG_CAP_LOW		0xF781
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:74:#define REG_BAT_DESIGN_VOL_HIGH		0xF782
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:75:#define REG_BAT_DESIGN_VOL_LOW		0xF783
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:76:#define REG_BAT_CURRENT_HIGH		0xF784
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:77:#define REG_BAT_CURRENT_LOW		0xF785
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:78:#define REG_BAT_VOLTAGE_HIGH		0xF786
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:79:#define REG_BAT_VOLTAGE_LOW		0xF787
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:80:#define REG_BAT_TEMPERATURE_HIGH	0xF788
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:81:#define REG_BAT_TEMPERATURE_LOW		0xF789
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:82:#define REG_BAT_RELATIVE_CAP_HIGH	0xF492
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:83:#define REG_BAT_RELATIVE_CAP_LOW	0xF493
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:84:#define REG_BAT_VENDOR			0xF4C4
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-85-#define FLAG_BAT_VENDOR_SANYO		0x01
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-86-#define FLAG_BAT_VENDOR_SIMPLO		0x02
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:87:#define REG_BAT_CELL_COUNT		0xF4C6
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-88-#define FLAG_BAT_CELL_3S1P		0x03
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-89-#define FLAG_BAT_CELL_3S2P		0x06
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:90:#define REG_BAT_CHARGE			0xF4A2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-91-#define FLAG_BAT_CHARGE_DISCHARGE	0x01
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-93-#define FLAG_BAT_CHARGE_ACPOWER		0x00
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:94:#define REG_BAT_STATUS			0xF4B0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-95-#define BIT_BAT_STATUS_LOW		(1 << 5)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-98-#define BIT_BAT_STATUS_IN		(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:99:#define REG_BAT_CHARGE_STATUS		0xF4B1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-100-#define BIT_BAT_CHARGE_STATUS_OVERTEMP	(1 << 2)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-101-#define BIT_BAT_CHARGE_STATUS_PRECHG	(1 << 1)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:102:#define REG_BAT_STATE			0xF482
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-103-#define BIT_BAT_STATE_CHARGING		(1 << 1)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-104-#define BIT_BAT_STATE_DISCHARGING	(1 << 0)
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:105:#define REG_BAT_POWER			0xF440
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-106-#define BIT_BAT_POWER_S3		(1 << 2)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-111-/* Audio: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:112:#define REG_AUDIO_VOLUME	0xF46C
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:113:#define REG_AUDIO_MUTE		0xF4E7
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:114:#define REG_AUDIO_BEEP		0xF4D0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-115-/* USB port power or not: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:116:#define REG_USB0_FLAG		0xF461
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:117:#define REG_USB1_FLAG		0xF462
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:118:#define REG_USB2_FLAG		0xF463
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-119-#define BIT_USB_FLAG_ON		1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-121-/* LID */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:122:#define REG_LID_DETECT		0xF4BD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-123-#define BIT_LID_DETECT_ON	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-125-/* CRT */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:126:#define REG_CRT_DETECT		0xF4AD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-127-#define BIT_CRT_DETECT_PLUG	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-129-/* LCD backlight brightness adjust: 9 levels */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:130:#define REG_DISPLAY_BRIGHTNESS	0xF4F5
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-131-/* Black screen Status */
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-134-/* LCD backlight control: off/restore */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:135:#define REG_BACKLIGHT_CTRL	0xF7BD
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-136-#define BIT_BACKLIGHT_ON	1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-138-/* Reset the machine auto-clear: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:139:#define REG_RESET		0xF4EC
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-140-#define BIT_RESET_ON		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-141-/* Light the led: rd/wr */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:142:#define REG_LED			0xF4C8
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-143-#define BIT_LED_RED_POWER	(1 << 0)
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-148-/* Test led mode, all led on/off */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:149:#define REG_LED_TEST		0xF4C2
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-150-#define BIT_LED_TEST_IN		1
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-152-/* Camera on/off */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:153:#define REG_CAMERA_STATUS	0xF46A
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-154-#define BIT_CAMERA_STATUS_ON	1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-155-#define BIT_CAMERA_STATUS_OFF	0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:156:#define REG_CAMERA_CONTROL	0xF7B7
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-157-#define BIT_CAMERA_CONTROL_OFF	0
--
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-159-/* Wlan Status */
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:160:#define REG_WLAN		0xF4FA
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-161-#define BIT_WLAN_ON		1
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-162-#define BIT_WLAN_OFF		0
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h:163:#define REG_DISPLAY_LCD		0xF79F
arch/mips/loongson2ef/lemote-2f/ec_kb3310b.h-164-
--
arch/mips/loongson2ef/lemote-2f/reset.c=75=static void ml2f_reboot(void)
--
arch/mips/loongson2ef/lemote-2f/reset.c-88-#define EC_SHUTDOWN_IO_PORT_DATA 0xff2f
arch/mips/loongson2ef/lemote-2f/reset.c:89:#define REG_SHUTDOWN_HIGH	 0xFC
arch/mips/loongson2ef/lemote-2f/reset.c:90:#define REG_SHUTDOWN_LOW	 0x29
arch/mips/loongson2ef/lemote-2f/reset.c-91-#define BIT_SHUTDOWN_ON		 (1 << 1)
--
arch/mips/n64/init.c=46=void __init prom_init(void)
--
arch/mips/n64/init.c-52-#define H 240
arch/mips/n64/init.c:53:#define REG_BASE ((u32 __iomem *) CKSEG1ADDR(0x4400000))
arch/mips/n64/init.c-54-
--
arch/mips/ralink/ill_acc.c-14-
arch/mips/ralink/ill_acc.c:15:#define REG_ILL_ACC_ADDR	0x10
arch/mips/ralink/ill_acc.c:16:#define REG_ILL_ACC_TYPE	0x14
arch/mips/ralink/ill_acc.c-17-
--
arch/nios2/kernel/ptrace.c=46=static int genregs_set(struct task_struct *target,
--
arch/nios2/kernel/ptrace.c-54-
arch/nios2/kernel/ptrace.c:55:#define REG_IGNORE_RANGE(START, END)		\
arch/nios2/kernel/ptrace.c-56-	if (!ret)					\
--
arch/nios2/kernel/ptrace.c-59-
arch/nios2/kernel/ptrace.c:60:#define REG_IN_ONE(PTR, LOC)	\
arch/nios2/kernel/ptrace.c-61-	if (!ret)			\
--
arch/nios2/kernel/ptrace.c-64-
arch/nios2/kernel/ptrace.c:65:#define REG_IN_RANGE(PTR, START, END)	\
arch/nios2/kernel/ptrace.c-66-	if (!ret)				\
--
arch/openrisc/kernel/ptrace.c=163=struct pt_regs_offset {
--
arch/openrisc/kernel/ptrace.c-167-
arch/openrisc/kernel/ptrace.c:168:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/openrisc/kernel/ptrace.c:169:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/openrisc/kernel/ptrace.c-170-
--
arch/parisc/include/asm/assembly.h-15-#define CALLEE_REG_FRAME_SIZE	144
arch/parisc/include/asm/assembly.h:16:#define REG_SZ		8
arch/parisc/include/asm/assembly.h-17-#define ASM_ULONG_INSN	.dword
--
arch/parisc/include/asm/assembly.h-21-#define CALLEE_REG_FRAME_SIZE	128
arch/parisc/include/asm/assembly.h:22:#define REG_SZ		4
arch/parisc/include/asm/assembly.h-23-#define ASM_ULONG_INSN	.word
--
arch/parisc/kernel/perf_regs.c=9=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/parisc/kernel/perf_regs.c-34-
arch/parisc/kernel/perf_regs.c:35:#define REG_RESERVED (~((1ULL << PERF_REG_PARISC_MAX) - 1))
arch/parisc/kernel/perf_regs.c-36-
--
arch/parisc/kernel/ptrace.c=663=struct pt_regs_offset {
--
arch/parisc/kernel/ptrace.c-667-
arch/parisc/kernel/ptrace.c:668:#define REG_OFFSET_NAME(r)    {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/parisc/kernel/ptrace.c:669:#define REG_OFFSET_INDEX(r,i) {.name = #r#i, .offset = offsetof(struct pt_regs, r[i])}
arch/parisc/kernel/ptrace.c:670:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/parisc/kernel/ptrace.c-671-
--
arch/parisc/net/bpf_jit.h=65=struct hppa_jit_context {
--
arch/parisc/net/bpf_jit.h-76-
arch/parisc/net/bpf_jit.h:77:#define REG_SET_SEEN(ctx, nr)	{ if (ctx->reg_seen_collect) ctx->reg_seen |= BIT(nr); }
arch/parisc/net/bpf_jit.h:78:#define REG_SET_SEEN_ALL(ctx)	{ if (ctx->reg_seen_collect) ctx->reg_seen = -1; }
arch/parisc/net/bpf_jit.h:79:#define REG_FORCE_SEEN(ctx, nr)	{ ctx->reg_seen |= BIT(nr); }
arch/parisc/net/bpf_jit.h:80:#define REG_WAS_SEEN(ctx, nr)	(ctx->reg_seen & BIT(nr))
arch/parisc/net/bpf_jit.h:81:#define REG_ALL_SEEN(ctx)	(ctx->reg_seen == -1)
arch/parisc/net/bpf_jit.h-82-
arch/parisc/net/bpf_jit.h-83-#define HPPA_INSN_SIZE		4	/* bytes per HPPA asm instruction */
arch/parisc/net/bpf_jit.h:84:#define REG_SIZE		REG_SZ	/* bytes per native "long" word */
arch/parisc/net/bpf_jit.h-85-
--
arch/powerpc/kernel/ptrace/ptrace-view.c=10=struct pt_regs_offset {
--
arch/powerpc/kernel/ptrace/ptrace-view.c-15-#define STR(s)	#s			/* convert to string */
arch/powerpc/kernel/ptrace/ptrace-view.c:16:#define REG_OFFSET_NAME(r) {.name = #r, .offset = offsetof(struct pt_regs, r)}
arch/powerpc/kernel/ptrace/ptrace-view.c-17-#define GPR_OFFSET_NAME(num)	\
--
arch/powerpc/kernel/ptrace/ptrace-view.c-19-	{.name = STR(gpr##num), .offset = offsetof(struct pt_regs, gpr[num])}
arch/powerpc/kernel/ptrace/ptrace-view.c:20:#define REG_OFFSET_END {.name = NULL, .offset = 0}
arch/powerpc/kernel/ptrace/ptrace-view.c-21-
--
arch/powerpc/perf/perf_regs.c=16=u64 PERF_REG_EXTENDED_MASK;
--
arch/powerpc/perf/perf_regs.c-19-
arch/powerpc/perf/perf_regs.c:20:#define REG_RESERVED (~(PERF_REG_EXTENDED_MASK | PERF_REG_PMU_MASK))
arch/powerpc/perf/perf_regs.c-21-
--
arch/riscv/include/asm/asm.h-28-
arch/riscv/include/asm/asm.h:29:#define REG_L		__REG_SEL(ld, lw)
arch/riscv/include/asm/asm.h:30:#define REG_S		__REG_SEL(sd, sw)
arch/riscv/include/asm/asm.h:31:#define REG_SC		__REG_SEL(sc.d, sc.w)
arch/riscv/include/asm/asm.h:32:#define REG_AMOSWAP_AQ	__REG_SEL(amoswap.d.aq, amoswap.w.aq)
arch/riscv/include/asm/asm.h:33:#define REG_ASM		__REG_SEL(.dword, .word)
arch/riscv/include/asm/asm.h-34-#define SZREG		__REG_SEL(8, 4)
--
arch/riscv/include/asm/insn.h=284=static __always_inline bool riscv_insn_is_c_jalr(u32 code)
--
arch/riscv/include/asm/insn.h-396-
arch/riscv/include/asm/insn.h:397:#define REG_MASK			\
arch/riscv/include/asm/insn.h-398-	((1 << (5 + LOG_REGBYTES)) - (1 << LOG_REGBYTES))
arch/riscv/include/asm/insn.h-399-
arch/riscv/include/asm/insn.h:400:#define REG_OFFSET(insn, pos)		\
arch/riscv/include/asm/insn.h-401-	(SHIFT_RIGHT((insn), (pos) - LOG_REGBYTES) & REG_MASK)
arch/riscv/include/asm/insn.h-402-
arch/riscv/include/asm/insn.h:403:#define REG_PTR(insn, pos, regs)	\
arch/riscv/include/asm/insn.h-404-	((ulong *)((ulong)(regs) + REG_OFFSET(insn, pos)))
--
arch/riscv/include/asm/module.h=48=struct plt_entry {
--
arch/riscv/include/asm/module.h-60-#define OPC_JALR   0x0067
arch/riscv/include/asm/module.h:61:#define REG_T0     0x5
arch/riscv/include/asm/module.h:62:#define REG_T1     0x6
arch/riscv/include/asm/module.h-63-
--
arch/riscv/include/asm/ptrace.h=15=struct pt_regs {
--
arch/riscv/include/asm/ptrace.h-61-#ifdef CONFIG_64BIT
arch/riscv/include/asm/ptrace.h:62:#define REG_FMT "%016lx"
arch/riscv/include/asm/ptrace.h-63-#else
arch/riscv/include/asm/ptrace.h:64:#define REG_FMT "%08lx"
arch/riscv/include/asm/ptrace.h-65-#endif
--
arch/riscv/kernel/perf_regs.c=11=u64 perf_reg_value(struct pt_regs *regs, int idx)
--
arch/riscv/kernel/perf_regs.c-18-
arch/riscv/kernel/perf_regs.c:19:#define REG_RESERVED (~((1ULL << PERF_REG_RISCV_MAX) - 1))

]

239/4 2026/08/10 08:46 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 44506
							output: 39
							thoughts: 16
						

Thoughts:
**My Thought Process for Approaching This Problem**

Ah, an immediate realization strikes me: instead of delving into layers of abstraction or documentation, I can go straight to the source. My first instinct is to directly examine the `nhi_regs.h` file. This implies that I have prior knowledge of this file's existence and its relevance to the problem at hand, and I recognize that it likely contains the definitive information I need. I'm not going to waste time with indirect methods; the most efficient path is to interrogate the header file itself.


240/4 2026/08/10 08:46 tool codesearch-definition-source
0m Error:
log-in to see details

Args:
map[ContextFile:drivers/thunderbolt/nhi_regs.h Name:REG_CAPS]

Results:
map[SourceCode: SourceFile:]

241/4 2026/08/10 08:46 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 44566
							output: 38
							thoughts: 17
						

Thoughts:
**A Deep Dive into the NHI Thunderbolt Register Definitions**

My objective here is to thoroughly understand the intricacies of the Thunderbolt controller's hardware interface as exposed through its register definitions. To achieve this, I'm beginning by meticulously examining the `drivers/thunderbolt/nhi_regs.h` file. This header file is crucial because it contains the symbolic names and bit definitions for all the registers that the Thunderbolt host controller uses to communicate with the system. By understanding these definitions, I can then begin to interpret the low-level behavior of the Thunderbolt controller and how it interacts with the rest of the system hardware. My goal is to build a foundational knowledge of these registers, which will enable me to eventually write or debug the driver code that manipulates them. This is a critical first step in understanding the driver's interaction with the hardware at its most fundamental level.


242/4 2026/08/10 08:47 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:1 LineCount:100]

Results:
map[Contents:   1:	/* SPDX-License-Identifier: GPL-2.0 */
   2:	/*
   3:	 * Thunderbolt driver - NHI registers
   4:	 *
   5:	 * Copyright (c) 2014 Andreas Noever <andreas.noever@gmail.com>
   6:	 * Copyright (C) 2018, Intel Corporation
   7:	 */
   8:	
   9:	#ifndef NHI_REGS_H_
  10:	#define NHI_REGS_H_
  11:	
  12:	#include <linux/types.h>
  13:	
  14:	enum ring_flags {
  15:		RING_FLAG_ISOCH_ENABLE = 1 << 27, /* TX only? */
  16:		RING_FLAG_E2E_FLOW_CONTROL = 1 << 28,
  17:		RING_FLAG_PCI_NO_SNOOP = 1 << 29,
  18:		RING_FLAG_RAW = 1 << 30, /* ignore EOF/SOF mask, include checksum */
  19:		RING_FLAG_ENABLE = 1 << 31,
  20:	};
  21:	
  22:	/**
  23:	 * struct ring_desc - TX/RX ring entry
  24:	 * @phys: DMA mapped address of the frame
  25:	 * @length: Size of the ring
  26:	 * @eof: End of frame protocol defined field
  27:	 * @sof: Start of frame protocol defined field
  28:	 * @flags: Ring descriptor flags
  29:	 * @time: Fill with zero
  30:	 *
  31:	 * For TX set length/eof/sof.
  32:	 * For RX length/eof/sof are set by the NHI.
  33:	 */
  34:	struct ring_desc {
  35:		u64 phys;
  36:		u32 length:12;
  37:		u32 eof:4;
  38:		u32 sof:4;
  39:		enum ring_desc_flags flags:12;
  40:		u32 time; /* write zero */
  41:	} __packed;
  42:	
  43:	/* NHI registers in bar 0 */
  44:	
  45:	/*
  46:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  47:	 * 00: physical pointer to an array of struct ring_desc
  48:	 * 08: ring tail (set by NHI)
  49:	 * 10: ring head (index of first non posted descriptor)
  50:	 * 12: descriptor count
  51:	 */
  52:	#define REG_TX_RING_BASE	0x00000
  53:	
  54:	/*
  55:	 * 16 bytes per entry, one entry for every hop (REG_CAPS)
  56:	 * 00: physical pointer to an array of struct ring_desc
  57:	 * 08: ring head (index of first not posted descriptor)
  58:	 * 10: ring tail (set by NHI)
  59:	 * 12: descriptor count
  60:	 * 14: max frame sizes (anything larger than 0x100 has no effect)
  61:	 */
  62:	#define REG_RX_RING_BASE	0x08000
  63:	
  64:	/*
  65:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  66:	 * 00: enum_ring_flags
  67:	 * 04: isoch time stamp ?? (write 0)
  68:	 * ..: unknown
  69:	 */
  70:	#define REG_TX_OPTIONS_BASE	0x19800
  71:	
  72:	/*
  73:	 * 32 bytes per entry, one entry for every hop (REG_CAPS)
  74:	 * 00: enum ring_flags
  75:	 *     If RING_FLAG_E2E_FLOW_CONTROL is set then bits 13-23 must be set to
  76:	 *     the corresponding TX hop id.
  77:	 * 04: EOF/SOF mask (ignored for RING_FLAG_RAW rings)
  78:	 * ..: unknown
  79:	 */
  80:	#define REG_RX_OPTIONS_BASE	0x29800
  81:	#define REG_RX_OPTIONS_E2E_HOP_MASK	GENMASK(22, 12)
  82:	#define REG_RX_OPTIONS_E2E_HOP_SHIFT	12
  83:	
  84:	/*
  85:	 * three bitfields: tx, rx, rx overflow
  86:	 * Every bitfield contains one bit for every hop (REG_CAPS).
  87:	 * New interrupts are fired only after ALL registers have been
  88:	 * read (even those containing only disabled rings).
  89:	 */
  90:	#define REG_RING_NOTIFY_BASE	0x37800
  91:	#define RING_NOTIFY_REG_COUNT(nhi) ((31 + 3 * nhi->hop_count) / 32)
  92:	#define REG_RING_INT_CLEAR	0x37808
  93:	
  94:	/*
  95:	 * two bitfields: rx, tx
  96:	 * Both bitfields contains one bit for every hop (REG_CAPS). To
  97:	 * enable/disable interrupts set/clear the corresponding bits.
  98:	 */
  99:	#define REG_RING_INTERRUPT_BASE	0x38200
 100:	#define RING_INTERRUPT_REG_COUNT(nhi) ((31 + 2 * nhi->hop_count) / 32)
]

243/4 2026/08/10 08:47 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 46182
							output: 40
							thoughts: 10
						

Thoughts:
**My Thought Process on Reading This File**

Alright, my immediate internal directive is straightforward: I need to thoroughly process the remainder of this document. This isn't a passive scan; it's a deep dive. As an expert in my domain, I'm not just looking for facts or data points, though those are crucial. I'm actively seeking the underlying logic, the inferential leaps, the unspoken assumptions, and the broader implications of the information presented. I'll be paying close attention to the structure of the arguments, the evidence provided to support claims, and the potential biases or limitations inherent in the source material. My goal is to achieve a comprehensive understanding, not just of *what* is being said, but *how* it's being said and *why* it matters within the context of my expertise. I'm prepared to engage critically with the content, to identify areas where further investigation might be warranted, and to begin formulating my own informed opinions and potential contributions based on this new influx of knowledge. Essentially, I'm gearing up for a detailed intellectual engagement, ready to absorb, analyze, and integrate this information into my existing framework of understanding.


244/4 2026/08/10 08:47 tool read-file
0m Args:
map[File:drivers/thunderbolt/nhi_regs.h FirstLine:101 LineCount:100]

Results:
map[Contents: 101:	
 102:	#define REG_RING_INTERRUPT_MASK_CLEAR_BASE	0x38208
 103:	
 104:	#define REG_INT_THROTTLING_RATE			0x38c00
 105:	#define REG_INT_THROTTLING_RATE_INTERVAL_MASK	GENMASK(15, 0)
 106:	
 107:	/* Interrupt Vector Allocation */
 108:	#define REG_INT_VEC_ALLOC_BASE	0x38c40
 109:	#define REG_INT_VEC_ALLOC_BITS	4
 110:	#define REG_INT_VEC_ALLOC_MASK	GENMASK(3, 0)
 111:	#define REG_INT_VEC_ALLOC_REGS	(32 / REG_INT_VEC_ALLOC_BITS)
 112:	
 113:	/* The last 11 bits contain the number of hops supported by the NHI port. */
 114:	#define REG_CAPS			0x39640
 115:	#define REG_CAPS_VERSION_MASK		GENMASK(23, 16)
 116:	#define REG_CAPS_VERSION_2		0x40
 117:	
 118:	#define REG_DMA_MISC			0x39864
 119:	#define REG_DMA_MISC_INT_AUTO_CLEAR     BIT(2)
 120:	#define REG_DMA_MISC_DISABLE_AUTO_CLEAR	BIT(17)
 121:	
 122:	#define REG_RESET			0x39898
 123:	#define REG_RESET_HRR			BIT(0)
 124:	
 125:	#define REG_INMAIL_DATA			0x39900
 126:	
 127:	#define REG_INMAIL_CMD			0x39904
 128:	#define REG_INMAIL_CMD_MASK		GENMASK(7, 0)
 129:	#define REG_INMAIL_ERROR		BIT(30)
 130:	#define REG_INMAIL_OP_REQUEST		BIT(31)
 131:	
 132:	#define REG_OUTMAIL_CMD			0x3990c
 133:	#define REG_OUTMAIL_CMD_OPMODE_SHIFT	8
 134:	#define REG_OUTMAIL_CMD_OPMODE_MASK	GENMASK(11, 8)
 135:	
 136:	#define REG_FW_STS			0x39944
 137:	#define REG_FW_STS_NVM_AUTH_DONE	BIT(31)
 138:	#define REG_FW_STS_CIO_RESET_REQ	BIT(30)
 139:	#define REG_FW_STS_ICM_EN_CPU		BIT(2)
 140:	#define REG_FW_STS_ICM_EN_INVERT	BIT(1)
 141:	#define REG_FW_STS_ICM_EN		BIT(0)
 142:	
 143:	/* ICL NHI VSEC registers */
 144:	
 145:	/* FW ready */
 146:	#define VS_CAP_9			0xc8
 147:	#define VS_CAP_9_FW_READY		BIT(31)
 148:	/* UUID */
 149:	#define VS_CAP_10			0xcc
 150:	#define VS_CAP_11			0xd0
 151:	/* LTR */
 152:	#define VS_CAP_15			0xe0
 153:	#define VS_CAP_16			0xe4
 154:	/* TBT2PCIe */
 155:	#define VS_CAP_18			0xec
 156:	#define VS_CAP_18_DONE			BIT(0)
 157:	/* PCIe2TBT */
 158:	#define VS_CAP_19			0xf0
 159:	#define VS_CAP_19_VALID			BIT(0)
 160:	#define VS_CAP_19_CMD_SHIFT		1
 161:	#define VS_CAP_19_CMD_MASK		GENMASK(7, 1)
 162:	/* Force power */
 163:	#define VS_CAP_22			0xfc
 164:	#define VS_CAP_22_FORCE_POWER		BIT(1)
 165:	#define VS_CAP_22_DMA_DELAY_MASK	GENMASK(31, 24)
 166:	#define VS_CAP_22_DMA_DELAY_SHIFT	24
 167:	
 168:	/**
 169:	 * enum icl_lc_mailbox_cmd - ICL specific LC mailbox commands
 170:	 * @ICL_LC_GO2SX: Ask LC to enter Sx without wake
 171:	 * @ICL_LC_GO2SX_NO_WAKE: Ask LC to enter Sx with wake
 172:	 * @ICL_LC_PREPARE_FOR_RESET: Prepare LC for reset
 173:	 */
 174:	enum icl_lc_mailbox_cmd {
 175:		ICL_LC_GO2SX = 0x02,
 176:		ICL_LC_GO2SX_NO_WAKE = 0x03,
 177:		ICL_LC_PREPARE_FOR_RESET = 0x21,
 178:	};
 179:	
 180:	#endif
]

245/4 2026/08/10 08:47 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 47762
							output: 40
							thoughts: 885
						

Thoughts:
**My Thoughts on the PCI BAR Size Vulnerability**

Okay, so looking at this, the most significant observation is that the highest register offset we're dealing with here is `0x39944`, specifically for `REG_FW_STS`. This immediately flags a potential issue: if the PCI Base Address Register (BAR) size is less than `0x39944 + 4` (accounting for the size of the access), then any attempt to touch these registers will be an out-of-bounds MMIO access.

My primary concern here is that the driver, as it stands, *isn't checking the BAR size at all*. This is a critical oversight. What happens if the BAR size is 0 or just very small? Well, `pcim_iomap_region` will map a correspondingly small region. Then, when `ioread32` or `iowrite32` tries to access an offset like `0x39944`, it's going to be operating on unmapped memory. That's a recipe for a page fault, and we've seen it happen.

It's interesting to note the page fault offsets. In the original crash, it was at `0x38208`. In the reproduced crash, it shifted to `0x39640`. This difference, while seemingly significant, doesn't change the underlying problem. Both are out-of-bounds MMIO accesses, and the root cause is identical: the lack of proper BAR size validation.

Now, I wanted to be absolutely sure about what `pcim_iomap_region` does when the BAR size is 0. If `pci_resource_len` returns 0 for the BAR, then `pci_iomap_range` has this crucial check: `if (len <= offset || !start) return NULL;`. If this condition is met, `pcim_iomap_region` should return an error, specifically `-EINVAL` (or `IOMEM_ERR_PTR(-EINVAL)`).

However, my analysis of the code snippet where `nhi->iobase` is populated shows that `PTR_ERR_OR_ZERO(nhi->iobase)` is used. This means `nhi->iobase` *cannot* be an error pointer if the code proceeds. It *must* be a valid pointer. This strongly implies that `pcim_iomap_region` *succeeded*. For it to succeed, `pci_resource_len(pdev, 0)` must have returned a value greater than 0, and `start` must have been non-zero. So, the BAR size was *not* 0.

But, this doesn't mean we're safe. The BAR size could still be very small, say 4KB (`0x1000`). If that's the case, `pcim_iomap_region` maps those 4KB, and `nhi->iobase` points to a valid 4KB region. Then, an operation like `ioread32(nhi->iobase + 0x39640)` attempts to access an offset that is vastly beyond the allocated 4KB. Again, this results in a page fault because it's trying to access unmapped memory.

The variation in the crash offset (`0x38208` vs. `0x39640`) is likely due to how the kernel's virtual memory (vmalloc) is laid out at the time of the crash. It's common for out-of-bounds accesses to vmalloc'd regions to hit different "guard pages" or unmapped areas depending on the specific vmalloc layout. So, while the *offset* differs, the underlying mechanism of hitting unmapped memory due to an insufficient BAR size is the same.

Therefore, the fundamental issue remains: the absence of a check to ensure `pci_resource_len(pdev, 0)` is sufficiently large. Realistically, the driver should be verifying that the BAR length is at least `0x39c00` to cover the entire NHI register space. I'll be looking to see if there's a patch in the current tree that addresses this specific bug report, which is described as an "unable to handle kernel paging request in iowrite32" within the `thunderbolt` module. The fix, in my view, would involve adding that crucial check for `pci_resource_len(pdev, 0)` within the `nhi_pci_probe` function.


246/4 2026/08/10 08:47 tool codesearch-definition-source
0m Args:
map[ContextFile:drivers/thunderbolt/pci.c Name:nhi_pci_probe]

Results:
map[SourceCode: 447:	static int nhi_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 448:	{
 449:		struct device *dev = &pdev->dev;
 450:		struct tb_nhi_pci *nhi_pci;
 451:		struct tb_nhi *nhi;
 452:		int res;
 453:	
 454:		if (!nhi_pci_imr_valid(pdev))
 455:			return dev_err_probe(dev, -ENODEV, "firmware image not valid, aborting\n");
 456:	
 457:		res = pcim_enable_device(pdev);
 458:		if (res)
 459:			return dev_err_probe(dev, res, "cannot enable PCI device, aborting\n");
 460:	
 461:		nhi_pci = devm_kzalloc(dev, sizeof(*nhi_pci), GFP_KERNEL);
 462:		if (!nhi_pci)
 463:			return -ENOMEM;
 464:	
 465:		nhi = &nhi_pci->nhi;
 466:		nhi->dev = dev;
 467:		nhi->ops = (const struct tb_nhi_ops *)id->driver_data ?: &pci_nhi_default_ops;
 468:	
 469:		nhi->iobase = pcim_iomap_region(pdev, 0, "thunderbolt");
 470:		res = PTR_ERR_OR_ZERO(nhi->iobase);
 471:		if (res)
 472:			return dev_err_probe(dev, res, "cannot obtain PCI resources, aborting\n");
 473:	
 474:		nhi_pci_check_quirks(nhi_pci);
 475:		nhi_pci_check_iommu(nhi_pci);
 476:	
 477:		pci_set_master(pdev);
 478:	
 479:		return nhi_probe(&nhi_pci->nhi);
 480:	}
 SourceFile:drivers/thunderbolt/pci.c]

247/4 2026/08/10 08:47 llm repro-oracle
0m Model:
gemini-3.1-pro-preview

Tokens:
							input: 49304
							output: 477
							thoughts: 936
						

Thoughts:
**My Analysis of the Reproducer Results and the Thunderbolt Driver Bug**

It seems I was initially looking at the wrong tree, or perhaps the fix hadn't landed there yet, because I didn't see the expected checks. However, I've been analyzing the results from the reproducer I've been working with, and it has indeed successfully triggered a crash. This is significant because it confirms the bug is still present.

Let's break down what I'm seeing. The original crash I was investigating was:

`BUG: unable to handle kernel paging request in iowrite32`
`RIP: 0010:iowrite32+0x1e/0x80 lib/iomap.c:225`
`Call Trace: nhi_mask_interrupt ... nhi_disable_interrupts ... nhi_probe`

This pointed to a problem within the `iowrite32` function, occurring during the interrupt handling or disabling routines called from `nhi_probe`.

Now, the reproduced crash shows this:

`BUG: unable to handle page fault for address: ffffc90003c99640`
`RIP: 0010:ioread32+0x1c/0x80`
`Call Trace: nhi_probe ... nhi_pci_probe`

Both of these events are fundamentally page faults occurring during Memory-Mapped I/O (MMIO) accesses. In the original case, it was an `iowrite32`, and in the reproduced case, it's an `ioread32`. Crucially, both are happening within the `nhi_probe` function (or its callers) and stem from an out-of-bounds access to `nhi->iobase`.

The root cause, from my perspective, is identical in both scenarios: the PCI BAR (Base Address Register) for the device is simply too small. The driver, specifically in `nhi_pci_probe`, maps this BAR 0 using `pcim_iomap_region` without adequately verifying if its reported size is sufficient for all the registers the driver intends to access. If a device, or a virtualized one, presents a small BAR (like a mere 4KB), `pcim_iomap_region` will happily map just that small segment. Then, when the driver attempts to read from or write to registers at larger offsets, such as `0x39640` or `0x38208` (which correspond to `REG_CAPS` and `REG_RING_INTERRUPT_MASK_CLEAR_BASE` respectively), these accesses fall outside the actually mapped memory region. This inevitably leads to a page fault.

The difference in the exact crashing instruction (`ioread32` vs. `iowrite32`) and the specific offset (`0x39640` vs. `0x38208`) is, in my expert opinion, a classic manifestation of the randomness introduced by the `vmalloc` layout at the moment of the crash. In the original scenario, the first out-of-bounds access, an `ioread32` at offset `0x39640`, happened to land within another *valid* `vmalloc` allocation. This meant it didn't immediately fault, but rather read garbage data. The execution continued until a subsequent `iowrite32` at `0x38208` occurred, which *did* land in an unmapped guard page, triggering the fault. In the reproduced crash, the `vmalloc` layout was different. The very first out-of-bounds access, the `ioread32` at `0x39640`, encountered an unmapped page immediately and thus faulted straight away.

This is a perfect match, confirming that the underlying bug is precisely the same. The reproducer has validated the original issue.

Therefore, I will proceed to set `TitleMatches` to `true` and will provide a detailed explanation of this analysis in the feedback. I'm now confident in documenting this as a direct reproduction of the identified bug.


248/4 2026/08/10 08:47 tool set-results
0m Args:
map[Feedback:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. ProbePassed:false TerminalError: TitleMatches:true]

Results:
map[Feedback:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. ProbePassed:false TerminalError: TitleMatches:true]

249/3 2026/08/10 08:47 action loop-controller
0m Results:
map[CapabilitiesVerified:true ContinueSignal: EquivalenceAnalysis:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. OracleFeedback:The reproducer successfully triggered the underlying bug.

The original crash was a page fault in `iowrite32` called from `nhi_disable_interrupts` (via `nhi_mask_interrupt`), which accesses `nhi->iobase + 0x38208` (`REG_RING_INTERRUPT_MASK_CLEAR_BASE`).
The reproduced crash is a page fault in `ioread32` called directly from `nhi_probe`, which accesses `nhi->iobase + 0x39640` (`REG_CAPS`).

Both crashes are caused by the exact same root cause: the Thunderbolt driver (`nhi_pci_probe`) maps PCI BAR 0 using `pcim_iomap_region` without validating that the BAR length is large enough to cover the registers it accesses. If a malicious or virtual PCI device (like `syz_pci`) provides a very small BAR 0 (e.g., 4KB), `pcim_iomap_region` succeeds and maps only that small region. Subsequent accesses to registers at large offsets (like `0x39640` or `0x38208`) fall outside the mapped vmalloc region, leading to a page fault.

The difference in the exact crashing instruction and offset is a classic artifact of vmalloc layout randomness. In the original crash, the first out-of-bounds read at `0x39640` (`REG_CAPS`) coincidentally landed inside another valid vmalloc allocation, avoiding a page fault and reading garbage data. The execution then proceeded to `nhi_disable_interrupts`, where the out-of-bounds write at `0x38208` landed in an unmapped guard page, triggering the fault. In the reproduced crash, the vmalloc layout was different, and the very first out-of-bounds read at `0x39640` hit an unmapped page and faulted immediately.

The reproduced crash represents the exact same missing BAR size validation bug as the original crash. ReproC:#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <dirent.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <errno.h>

void write_file(const char *path, const char *data) {
    int fd = open(path, O_WRONLY);
    if (fd >= 0) {
        if (write(fd, data, strlen(data)) < 0) {
            printf("[-] Failed to write to %s: %s\n", path, strerror(errno));
        } else {
            printf("[+] Successfully wrote '%s' to %s\n", data, path);
        }
        close(fd);
    } else {
        printf("[-] Failed to open %s: %s\n", path, strerror(errno));
    }
}

int main(void) {
    printf("[*] Starting thunderbolt bug reproducer...\n");

    DIR *dir = opendir("/sys/bus/pci/devices");
    if (!dir) {
        printf("[-] Failed to open /sys/bus/pci/devices: %s\n", strerror(errno));
        exit(1);
    }

    struct dirent *ent;
    while ((ent = readdir(dir)) != NULL) {
        if (ent->d_name[0] == '.') continue;

        char path[256];
        unsigned int class_code = 0;
        
        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/class", ent->d_name);
        FILE *f = fopen(path, "r");
        if (!f) continue;
        if (fscanf(f, "%x", &class_code) != 1) {
            fclose(f);
            continue;
        }
        fclose(f);
        
        // Skip Mass Storage (0x01) and Bridges (0x06) to avoid system hangs
        unsigned int base_class = class_code >> 16;
        if (base_class == 0x01 || base_class == 0x06) continue;

        snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/resource", ent->d_name);
        f = fopen(path, "r");
        if (!f) continue;

        unsigned long long start = 0, end = 0, flags = 0;
        // Read the first line which corresponds to BAR 0
        if (fscanf(f, "%llx %llx %llx", &start, &end, &flags) != 3) {
            fclose(f);
            continue;
        }
        fclose(f);

        // Must be a Memory BAR (IORESOURCE_MEM = 0x200)
        if (!(flags & 0x200)) continue;

        unsigned long long size = end ? (end - start + 1) : 0;
        
        // Check if BAR 0 is dangerously small for the thunderbolt driver
        // The driver expects to access registers up to 0x39944.
        if (size > 0 && size < 0x39640) {
            unsigned int vendor = 0, device = 0;
            
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/vendor", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &vendor); fclose(f); }

            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/device", ent->d_name);
            f = fopen(path, "r"); 
            if (f) { fscanf(f, "%x", &device); fclose(f); }

            if (!vendor || !device) continue;

            printf("[*] Found candidate device %s (vendor=%04x, device=%04x, BAR0 size=%llu)\n", ent->d_name, vendor, device, size);

            // 1. Unbind from current driver
            snprintf(path, sizeof(path), "/sys/bus/pci/devices/%s/driver/unbind", ent->d_name);
            write_file(path, ent->d_name);

            // 2. Add ID to thunderbolt driver
            char id_str[64];
            snprintf(id_str, sizeof(id_str), "%04x %04x", vendor, device);
            write_file("/sys/bus/pci/drivers/thunderbolt/new_id", id_str);

            // 3. Bind to thunderbolt driver (Triggers the OOB access)
            write_file("/sys/bus/pci/drivers/thunderbolt/bind", ent->d_name);
            
            // Wait a bit for async probe or crash
            sleep(1);
        }
    }
    closedir(dir);
    printf("[+] Done.\n");
    return 0;
}
 Reproduced:true ReproducedBugTitle:BUG: unable to handle kernel paging request in ioread32 ReproducedCrashReport:thunderbolt 0000:00:03.0: error -EINVAL: cannot enable interrupts, aborting
thunderbolt 0000:00:03.0: probe with driver thunderbolt failed with error -22
BUG: unable to handle page fault for address: ffffc90003c99640
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD 100000067 P4D 100000067 PUD 1012c1067 PMD 18bddc067 PTE 0
Oops: Oops: 0000 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 5875 Comm: syz-executor277 Not tainted syzkaller #1 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
Call Trace:
 <TASK>
 nhi_probe+0xcc/0x880 drivers/thunderbolt/nhi.c:1198
 nhi_pci_probe+0x46b/0x580 drivers/thunderbolt/pci.c:479
 local_pci_probe drivers/pci/pci-driver.c:332 [inline]
 pci_call_probe drivers/pci/pci-driver.c:394 [inline]
 __pci_device_probe drivers/pci/pci-driver.c:455 [inline]
 pci_device_probe+0x431/0xc90 drivers/pci/pci-driver.c:489
 call_driver_probe drivers/base/dd.c:-1 [inline]
 really_probe+0x254/0xae0 drivers/base/dd.c:706
 __driver_probe_device+0x1e8/0x360 drivers/base/dd.c:868
 device_driver_attach+0xe0/0x1d0 drivers/base/dd.c:1203
 bind_store+0x1d0/0x220 drivers/base/bus.c:267
 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x612/0xba0 fs/read_write.c:687
 ksys_write+0x150/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fbbd4aa6bf7
Code: 48 89 fa 4c 89 df e8 98 1d 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007fffa5b186f0 EFLAGS: 00000202 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000555595193400 RCX: 00007fbbd4aa6bf7
RDX: 000000000000000c RSI: 0000555595195883 RDI: 0000000000000004
RBP: 00007fbbd4ae31e8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000555595195883
R13: 00007fbbd4ae8bce R14: 00007fbbd4ae6e4c R15: 000000000001ffff
 </TASK>
Modules linked in:
CR2: ffffc90003c99640
---[ end trace 0000000000000000 ]---
RIP: 0010:readl arch/x86/include/asm/io.h:59 [inline]
RIP: 0010:ioread32+0x1c/0x80 lib/iomap.c:99
Code: 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 55 53 48 89 fb e8 a2 b2 e7 fc 48 81 fb 00 00 04 00 72 09 e8 94 b2 e7 fc <8b> 03 eb 55 48 81 fb 01 00 01 00 72 0a e8 82 b2 e7 fc 89 da ed eb
RSP: 0018:ffffc900046df850 EFLAGS: 00010293
RAX: ffffffff84df702c RBX: ffffc90003c99640 RCX: ffff8881047b0000
RDX: 0000000000000000 RSI: ffffffff8e365c7f RDI: ffffc90003c99640
RBP: 1ffff11032e7c710 R08: ffffffff9081c537 R09: 1ffffffff21038a6
R10: dffffc0000000000 R11: fffffbfff21038a7 R12: ffff8881973e3888
R13: ffff888187b5a0d0 R14: ffff8881973e3838 R15: 1ffff11032e7c711
FS:  0000555595193400(0000) GS:ffff8882e84a0000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffc90003c99640 CR3: 000000010fc4e000 CR4: 0000000000352ef0
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	90                   	nop
   a:	90                   	nop
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	f3 0f 1e fa          	endbr64
  12:	55                   	push   %rbp
  13:	53                   	push   %rbx
  14:	48 89 fb             	mov    %rdi,%rbx
  17:	e8 a2 b2 e7 fc       	call   0xfce7b2be
  1c:	48 81 fb 00 00 04 00 	cmp    $0x40000,%rbx
  23:	72 09                	jb     0x2e
  25:	e8 94 b2 e7 fc       	call   0xfce7b2be
* 2a:	8b 03                	mov    (%rbx),%eax <-- trapping instruction
  2c:	eb 55                	jmp    0x83
  2e:	48 81 fb 01 00 01 00 	cmp    $0x10001,%rbx
  35:	72 0a                	jb     0x41
  37:	e8 82 b2 e7 fc       	call   0xfce7b2be
  3c:	89 da                	mov    %ebx,%edx
  3e:	ed                   	in     (%dx),%eax
  3f:	eb                   	.byte 0xeb
]

250/1 2026/08/10 08:47 action save-repro-c
0m Results:
map[]

LLM Calls Summary:
Total Calls Total Tokens Avg Tokens Total Duration (Seconds) Avg Duration (Seconds)
Tool Calls Summary:
Total Calls Total Duration (Seconds) Avg Duration (Seconds)