[helgaas-pci:pci/driver 17/24] drivers/misc/cxl/guest.c:34:29: sparse: sparse: incorrect type in assignment (different modifiers)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git pci/driver
head: 0508b6f72f055b88df518db4f3811bda9bb35da4
commit: 115c9d41e58388415f4956d0a988c90fb48663b9 [17/24] cxl: Factor out common dev->driver expressions
config: powerpc64-randconfig-s032-20211025 (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 11.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git/commit/?i...
git remote add helgaas-pci https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git
git fetch --no-tags helgaas-pci pci/driver
git checkout 115c9d41e58388415f4956d0a988c90fb48663b9
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=powerpc64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/misc/cxl/guest.c:34:29: sparse: sparse: incorrect type in assignment (different modifiers) @@ expected struct pci_error_handlers *err_handler @@ got struct pci_error_handlers const *err_handler @@
drivers/misc/cxl/guest.c:34:29: sparse: expected struct pci_error_handlers *err_handler
drivers/misc/cxl/guest.c:34:29: sparse: got struct pci_error_handlers const *err_handler
drivers/misc/cxl/guest.c:108:33: sparse: sparse: incorrect type in assignment (different base types) @@ expected unsigned long long [usertype] phys_addr @@ got restricted __be64 [usertype] @@
drivers/misc/cxl/guest.c:108:33: sparse: expected unsigned long long [usertype] phys_addr
drivers/misc/cxl/guest.c:108:33: sparse: got restricted __be64 [usertype]
drivers/misc/cxl/guest.c:109:27: sparse: sparse: incorrect type in assignment (different base types) @@ expected unsigned long long [usertype] len @@ got restricted __be64 [usertype] @@
drivers/misc/cxl/guest.c:109:27: sparse: expected unsigned long long [usertype] len
drivers/misc/cxl/guest.c:109:27: sparse: got restricted __be64 [usertype]
drivers/misc/cxl/guest.c:111:35: sparse: sparse: incorrect type in assignment (different base types) @@ expected unsigned long long [usertype] len @@ got restricted __be64 [usertype] @@
drivers/misc/cxl/guest.c:111:35: sparse: expected unsigned long long [usertype] len
drivers/misc/cxl/guest.c:111:35: sparse: got restricted __be64 [usertype]
drivers/misc/cxl/guest.c:443:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected unsigned short const volatile [noderef] [usertype] __iomem *addr @@ got unsigned short [usertype] * @@
drivers/misc/cxl/guest.c:443:33: sparse: expected unsigned short const volatile [noderef] [usertype] __iomem *addr
drivers/misc/cxl/guest.c:443:33: sparse: got unsigned short [usertype] *
drivers/misc/cxl/guest.c:446:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@ got unsigned int * @@
drivers/misc/cxl/guest.c:446:33: sparse: expected unsigned int const volatile [noderef] [usertype] __iomem *addr
drivers/misc/cxl/guest.c:446:33: sparse: got unsigned int *
drivers/misc/cxl/guest.c:449:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected unsigned long long const volatile [noderef] [usertype] __iomem *addr @@ got unsigned long long [usertype] * @@
drivers/misc/cxl/guest.c:449:33: sparse: expected unsigned long long const volatile [noderef] [usertype] __iomem *addr
drivers/misc/cxl/guest.c:449:33: sparse: got unsigned long long [usertype] *
drivers/misc/cxl/guest.c:537:23: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:537:23: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:537:23: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:538:23: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:538:23: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:538:23: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:540:31: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:540:31: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:540:31: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:543:23: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:543:23: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:543:23: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:544:23: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:544:23: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:544:23: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:546:31: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:546:31: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:546:31: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:549:31: sparse: sparse: invalid assignment: |=
drivers/misc/cxl/guest.c:549:31: sparse: left side has type restricted __be64
drivers/misc/cxl/guest.c:549:31: sparse: right side has type unsigned long long
drivers/misc/cxl/guest.c:552:31: sparse: sparse: cast from restricted __be64
--
>> drivers/misc/cxl/pci.c:1816:29: sparse: sparse: incorrect type in assignment (different modifiers) @@ expected struct pci_error_handlers *err_handler @@ got struct pci_error_handlers const *err_handler @@
drivers/misc/cxl/pci.c:1816:29: sparse: expected struct pci_error_handlers *err_handler
drivers/misc/cxl/pci.c:1816:29: sparse: got struct pci_error_handlers const *err_handler
drivers/misc/cxl/pci.c:2041:37: sparse: sparse: incorrect type in assignment (different modifiers) @@ expected struct pci_error_handlers *err_handler @@ got struct pci_error_handlers const *err_handler @@
drivers/misc/cxl/pci.c:2041:37: sparse: expected struct pci_error_handlers *err_handler
drivers/misc/cxl/pci.c:2041:37: sparse: got struct pci_error_handlers const *err_handler
drivers/misc/cxl/pci.c:2090:37: sparse: sparse: incorrect type in assignment (different modifiers) @@ expected struct pci_error_handlers *err_handler @@ got struct pci_error_handlers const *err_handler @@
drivers/misc/cxl/pci.c:2090:37: sparse: expected struct pci_error_handlers *err_handler
drivers/misc/cxl/pci.c:2090:37: sparse: got struct pci_error_handlers const *err_handler
vim +34 drivers/misc/cxl/guest.c
17
18 static void pci_error_handlers(struct cxl_afu *afu,
19 int bus_error_event,
20 pci_channel_state_t state)
21 {
22 struct pci_dev *afu_dev;
23 struct pci_driver *afu_drv;
24 struct pci_error_handlers *err_handler;
25
26 if (afu->phb == NULL)
27 return;
28
29 list_for_each_entry(afu_dev, &afu->phb->bus->devices, bus_list) {
30 afu_drv = afu_dev->driver;
31 if (!afu_drv)
32 continue;
33
> 34 err_handler = afu_drv->err_handler;
35 switch (bus_error_event) {
36 case CXL_ERROR_DETECTED_EVENT:
37 afu_dev->error_state = state;
38
39 if (err_handler &&
40 err_handler->error_detected)
41 err_handler->error_detected(afu_dev, state);
42 break;
43 case CXL_SLOT_RESET_EVENT:
44 afu_dev->error_state = state;
45
46 if (err_handler &&
47 err_handler->slot_reset)
48 err_handler->slot_reset(afu_dev);
49 break;
50 case CXL_RESUME_EVENT:
51 if (err_handler &&
52 err_handler->resume)
53 err_handler->resume(afu_dev);
54 break;
55 }
56 }
57 }
58
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 1 week
[mcgrof-next:20211116-sysctl-cleanups-v4 6/35] kernel/sysctl.c:1772:2: error: unterminated conditional directive
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git 20211116-sysctl-cleanups-v4
head: 5347239461f25fc50aa761923245b9ec4a4aafec
commit: 88b045e811bcb4988e2f37077d8a582b7a111b68 [6/35] sysctl: Add const decoration for static boundary value variables
config: hexagon-randconfig-r045-20211116 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 4c2cf3a314d9131b1b288e7c8ab0c75ac1b2be1d)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/com...
git remote add mcgrof-next https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git
git fetch --no-tags mcgrof-next 20211116-sysctl-cleanups-v4
git checkout 88b045e811bcb4988e2f37077d8a582b7a111b68
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=hexagon SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> kernel/sysctl.c:1772:2: error: unterminated conditional directive
#ifdef CONFIG_SCHED_DEBUG
^
kernel/sysctl.c:1733:2: error: unterminated conditional directive
#if defined(CONFIG_SYSCTL)
^
>> kernel/sysctl.c:3398:37: error: expected expression
EXPORT_SYMBOL(proc_do_large_bitmap);
^
>> kernel/sysctl.c:3398:37: error: expected '}'
kernel/sysctl.c:1764:40: note: to match this '{'
static struct ctl_table kern_table[] = {
^
>> kernel/sysctl.c:1771:4: error: expected ';' after top level declarator
},
^
;
5 errors generated.
vim +1772 kernel/sysctl.c
1763
1764 static struct ctl_table kern_table[] = {
1765 {
1766 .procname = "sched_child_runs_first",
1767 .data = &sysctl_sched_child_runs_first,
1768 .maxlen = sizeof(unsigned int),
1769 .mode = 0644,
1770 .proc_handler = proc_dointvec,
> 1771 },
> 1772 #ifdef CONFIG_SCHED_DEBUG
1773 {
1774 .procname = "sched_min_granularity_ns",
1775 .data = &sysctl_sched_min_granularity,
1776 .maxlen = sizeof(unsigned int),
1777 .mode = 0644,
1778 .proc_handler = sched_proc_update_handler,
1779 .extra1 = (void *)&min_sched_granularity_ns,
1780 .extra2 = (void *)&max_sched_granularity_ns,
1781 },
1782 {
1783 .procname = "sched_latency_ns",
1784 .data = &sysctl_sched_latency,
1785 .maxlen = sizeof(unsigned int),
1786 .mode = 0644,
1787 .proc_handler = sched_proc_update_handler,
1788 .extra1 = (void *)&min_sched_granularity_ns,
1789 .extra2 = (void *)&max_sched_granularity_ns,
1790 },
1791 {
1792 .procname = "sched_wakeup_granularity_ns",
1793 .data = &sysctl_sched_wakeup_granularity,
1794 .maxlen = sizeof(unsigned int),
1795 .mode = 0644,
1796 .proc_handler = sched_proc_update_handler,
1797 .extra1 = (void *)&min_wakeup_granularity_ns,
1798 .extra2 = (void *)&max_wakeup_granularity_ns,
1799 },
1800 #ifdef CONFIG_SMP
1801 {
1802 .procname = "sched_tunable_scaling",
1803 .data = &sysctl_sched_tunable_scaling,
1804 .maxlen = sizeof(enum sched_tunable_scaling),
1805 .mode = 0644,
1806 .proc_handler = sched_proc_update_handler,
1807 .extra1 = (void *)&min_sched_tunable_scaling,
1808 .extra2 = (void *)&max_sched_tunable_scaling,
1809 },
1810 {
1811 .procname = "sched_migration_cost_ns",
1812 .data = &sysctl_sched_migration_cost,
1813 .maxlen = sizeof(unsigned int),
1814 .mode = 0644,
1815 .proc_handler = proc_dointvec,
1816 },
1817 {
1818 .procname = "sched_nr_migrate",
1819 .data = &sysctl_sched_nr_migrate,
1820 .maxlen = sizeof(unsigned int),
1821 .mode = 0644,
1822 .proc_handler = proc_dointvec,
1823 },
1824 #ifdef CONFIG_SCHEDSTATS
1825 {
1826 .procname = "sched_schedstats",
1827 .data = NULL,
1828 .maxlen = sizeof(unsigned int),
1829 .mode = 0644,
1830 .proc_handler = sysctl_schedstats,
1831 .extra1 = SYSCTL_ZERO,
1832 .extra2 = SYSCTL_ONE,
1833 },
1834 #endif /* CONFIG_SCHEDSTATS */
1835 #ifdef CONFIG_TASK_DELAY_ACCT
1836 {
1837 .procname = "task_delayacct",
1838 .data = NULL,
1839 .maxlen = sizeof(unsigned int),
1840 .mode = 0644,
1841 .proc_handler = sysctl_delayacct,
1842 .extra1 = SYSCTL_ZERO,
1843 .extra2 = SYSCTL_ONE,
1844 },
1845 #endif /* CONFIG_TASK_DELAY_ACCT */
1846 #ifdef CONFIG_NUMA_BALANCING
1847 {
1848 .procname = "numa_balancing",
1849 .data = NULL, /* filled in by handler */
1850 .maxlen = sizeof(unsigned int),
1851 .mode = 0644,
1852 .proc_handler = sysctl_numa_balancing,
1853 .extra1 = SYSCTL_ZERO,
1854 .extra2 = SYSCTL_ONE,
1855 },
1856 #endif /* CONFIG_NUMA_BALANCING */
1857 {
1858 .procname = "sched_rt_period_us",
1859 .data = &sysctl_sched_rt_period,
1860 .maxlen = sizeof(unsigned int),
1861 .mode = 0644,
1862 .proc_handler = sched_rt_handler,
1863 },
1864 {
1865 .procname = "sched_rt_runtime_us",
1866 .data = &sysctl_sched_rt_runtime,
1867 .maxlen = sizeof(int),
1868 .mode = 0644,
1869 .proc_handler = sched_rt_handler,
1870 },
1871 {
1872 .procname = "sched_deadline_period_max_us",
1873 .data = &sysctl_sched_dl_period_max,
1874 .maxlen = sizeof(unsigned int),
1875 .mode = 0644,
1876 .proc_handler = proc_dointvec,
1877 },
1878 {
1879 .procname = "sched_deadline_period_min_us",
1880 .data = &sysctl_sched_dl_period_min,
1881 .maxlen = sizeof(unsigned int),
1882 .mode = 0644,
1883 .proc_handler = proc_dointvec,
1884 },
1885 {
1886 .procname = "sched_rr_timeslice_ms",
1887 .data = &sysctl_sched_rr_timeslice,
1888 .maxlen = sizeof(int),
1889 .mode = 0644,
1890 .proc_handler = sched_rr_handler,
1891 },
1892 #ifdef CONFIG_UCLAMP_TASK
1893 {
1894 .procname = "sched_util_clamp_min",
1895 .data = &sysctl_sched_uclamp_util_min,
1896 .maxlen = sizeof(unsigned int),
1897 .mode = 0644,
1898 .proc_handler = sysctl_sched_uclamp_handler,
1899 },
1900 {
1901 .procname = "sched_util_clamp_max",
1902 .data = &sysctl_sched_uclamp_util_max,
1903 .maxlen = sizeof(unsigned int),
1904 .mode = 0644,
1905 .proc_handler = sysctl_sched_uclamp_handler,
1906 },
1907 {
1908 .procname = "sched_util_clamp_min_rt_default",
1909 .data = &sysctl_sched_uclamp_util_min_rt_default,
1910 .maxlen = sizeof(unsigned int),
1911 .mode = 0644,
1912 .proc_handler = sysctl_sched_uclamp_handler,
1913 },
1914 #endif
1915 #ifdef CONFIG_SCHED_AUTOGROUP
1916 {
1917 .procname = "sched_autogroup_enabled",
1918 .data = &sysctl_sched_autogroup_enabled,
1919 .maxlen = sizeof(unsigned int),
1920 .mode = 0644,
1921 .proc_handler = proc_dointvec_minmax,
1922 .extra1 = SYSCTL_ZERO,
1923 .extra2 = SYSCTL_ONE,
1924 },
1925 #endif
1926 #ifdef CONFIG_CFS_BANDWIDTH
1927 {
1928 .procname = "sched_cfs_bandwidth_slice_us",
1929 .data = &sysctl_sched_cfs_bandwidth_slice,
1930 .maxlen = sizeof(unsigned int),
1931 .mode = 0644,
1932 .proc_handler = proc_dointvec_minmax,
1933 .extra1 = SYSCTL_ONE,
1934 },
1935 #endif
1936 #if defined(CONFIG_ENERGY_MODEL) && defined(CONFIG_CPU_FREQ_GOV_SCHEDUTIL)
1937 {
1938 .procname = "sched_energy_aware",
1939 .data = &sysctl_sched_energy_aware,
1940 .maxlen = sizeof(unsigned int),
1941 .mode = 0644,
1942 .proc_handler = sched_energy_aware_handler,
1943 .extra1 = SYSCTL_ZERO,
1944 .extra2 = SYSCTL_ONE,
1945 },
1946 #endif
1947 #ifdef CONFIG_PROVE_LOCKING
1948 {
1949 .procname = "prove_locking",
1950 .data = &prove_locking,
1951 .maxlen = sizeof(int),
1952 .mode = 0644,
1953 .proc_handler = proc_dointvec,
1954 },
1955 #endif
1956 #ifdef CONFIG_LOCK_STAT
1957 {
1958 .procname = "lock_stat",
1959 .data = &lock_stat,
1960 .maxlen = sizeof(int),
1961 .mode = 0644,
1962 .proc_handler = proc_dointvec,
1963 },
1964 #endif
1965 {
1966 .procname = "panic",
1967 .data = &panic_timeout,
1968 .maxlen = sizeof(int),
1969 .mode = 0644,
1970 .proc_handler = proc_dointvec,
1971 },
1972 #ifdef CONFIG_COREDUMP
1973 {
1974 .procname = "core_uses_pid",
1975 .data = &core_uses_pid,
1976 .maxlen = sizeof(int),
1977 .mode = 0644,
1978 .proc_handler = proc_dointvec,
1979 },
1980 {
1981 .procname = "core_pattern",
1982 .data = core_pattern,
1983 .maxlen = CORENAME_MAX_SIZE,
1984 .mode = 0644,
1985 .proc_handler = proc_dostring_coredump,
1986 },
1987 {
1988 .procname = "core_pipe_limit",
1989 .data = &core_pipe_limit,
1990 .maxlen = sizeof(unsigned int),
1991 .mode = 0644,
1992 .proc_handler = proc_dointvec,
1993 },
1994 #endif
1995 #ifdef CONFIG_PROC_SYSCTL
1996 {
1997 .procname = "tainted",
1998 .maxlen = sizeof(long),
1999 .mode = 0644,
2000 .proc_handler = proc_taint,
2001 },
2002 {
2003 .procname = "sysctl_writes_strict",
2004 .data = &sysctl_writes_strict,
2005 .maxlen = sizeof(int),
2006 .mode = 0644,
2007 .proc_handler = proc_dointvec_minmax,
2008 .extra1 = SYSCTL_NEG_ONE,
2009 .extra2 = SYSCTL_ONE,
2010 },
2011 #endif
2012 #ifdef CONFIG_LATENCYTOP
2013 {
2014 .procname = "latencytop",
2015 .data = &latencytop_enabled,
2016 .maxlen = sizeof(int),
2017 .mode = 0644,
2018 .proc_handler = sysctl_latencytop,
2019 },
2020 #endif
2021 #ifdef CONFIG_BLK_DEV_INITRD
2022 {
2023 .procname = "real-root-dev",
2024 .data = &real_root_dev,
2025 .maxlen = sizeof(int),
2026 .mode = 0644,
2027 .proc_handler = proc_dointvec,
2028 },
2029 #endif
2030 {
2031 .procname = "print-fatal-signals",
2032 .data = &print_fatal_signals,
2033 .maxlen = sizeof(int),
2034 .mode = 0644,
2035 .proc_handler = proc_dointvec,
2036 },
2037 #ifdef CONFIG_SPARC
2038 {
2039 .procname = "reboot-cmd",
2040 .data = reboot_command,
2041 .maxlen = 256,
2042 .mode = 0644,
2043 .proc_handler = proc_dostring,
2044 },
2045 {
2046 .procname = "stop-a",
2047 .data = &stop_a_enabled,
2048 .maxlen = sizeof (int),
2049 .mode = 0644,
2050 .proc_handler = proc_dointvec,
2051 },
2052 {
2053 .procname = "scons-poweroff",
2054 .data = &scons_pwroff,
2055 .maxlen = sizeof (int),
2056 .mode = 0644,
2057 .proc_handler = proc_dointvec,
2058 },
2059 #endif
2060 #ifdef CONFIG_SPARC64
2061 {
2062 .procname = "tsb-ratio",
2063 .data = &sysctl_tsb_ratio,
2064 .maxlen = sizeof (int),
2065 .mode = 0644,
2066 .proc_handler = proc_dointvec,
2067 },
2068 #endif
2069 #ifdef CONFIG_PARISC
2070 {
2071 .procname = "soft-power",
2072 .data = &pwrsw_enabled,
2073 .maxlen = sizeof (int),
2074 .mode = 0644,
2075 .proc_handler = proc_dointvec,
2076 },
2077 #endif
2078 #ifdef CONFIG_SYSCTL_ARCH_UNALIGN_ALLOW
2079 {
2080 .procname = "unaligned-trap",
2081 .data = &unaligned_enabled,
2082 .maxlen = sizeof (int),
2083 .mode = 0644,
2084 .proc_handler = proc_dointvec,
2085 },
2086 #endif
2087 {
2088 .procname = "ctrl-alt-del",
2089 .data = &C_A_D,
2090 .maxlen = sizeof(int),
2091 .mode = 0644,
2092 .proc_handler = proc_dointvec,
2093 },
2094 #ifdef CONFIG_FUNCTION_TRACER
2095 {
2096 .procname = "ftrace_enabled",
2097 .data = &ftrace_enabled,
2098 .maxlen = sizeof(int),
2099 .mode = 0644,
2100 .proc_handler = ftrace_enable_sysctl,
2101 },
2102 #endif
2103 #ifdef CONFIG_STACK_TRACER
2104 {
2105 .procname = "stack_tracer_enabled",
2106 .data = &stack_tracer_enabled,
2107 .maxlen = sizeof(int),
2108 .mode = 0644,
2109 .proc_handler = stack_trace_sysctl,
2110 },
2111 #endif
2112 #ifdef CONFIG_TRACING
2113 {
2114 .procname = "ftrace_dump_on_oops",
2115 .data = &ftrace_dump_on_oops,
2116 .maxlen = sizeof(int),
2117 .mode = 0644,
2118 .proc_handler = proc_dointvec,
2119 },
2120 {
2121 .procname = "traceoff_on_warning",
2122 .data = &__disable_trace_on_warning,
2123 .maxlen = sizeof(__disable_trace_on_warning),
2124 .mode = 0644,
2125 .proc_handler = proc_dointvec,
2126 },
2127 {
2128 .procname = "tracepoint_printk",
2129 .data = &tracepoint_printk,
2130 .maxlen = sizeof(tracepoint_printk),
2131 .mode = 0644,
2132 .proc_handler = tracepoint_printk_sysctl,
2133 },
2134 #endif
2135 #ifdef CONFIG_KEXEC_CORE
2136 {
2137 .procname = "kexec_load_disabled",
2138 .data = &kexec_load_disabled,
2139 .maxlen = sizeof(int),
2140 .mode = 0644,
2141 /* only handle a transition from default "0" to "1" */
2142 .proc_handler = proc_dointvec_minmax,
2143 .extra1 = SYSCTL_ONE,
2144 .extra2 = SYSCTL_ONE,
2145 },
2146 #endif
2147 #ifdef CONFIG_MODULES
2148 {
2149 .procname = "modprobe",
2150 .data = &modprobe_path,
2151 .maxlen = KMOD_PATH_LEN,
2152 .mode = 0644,
2153 .proc_handler = proc_dostring,
2154 },
2155 {
2156 .procname = "modules_disabled",
2157 .data = &modules_disabled,
2158 .maxlen = sizeof(int),
2159 .mode = 0644,
2160 /* only handle a transition from default "0" to "1" */
2161 .proc_handler = proc_dointvec_minmax,
2162 .extra1 = SYSCTL_ONE,
2163 .extra2 = SYSCTL_ONE,
2164 },
2165 #endif
2166 #ifdef CONFIG_UEVENT_HELPER
2167 {
2168 .procname = "hotplug",
2169 .data = &uevent_helper,
2170 .maxlen = UEVENT_HELPER_PATH_LEN,
2171 .mode = 0644,
2172 .proc_handler = proc_dostring,
2173 },
2174 #endif
2175 #ifdef CONFIG_CHR_DEV_SG
2176 {
2177 .procname = "sg-big-buff",
2178 .data = &sg_big_buff,
2179 .maxlen = sizeof (int),
2180 .mode = 0444,
2181 .proc_handler = proc_dointvec,
2182 },
2183 #endif
2184 #ifdef CONFIG_BSD_PROCESS_ACCT
2185 {
2186 .procname = "acct",
2187 .data = &acct_parm,
2188 .maxlen = 3*sizeof(int),
2189 .mode = 0644,
2190 .proc_handler = proc_dointvec,
2191 },
2192 #endif
2193 #ifdef CONFIG_MAGIC_SYSRQ
2194 {
2195 .procname = "sysrq",
2196 .data = NULL,
2197 .maxlen = sizeof (int),
2198 .mode = 0644,
2199 .proc_handler = sysrq_sysctl_handler,
2200 },
2201 #endif
2202 #ifdef CONFIG_PROC_SYSCTL
2203 {
2204 .procname = "cad_pid",
2205 .data = NULL,
2206 .maxlen = sizeof (int),
2207 .mode = 0600,
2208 .proc_handler = proc_do_cad_pid,
2209 },
2210 #endif
2211 {
2212 .procname = "threads-max",
2213 .data = NULL,
2214 .maxlen = sizeof(int),
2215 .mode = 0644,
2216 .proc_handler = sysctl_max_threads,
2217 },
2218 {
2219 .procname = "random",
2220 .mode = 0555,
2221 .child = random_table,
2222 },
2223 {
2224 .procname = "usermodehelper",
2225 .mode = 0555,
2226 .child = usermodehelper_table,
2227 },
2228 #ifdef CONFIG_FW_LOADER_USER_HELPER
2229 {
2230 .procname = "firmware_config",
2231 .mode = 0555,
2232 .child = firmware_config_table,
2233 },
2234 #endif
2235 {
2236 .procname = "overflowuid",
2237 .data = &overflowuid,
2238 .maxlen = sizeof(int),
2239 .mode = 0644,
2240 .proc_handler = proc_dointvec_minmax,
2241 .extra1 = (void *)&minolduid,
2242 .extra2 = (void *)&maxolduid,
2243 },
2244 {
2245 .procname = "overflowgid",
2246 .data = &overflowgid,
2247 .maxlen = sizeof(int),
2248 .mode = 0644,
2249 .proc_handler = proc_dointvec_minmax,
2250 .extra1 = (void *)&minolduid,
2251 .extra2 = (void *)&maxolduid,
2252 },
2253 #ifdef CONFIG_S390
2254 {
2255 .procname = "userprocess_debug",
2256 .data = &show_unhandled_signals,
2257 .maxlen = sizeof(int),
2258 .mode = 0644,
2259 .proc_handler = proc_dointvec,
2260 },
2261 #endif
2262 #ifdef CONFIG_SMP
2263 {
2264 .procname = "oops_all_cpu_backtrace",
2265 .data = &sysctl_oops_all_cpu_backtrace,
2266 .maxlen = sizeof(int),
2267 .mode = 0644,
2268 .proc_handler = proc_dointvec_minmax,
2269 .extra1 = SYSCTL_ZERO,
2270 .extra2 = SYSCTL_ONE,
2271 },
2272 #endif /* CONFIG_SMP */
2273 {
2274 .procname = "pid_max",
2275 .data = &pid_max,
2276 .maxlen = sizeof (int),
2277 .mode = 0644,
2278 .proc_handler = proc_dointvec_minmax,
2279 .extra1 = &pid_max_min,
2280 .extra2 = &pid_max_max,
2281 },
2282 {
2283 .procname = "panic_on_oops",
2284 .data = &panic_on_oops,
2285 .maxlen = sizeof(int),
2286 .mode = 0644,
2287 .proc_handler = proc_dointvec,
2288 },
2289 {
2290 .procname = "panic_print",
2291 .data = &panic_print,
2292 .maxlen = sizeof(unsigned long),
2293 .mode = 0644,
2294 .proc_handler = proc_doulongvec_minmax,
2295 },
2296 #if defined CONFIG_PRINTK
2297 {
2298 .procname = "printk",
2299 .data = &console_loglevel,
2300 .maxlen = 4*sizeof(int),
2301 .mode = 0644,
2302 .proc_handler = proc_dointvec,
2303 },
2304 {
2305 .procname = "printk_ratelimit",
2306 .data = &printk_ratelimit_state.interval,
2307 .maxlen = sizeof(int),
2308 .mode = 0644,
2309 .proc_handler = proc_dointvec_jiffies,
2310 },
2311 {
2312 .procname = "printk_ratelimit_burst",
2313 .data = &printk_ratelimit_state.burst,
2314 .maxlen = sizeof(int),
2315 .mode = 0644,
2316 .proc_handler = proc_dointvec,
2317 },
2318 {
2319 .procname = "printk_delay",
2320 .data = &printk_delay_msec,
2321 .maxlen = sizeof(int),
2322 .mode = 0644,
2323 .proc_handler = proc_dointvec_minmax,
2324 .extra1 = SYSCTL_ZERO,
2325 .extra2 = (void *)&ten_thousand,
2326 },
2327 {
2328 .procname = "printk_devkmsg",
2329 .data = devkmsg_log_str,
2330 .maxlen = DEVKMSG_STR_MAX_SIZE,
2331 .mode = 0644,
2332 .proc_handler = devkmsg_sysctl_set_loglvl,
2333 },
2334 {
2335 .procname = "dmesg_restrict",
2336 .data = &dmesg_restrict,
2337 .maxlen = sizeof(int),
2338 .mode = 0644,
2339 .proc_handler = proc_dointvec_minmax_sysadmin,
2340 .extra1 = SYSCTL_ZERO,
2341 .extra2 = SYSCTL_ONE,
2342 },
2343 {
2344 .procname = "kptr_restrict",
2345 .data = &kptr_restrict,
2346 .maxlen = sizeof(int),
2347 .mode = 0644,
2348 .proc_handler = proc_dointvec_minmax_sysadmin,
2349 .extra1 = SYSCTL_ZERO,
2350 .extra2 = SYSCTL_TWO,
2351 },
2352 #endif
2353 {
2354 .procname = "ngroups_max",
2355 .data = (void *)&ngroups_max,
2356 .maxlen = sizeof (int),
2357 .mode = 0444,
2358 .proc_handler = proc_dointvec,
2359 },
2360 {
2361 .procname = "cap_last_cap",
2362 .data = (void *)&cap_last_cap,
2363 .maxlen = sizeof(int),
2364 .mode = 0444,
2365 .proc_handler = proc_dointvec,
2366 },
2367 #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86)
2368 {
2369 .procname = "unknown_nmi_panic",
2370 .data = &unknown_nmi_panic,
2371 .maxlen = sizeof (int),
2372 .mode = 0644,
2373 .proc_handler = proc_dointvec,
2374 },
2375 #endif
2376
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 1 week
[mcgrof-next:20211116-sysctl-cleanups-v3 18/20] include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git 20211116-sysctl-cleanups-v3
head: 06113f1d9a2d0669964adfa2e0128bd50e56b621
commit: 39ba9159476b6d86288f95f4cb62ad7055680395 [18/20] sysctl: add helper to register a sysctl mount point
config: sparc-randconfig-r004-20211116 (attached as .config)
compiler: sparc-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/com...
git remote add mcgrof-next https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git
git fetch --no-tags mcgrof-next 20211116-sysctl-cleanups-v3
git checkout 39ba9159476b6d86288f95f4cb62ad7055680395
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=sparc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/kdebug_32.h:11,
from arch/sparc/include/asm/kdebug.h:7,
from include/linux/kdebug.h:5,
from arch/sparc/kernel/traps_32.c:19:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/kernel/traps_32.c: At top level:
arch/sparc/kernel/traps_32.c:368:6: error: no previous prototype for 'trap_init' [-Werror=missing-prototypes]
368 | void trap_init(void)
| ^~~~~~~~~
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/kdebug_32.h:11,
from arch/sparc/include/asm/kdebug.h:7,
from include/linux/kdebug.h:5,
from arch/sparc/kernel/traps_32.c:19:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/seq_file.h:12,
from arch/sparc/kernel/irq_32.c:16:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
At top level:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/oplib_32.h:12,
from arch/sparc/include/asm/oplib.h:7,
from arch/sparc/include/asm/pgtable_32.h:32,
from arch/sparc/include/asm/pgtable.h:7,
from include/linux/pgtable.h:6,
from include/linux/mm.h:33,
from arch/sparc/kernel/smp_32.c:19:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/kernel/smp_32.c: At top level:
arch/sparc/kernel/smp_32.c:177:5: error: no previous prototype for 'setup_profiling_timer' [-Werror=missing-prototypes]
177 | int setup_profiling_timer(unsigned int multiplier)
| ^~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/oplib_32.h:12,
from arch/sparc/include/asm/oplib.h:7,
from arch/sparc/include/asm/pgtable_32.h:32,
from arch/sparc/include/asm/pgtable.h:7,
from include/linux/pgtable.h:6,
from include/linux/mm.h:33,
from arch/sparc/kernel/smp_32.c:19:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from include/linux/moduleloader.h:6,
from arch/sparc/kernel/module.c:8:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/kernel/module.c: In function 'module_frob_arch_sections':
arch/sparc/kernel/module.c:62:15: error: variable 'strtab' set but not used [-Werror=unused-but-set-variable]
62 | char *strtab;
| ^~~~~~
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from include/linux/moduleloader.h:6,
from arch/sparc/kernel/module.c:8:
At top level:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/seq_file.h:12,
from arch/sparc/mm/srmmu.c:12:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/mm/srmmu.c: In function 'poke_hypersparc':
arch/sparc/mm/srmmu.c:1081:32: error: variable 'clear' set but not used [-Werror=unused-but-set-variable]
1081 | volatile unsigned long clear;
| ^~~~~
arch/sparc/mm/srmmu.c: In function 'smp_flush_page_for_dma':
arch/sparc/mm/srmmu.c:1639:13: error: cast between incompatible function types from 'void (*)(long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1639 | xc1((smpfunc_t) local_ops->page_for_dma, page);
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_cache_mm':
arch/sparc/mm/srmmu.c:1662:29: error: cast between incompatible function types from 'void (*)(struct mm_struct *)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1662 | xc1((smpfunc_t) local_ops->cache_mm, (unsigned long) mm);
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_tlb_mm':
arch/sparc/mm/srmmu.c:1674:29: error: cast between incompatible function types from 'void (*)(struct mm_struct *)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1674 | xc1((smpfunc_t) local_ops->tlb_mm, (unsigned long) mm);
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_cache_range':
arch/sparc/mm/srmmu.c:1694:29: error: cast between incompatible function types from 'void (*)(struct vm_area_struct *, long unsigned int, long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1694 | xc3((smpfunc_t) local_ops->cache_range,
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_tlb_range':
arch/sparc/mm/srmmu.c:1711:29: error: cast between incompatible function types from 'void (*)(struct vm_area_struct *, long unsigned int, long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1711 | xc3((smpfunc_t) local_ops->tlb_range,
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_cache_page':
arch/sparc/mm/srmmu.c:1726:29: error: cast between incompatible function types from 'void (*)(struct vm_area_struct *, long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1726 | xc2((smpfunc_t) local_ops->cache_page,
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_tlb_page':
arch/sparc/mm/srmmu.c:1741:29: error: cast between incompatible function types from 'void (*)(struct vm_area_struct *, long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1741 | xc2((smpfunc_t) local_ops->tlb_page,
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_page_to_ram':
arch/sparc/mm/srmmu.c:1756:13: error: cast between incompatible function types from 'void (*)(long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1756 | xc1((smpfunc_t) local_ops->page_to_ram, page);
| ^
arch/sparc/mm/srmmu.c: In function 'smp_flush_sig_insns':
arch/sparc/mm/srmmu.c:1767:21: error: cast between incompatible function types from 'void (*)(struct mm_struct *, long unsigned int)' to 'void (*)(long unsigned int, long unsigned int, long unsigned int, long unsigned int, long unsigned int)' [-Werror=cast-function-type]
1767 | xc2((smpfunc_t) local_ops->sig_insns,
| ^
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/seq_file.h:12,
from arch/sparc/mm/srmmu.c:12:
At top level:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/oplib_32.h:12,
from arch/sparc/include/asm/oplib.h:7,
from arch/sparc/include/asm/pgtable_32.h:32,
from arch/sparc/include/asm/pgtable.h:7,
from include/linux/pgtable.h:6,
from include/linux/mm.h:33,
from arch/sparc/mm/leon_mm.c:14:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/mm/leon_mm.c: In function 'leon_swprobe':
arch/sparc/mm/leon_mm.c:42:32: error: variable 'paddrbase' set but not used [-Werror=unused-but-set-variable]
42 | unsigned int lvl, pte, paddrbase;
| ^~~~~~~~~
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/proc_fs.h:10,
from arch/sparc/include/asm/prom.h:18,
from include/linux/of.h:250,
from arch/sparc/include/asm/openprom.h:15,
from arch/sparc/include/asm/oplib_32.h:12,
from arch/sparc/include/asm/oplib.h:7,
from arch/sparc/include/asm/pgtable_32.h:32,
from arch/sparc/include/asm/pgtable.h:7,
from include/linux/pgtable.h:6,
from include/linux/mm.h:33,
from arch/sparc/mm/leon_mm.c:14:
At top level:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from arch/sparc/lib/cmpdi2.c:2:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/lib/cmpdi2.c: At top level:
arch/sparc/lib/cmpdi2.c:6:11: error: no previous prototype for '__cmpdi2' [-Werror=missing-prototypes]
6 | word_type __cmpdi2(long long a, long long b)
| ^~~~~~~~
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from arch/sparc/lib/cmpdi2.c:2:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from arch/sparc/lib/ucmpdi2.c:2:
include/linux/sysctl.h: In function 'register_sysctl_mount_point':
include/linux/sysctl.h:230:1: error: expected ';' before '}' token
230 | }
| ^
arch/sparc/lib/ucmpdi2.c: At top level:
arch/sparc/lib/ucmpdi2.c:5:11: error: no previous prototype for '__ucmpdi2' [-Werror=missing-prototypes]
5 | word_type __ucmpdi2(unsigned long long a, unsigned long long b)
| ^~~~~~~~~
In file included from include/linux/umh.h:9,
from include/linux/kmod.h:9,
from include/linux/module.h:17,
from arch/sparc/lib/ucmpdi2.c:2:
>> include/linux/sysctl.h:227:30: error: 'register_sysctl_mount_point' defined but not used [-Werror=unused-function]
227 | static struct sysctl_header *register_sysctl_mount_point(const char *path)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/register_sysctl_mount_point +227 include/linux/sysctl.h
226
> 227 static struct sysctl_header *register_sysctl_mount_point(const char *path)
228 {
229 return NULL
230 }
231
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 1 week
[toke:xdp-traffic-gen-01 8/10] net/bpf/test_run.c:160: undefined reference to `page_pool_create'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git xdp-traffic-gen-01
head: a7f4d7f9e215d1e540f81f6cd3f5b46d970c5449
commit: fcc7154eccb6e67d55d0cf407d4ce95c49042a5a [8/10] bpf: Add XDP_REDIRECT support to XDP for bpf_prog_run()
config: x86_64-randconfig-a013-20211116 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git/commit/?id...
git remote add toke https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git
git fetch --no-tags toke xdp-traffic-gen-01
git checkout fcc7154eccb6e67d55d0cf407d4ce95c49042a5a
# save the attached .config to linux build tree
mkdir build_dir
make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
vmlinux.o: warning: objtool: do_machine_check()+0x6d1: call to queue_task_work() leaves .noinstr.text section
vmlinux.o: warning: objtool: enter_from_user_mode()+0x4e: call to on_thread_stack() leaves .noinstr.text section
vmlinux.o: warning: objtool: syscall_enter_from_user_mode()+0x53: call to on_thread_stack() leaves .noinstr.text section
vmlinux.o: warning: objtool: syscall_enter_from_user_mode_prepare()+0x4e: call to on_thread_stack() leaves .noinstr.text section
vmlinux.o: warning: objtool: irqentry_enter_from_user_mode()+0x4e: call to on_thread_stack() leaves .noinstr.text section
ld: net/bpf/test_run.o: in function `bpf_test_run_xdp_setup':
>> net/bpf/test_run.c:160: undefined reference to `page_pool_create'
vim +160 net/bpf/test_run.c
144
145 static int bpf_test_run_xdp_setup(struct bpf_test_timer *t, struct xdp_buff *orig_ctx)
146 {
147 struct xdp_mem_info mem = {};
148 struct page_pool *pp;
149 int err;
150 struct page_pool_params pp_params = {
151 .order = 0,
152 .flags = 0,
153 .pool_size = NAPI_POLL_WEIGHT * 2,
154 .nid = NUMA_NO_NODE,
155 .max_len = TEST_XDP_FRAME_SIZE,
156 .init_callback = bpf_test_run_xdp_init_page,
157 .init_arg = t,
158 };
159
> 160 pp = page_pool_create(&pp_params);
161 if (IS_ERR(pp))
162 return PTR_ERR(pp);
163
164 /* will copy 'mem->id' into pp->xdp_mem_id */
165 err = xdp_reg_mem_model(&mem, MEM_TYPE_PAGE_POOL, pp);
166 if (err) {
167 page_pool_destroy(pp);
168 return err;
169 }
170 t->xdp.pp = pp;
171
172 /* We create a 'fake' RXQ referencing the original dev, but with an
173 * xdp_mem_info pointing to our page_pool
174 */
175 xdp_rxq_info_reg(&t->xdp.rxq, orig_ctx->rxq->dev, 0, 0);
176 t->xdp.rxq.mem.type = MEM_TYPE_PAGE_POOL;
177 t->xdp.rxq.mem.id = pp->xdp_mem_id;
178 t->xdp.orig_ctx = orig_ctx;
179
180 return 0;
181 }
182
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 1 week
[mcgrof-next:20211116-sysctl-cleanups-v4 6/35] kernel/sysctl.c:1772: error: unterminated #ifdef
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git 20211116-sysctl-cleanups-v4
head: 5347239461f25fc50aa761923245b9ec4a4aafec
commit: 88b045e811bcb4988e2f37077d8a582b7a111b68 [6/35] sysctl: Add const decoration for static boundary value variables
config: nds32-allnoconfig (attached as .config)
compiler: nds32le-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/com...
git remote add mcgrof-next https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git
git fetch --no-tags mcgrof-next 20211116-sysctl-cleanups-v4
git checkout 88b045e811bcb4988e2f37077d8a582b7a111b68
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=nds32 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> kernel/sysctl.c:1772: error: unterminated #ifdef
1772 | #ifdef CONFIG_SCHED_DEBUG
|
>> kernel/sysctl.c:1733: error: unterminated #if
1733 | #if defined(CONFIG_SYSCTL)
|
>> kernel/sysctl.c:1771:9: error: expected expression at end of input
1771 | },
| ^
kernel/sysctl.c:1764:25: warning: 'kern_table' defined but not used [-Wunused-variable]
1764 | static struct ctl_table kern_table[] = {
| ^~~~~~~~~~
kernel/sysctl.c:1482:12: warning: 'proc_do_cad_pid' defined but not used [-Wunused-function]
1482 | static int proc_do_cad_pid(struct ctl_table *table, int write, void *buffer,
| ^~~~~~~~~~~~~~~
kernel/sysctl.c:1187:12: warning: 'proc_dostring_coredump' defined but not used [-Wunused-function]
1187 | static int proc_dostring_coredump(struct ctl_table *table, int write,
| ^~~~~~~~~~~~~~~~~~~~~~
kernel/sysctl.c:1177:12: warning: 'proc_dointvec_minmax_coredump' defined but not used [-Wunused-function]
1177 | static int proc_dointvec_minmax_coredump(struct ctl_table *table, int write,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
kernel/sysctl.c:1156:12: warning: 'proc_dopipe_max_size' defined but not used [-Wunused-function]
1156 | static int proc_dopipe_max_size(struct ctl_table *table, int write,
| ^~~~~~~~~~~~~~~~~~~~
kernel/sysctl.c:931:12: warning: 'proc_dointvec_minmax_sysadmin' defined but not used [-Wunused-function]
931 | static int proc_dointvec_minmax_sysadmin(struct ctl_table *table, int write,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
kernel/sysctl.c:891:12: warning: 'proc_taint' defined but not used [-Wunused-function]
891 | static int proc_taint(struct ctl_table *table, int write,
| ^~~~~~~~~~
kernel/sysctl.c:128:18: warning: 'cap_last_cap' defined but not used [-Wunused-const-variable=]
128 | static const int cap_last_cap = CAP_LAST_CAP;
| ^~~~~~~~~~~~
kernel/sysctl.c:127:18: warning: 'ngroups_max' defined but not used [-Wunused-const-variable=]
127 | static const int ngroups_max = NGROUPS_MAX;
| ^~~~~~~~~~~
kernel/sysctl.c:125:18: warning: 'minolduid' defined but not used [-Wunused-const-variable=]
125 | static const int minolduid;
| ^~~~~~~~~
kernel/sysctl.c:124:18: warning: 'maxolduid' defined but not used [-Wunused-const-variable=]
124 | static const int maxolduid = 65535;
| ^~~~~~~~~
kernel/sysctl.c:121:28: warning: 'dirty_bytes_min' defined but not used [-Wunused-const-variable=]
121 | static const unsigned long dirty_bytes_min = 2 * PAGE_SIZE;
| ^~~~~~~~~~~~~~~
kernel/sysctl.c:114:18: warning: 'ten_thousand' defined but not used [-Wunused-const-variable=]
114 | static const int ten_thousand = 10000;
| ^~~~~~~~~~~~
kernel/sysctl.c:112:28: warning: 'long_max' defined but not used [-Wunused-const-variable=]
112 | static const unsigned long long_max = LONG_MAX;
| ^~~~~~~~
kernel/sysctl.c:111:28: warning: 'one_ul' defined but not used [-Wunused-const-variable=]
111 | static const unsigned long one_ul = 1;
| ^~~~~~
kernel/sysctl.c:110:28: warning: 'zero_ul' defined but not used [-Wunused-const-variable=]
110 | static const unsigned long zero_ul;
| ^~~~~~~
vim +1772 kernel/sysctl.c
1732
> 1733 #if defined(CONFIG_SYSCTL)
1734 int proc_do_static_key(struct ctl_table *table, int write,
1735 void *buffer, size_t *lenp, loff_t *ppos)
1736 {
1737 struct static_key *key = (struct static_key *)table->data;
1738 static DEFINE_MUTEX(static_key_mutex);
1739 int val, ret;
1740 struct ctl_table tmp = {
1741 .data = &val,
1742 .maxlen = sizeof(val),
1743 .mode = table->mode,
1744 .extra1 = SYSCTL_ZERO,
1745 .extra2 = SYSCTL_ONE,
1746 };
1747
1748 if (write && !capable(CAP_SYS_ADMIN))
1749 return -EPERM;
1750
1751 mutex_lock(&static_key_mutex);
1752 val = static_key_enabled(key);
1753 ret = proc_dointvec_minmax(&tmp, write, buffer, lenp, ppos);
1754 if (write && !ret) {
1755 if (val)
1756 static_key_enable(key);
1757 else
1758 static_key_disable(key);
1759 }
1760 mutex_unlock(&static_key_mutex);
1761 return ret;
1762 }
1763
1764 static struct ctl_table kern_table[] = {
1765 {
1766 .procname = "sched_child_runs_first",
1767 .data = &sysctl_sched_child_runs_first,
1768 .maxlen = sizeof(unsigned int),
1769 .mode = 0644,
1770 .proc_handler = proc_dointvec,
> 1771 },
> 1772 #ifdef CONFIG_SCHED_DEBUG
1773 {
1774 .procname = "sched_min_granularity_ns",
1775 .data = &sysctl_sched_min_granularity,
1776 .maxlen = sizeof(unsigned int),
1777 .mode = 0644,
1778 .proc_handler = sched_proc_update_handler,
1779 .extra1 = (void *)&min_sched_granularity_ns,
1780 .extra2 = (void *)&max_sched_granularity_ns,
1781 },
1782 {
1783 .procname = "sched_latency_ns",
1784 .data = &sysctl_sched_latency,
1785 .maxlen = sizeof(unsigned int),
1786 .mode = 0644,
1787 .proc_handler = sched_proc_update_handler,
1788 .extra1 = (void *)&min_sched_granularity_ns,
1789 .extra2 = (void *)&max_sched_granularity_ns,
1790 },
1791 {
1792 .procname = "sched_wakeup_granularity_ns",
1793 .data = &sysctl_sched_wakeup_granularity,
1794 .maxlen = sizeof(unsigned int),
1795 .mode = 0644,
1796 .proc_handler = sched_proc_update_handler,
1797 .extra1 = (void *)&min_wakeup_granularity_ns,
1798 .extra2 = (void *)&max_wakeup_granularity_ns,
1799 },
1800 #ifdef CONFIG_SMP
1801 {
1802 .procname = "sched_tunable_scaling",
1803 .data = &sysctl_sched_tunable_scaling,
1804 .maxlen = sizeof(enum sched_tunable_scaling),
1805 .mode = 0644,
1806 .proc_handler = sched_proc_update_handler,
1807 .extra1 = (void *)&min_sched_tunable_scaling,
1808 .extra2 = (void *)&max_sched_tunable_scaling,
1809 },
1810 {
1811 .procname = "sched_migration_cost_ns",
1812 .data = &sysctl_sched_migration_cost,
1813 .maxlen = sizeof(unsigned int),
1814 .mode = 0644,
1815 .proc_handler = proc_dointvec,
1816 },
1817 {
1818 .procname = "sched_nr_migrate",
1819 .data = &sysctl_sched_nr_migrate,
1820 .maxlen = sizeof(unsigned int),
1821 .mode = 0644,
1822 .proc_handler = proc_dointvec,
1823 },
1824 #ifdef CONFIG_SCHEDSTATS
1825 {
1826 .procname = "sched_schedstats",
1827 .data = NULL,
1828 .maxlen = sizeof(unsigned int),
1829 .mode = 0644,
1830 .proc_handler = sysctl_schedstats,
1831 .extra1 = SYSCTL_ZERO,
1832 .extra2 = SYSCTL_ONE,
1833 },
1834 #endif /* CONFIG_SCHEDSTATS */
1835 #ifdef CONFIG_TASK_DELAY_ACCT
1836 {
1837 .procname = "task_delayacct",
1838 .data = NULL,
1839 .maxlen = sizeof(unsigned int),
1840 .mode = 0644,
1841 .proc_handler = sysctl_delayacct,
1842 .extra1 = SYSCTL_ZERO,
1843 .extra2 = SYSCTL_ONE,
1844 },
1845 #endif /* CONFIG_TASK_DELAY_ACCT */
1846 #ifdef CONFIG_NUMA_BALANCING
1847 {
1848 .procname = "numa_balancing",
1849 .data = NULL, /* filled in by handler */
1850 .maxlen = sizeof(unsigned int),
1851 .mode = 0644,
1852 .proc_handler = sysctl_numa_balancing,
1853 .extra1 = SYSCTL_ZERO,
1854 .extra2 = SYSCTL_ONE,
1855 },
1856 #endif /* CONFIG_NUMA_BALANCING */
1857 {
1858 .procname = "sched_rt_period_us",
1859 .data = &sysctl_sched_rt_period,
1860 .maxlen = sizeof(unsigned int),
1861 .mode = 0644,
1862 .proc_handler = sched_rt_handler,
1863 },
1864 {
1865 .procname = "sched_rt_runtime_us",
1866 .data = &sysctl_sched_rt_runtime,
1867 .maxlen = sizeof(int),
1868 .mode = 0644,
1869 .proc_handler = sched_rt_handler,
1870 },
1871 {
1872 .procname = "sched_deadline_period_max_us",
1873 .data = &sysctl_sched_dl_period_max,
1874 .maxlen = sizeof(unsigned int),
1875 .mode = 0644,
1876 .proc_handler = proc_dointvec,
1877 },
1878 {
1879 .procname = "sched_deadline_period_min_us",
1880 .data = &sysctl_sched_dl_period_min,
1881 .maxlen = sizeof(unsigned int),
1882 .mode = 0644,
1883 .proc_handler = proc_dointvec,
1884 },
1885 {
1886 .procname = "sched_rr_timeslice_ms",
1887 .data = &sysctl_sched_rr_timeslice,
1888 .maxlen = sizeof(int),
1889 .mode = 0644,
1890 .proc_handler = sched_rr_handler,
1891 },
1892 #ifdef CONFIG_UCLAMP_TASK
1893 {
1894 .procname = "sched_util_clamp_min",
1895 .data = &sysctl_sched_uclamp_util_min,
1896 .maxlen = sizeof(unsigned int),
1897 .mode = 0644,
1898 .proc_handler = sysctl_sched_uclamp_handler,
1899 },
1900 {
1901 .procname = "sched_util_clamp_max",
1902 .data = &sysctl_sched_uclamp_util_max,
1903 .maxlen = sizeof(unsigned int),
1904 .mode = 0644,
1905 .proc_handler = sysctl_sched_uclamp_handler,
1906 },
1907 {
1908 .procname = "sched_util_clamp_min_rt_default",
1909 .data = &sysctl_sched_uclamp_util_min_rt_default,
1910 .maxlen = sizeof(unsigned int),
1911 .mode = 0644,
1912 .proc_handler = sysctl_sched_uclamp_handler,
1913 },
1914 #endif
1915 #ifdef CONFIG_SCHED_AUTOGROUP
1916 {
1917 .procname = "sched_autogroup_enabled",
1918 .data = &sysctl_sched_autogroup_enabled,
1919 .maxlen = sizeof(unsigned int),
1920 .mode = 0644,
1921 .proc_handler = proc_dointvec_minmax,
1922 .extra1 = SYSCTL_ZERO,
1923 .extra2 = SYSCTL_ONE,
1924 },
1925 #endif
1926 #ifdef CONFIG_CFS_BANDWIDTH
1927 {
1928 .procname = "sched_cfs_bandwidth_slice_us",
1929 .data = &sysctl_sched_cfs_bandwidth_slice,
1930 .maxlen = sizeof(unsigned int),
1931 .mode = 0644,
1932 .proc_handler = proc_dointvec_minmax,
1933 .extra1 = SYSCTL_ONE,
1934 },
1935 #endif
1936 #if defined(CONFIG_ENERGY_MODEL) && defined(CONFIG_CPU_FREQ_GOV_SCHEDUTIL)
1937 {
1938 .procname = "sched_energy_aware",
1939 .data = &sysctl_sched_energy_aware,
1940 .maxlen = sizeof(unsigned int),
1941 .mode = 0644,
1942 .proc_handler = sched_energy_aware_handler,
1943 .extra1 = SYSCTL_ZERO,
1944 .extra2 = SYSCTL_ONE,
1945 },
1946 #endif
1947 #ifdef CONFIG_PROVE_LOCKING
1948 {
1949 .procname = "prove_locking",
1950 .data = &prove_locking,
1951 .maxlen = sizeof(int),
1952 .mode = 0644,
1953 .proc_handler = proc_dointvec,
1954 },
1955 #endif
1956 #ifdef CONFIG_LOCK_STAT
1957 {
1958 .procname = "lock_stat",
1959 .data = &lock_stat,
1960 .maxlen = sizeof(int),
1961 .mode = 0644,
1962 .proc_handler = proc_dointvec,
1963 },
1964 #endif
1965 {
1966 .procname = "panic",
1967 .data = &panic_timeout,
1968 .maxlen = sizeof(int),
1969 .mode = 0644,
1970 .proc_handler = proc_dointvec,
1971 },
1972 #ifdef CONFIG_COREDUMP
1973 {
1974 .procname = "core_uses_pid",
1975 .data = &core_uses_pid,
1976 .maxlen = sizeof(int),
1977 .mode = 0644,
1978 .proc_handler = proc_dointvec,
1979 },
1980 {
1981 .procname = "core_pattern",
1982 .data = core_pattern,
1983 .maxlen = CORENAME_MAX_SIZE,
1984 .mode = 0644,
1985 .proc_handler = proc_dostring_coredump,
1986 },
1987 {
1988 .procname = "core_pipe_limit",
1989 .data = &core_pipe_limit,
1990 .maxlen = sizeof(unsigned int),
1991 .mode = 0644,
1992 .proc_handler = proc_dointvec,
1993 },
1994 #endif
1995 #ifdef CONFIG_PROC_SYSCTL
1996 {
1997 .procname = "tainted",
1998 .maxlen = sizeof(long),
1999 .mode = 0644,
2000 .proc_handler = proc_taint,
2001 },
2002 {
2003 .procname = "sysctl_writes_strict",
2004 .data = &sysctl_writes_strict,
2005 .maxlen = sizeof(int),
2006 .mode = 0644,
2007 .proc_handler = proc_dointvec_minmax,
2008 .extra1 = SYSCTL_NEG_ONE,
2009 .extra2 = SYSCTL_ONE,
2010 },
2011 #endif
2012 #ifdef CONFIG_LATENCYTOP
2013 {
2014 .procname = "latencytop",
2015 .data = &latencytop_enabled,
2016 .maxlen = sizeof(int),
2017 .mode = 0644,
2018 .proc_handler = sysctl_latencytop,
2019 },
2020 #endif
2021 #ifdef CONFIG_BLK_DEV_INITRD
2022 {
2023 .procname = "real-root-dev",
2024 .data = &real_root_dev,
2025 .maxlen = sizeof(int),
2026 .mode = 0644,
2027 .proc_handler = proc_dointvec,
2028 },
2029 #endif
2030 {
2031 .procname = "print-fatal-signals",
2032 .data = &print_fatal_signals,
2033 .maxlen = sizeof(int),
2034 .mode = 0644,
2035 .proc_handler = proc_dointvec,
2036 },
2037 #ifdef CONFIG_SPARC
2038 {
2039 .procname = "reboot-cmd",
2040 .data = reboot_command,
2041 .maxlen = 256,
2042 .mode = 0644,
2043 .proc_handler = proc_dostring,
2044 },
2045 {
2046 .procname = "stop-a",
2047 .data = &stop_a_enabled,
2048 .maxlen = sizeof (int),
2049 .mode = 0644,
2050 .proc_handler = proc_dointvec,
2051 },
2052 {
2053 .procname = "scons-poweroff",
2054 .data = &scons_pwroff,
2055 .maxlen = sizeof (int),
2056 .mode = 0644,
2057 .proc_handler = proc_dointvec,
2058 },
2059 #endif
2060 #ifdef CONFIG_SPARC64
2061 {
2062 .procname = "tsb-ratio",
2063 .data = &sysctl_tsb_ratio,
2064 .maxlen = sizeof (int),
2065 .mode = 0644,
2066 .proc_handler = proc_dointvec,
2067 },
2068 #endif
2069 #ifdef CONFIG_PARISC
2070 {
2071 .procname = "soft-power",
2072 .data = &pwrsw_enabled,
2073 .maxlen = sizeof (int),
2074 .mode = 0644,
2075 .proc_handler = proc_dointvec,
2076 },
2077 #endif
2078 #ifdef CONFIG_SYSCTL_ARCH_UNALIGN_ALLOW
2079 {
2080 .procname = "unaligned-trap",
2081 .data = &unaligned_enabled,
2082 .maxlen = sizeof (int),
2083 .mode = 0644,
2084 .proc_handler = proc_dointvec,
2085 },
2086 #endif
2087 {
2088 .procname = "ctrl-alt-del",
2089 .data = &C_A_D,
2090 .maxlen = sizeof(int),
2091 .mode = 0644,
2092 .proc_handler = proc_dointvec,
2093 },
2094 #ifdef CONFIG_FUNCTION_TRACER
2095 {
2096 .procname = "ftrace_enabled",
2097 .data = &ftrace_enabled,
2098 .maxlen = sizeof(int),
2099 .mode = 0644,
2100 .proc_handler = ftrace_enable_sysctl,
2101 },
2102 #endif
2103 #ifdef CONFIG_STACK_TRACER
2104 {
2105 .procname = "stack_tracer_enabled",
2106 .data = &stack_tracer_enabled,
2107 .maxlen = sizeof(int),
2108 .mode = 0644,
2109 .proc_handler = stack_trace_sysctl,
2110 },
2111 #endif
2112 #ifdef CONFIG_TRACING
2113 {
2114 .procname = "ftrace_dump_on_oops",
2115 .data = &ftrace_dump_on_oops,
2116 .maxlen = sizeof(int),
2117 .mode = 0644,
2118 .proc_handler = proc_dointvec,
2119 },
2120 {
2121 .procname = "traceoff_on_warning",
2122 .data = &__disable_trace_on_warning,
2123 .maxlen = sizeof(__disable_trace_on_warning),
2124 .mode = 0644,
2125 .proc_handler = proc_dointvec,
2126 },
2127 {
2128 .procname = "tracepoint_printk",
2129 .data = &tracepoint_printk,
2130 .maxlen = sizeof(tracepoint_printk),
2131 .mode = 0644,
2132 .proc_handler = tracepoint_printk_sysctl,
2133 },
2134 #endif
2135 #ifdef CONFIG_KEXEC_CORE
2136 {
2137 .procname = "kexec_load_disabled",
2138 .data = &kexec_load_disabled,
2139 .maxlen = sizeof(int),
2140 .mode = 0644,
2141 /* only handle a transition from default "0" to "1" */
2142 .proc_handler = proc_dointvec_minmax,
2143 .extra1 = SYSCTL_ONE,
2144 .extra2 = SYSCTL_ONE,
2145 },
2146 #endif
2147 #ifdef CONFIG_MODULES
2148 {
2149 .procname = "modprobe",
2150 .data = &modprobe_path,
2151 .maxlen = KMOD_PATH_LEN,
2152 .mode = 0644,
2153 .proc_handler = proc_dostring,
2154 },
2155 {
2156 .procname = "modules_disabled",
2157 .data = &modules_disabled,
2158 .maxlen = sizeof(int),
2159 .mode = 0644,
2160 /* only handle a transition from default "0" to "1" */
2161 .proc_handler = proc_dointvec_minmax,
2162 .extra1 = SYSCTL_ONE,
2163 .extra2 = SYSCTL_ONE,
2164 },
2165 #endif
2166 #ifdef CONFIG_UEVENT_HELPER
2167 {
2168 .procname = "hotplug",
2169 .data = &uevent_helper,
2170 .maxlen = UEVENT_HELPER_PATH_LEN,
2171 .mode = 0644,
2172 .proc_handler = proc_dostring,
2173 },
2174 #endif
2175 #ifdef CONFIG_CHR_DEV_SG
2176 {
2177 .procname = "sg-big-buff",
2178 .data = &sg_big_buff,
2179 .maxlen = sizeof (int),
2180 .mode = 0444,
2181 .proc_handler = proc_dointvec,
2182 },
2183 #endif
2184 #ifdef CONFIG_BSD_PROCESS_ACCT
2185 {
2186 .procname = "acct",
2187 .data = &acct_parm,
2188 .maxlen = 3*sizeof(int),
2189 .mode = 0644,
2190 .proc_handler = proc_dointvec,
2191 },
2192 #endif
2193 #ifdef CONFIG_MAGIC_SYSRQ
2194 {
2195 .procname = "sysrq",
2196 .data = NULL,
2197 .maxlen = sizeof (int),
2198 .mode = 0644,
2199 .proc_handler = sysrq_sysctl_handler,
2200 },
2201 #endif
2202 #ifdef CONFIG_PROC_SYSCTL
2203 {
2204 .procname = "cad_pid",
2205 .data = NULL,
2206 .maxlen = sizeof (int),
2207 .mode = 0600,
2208 .proc_handler = proc_do_cad_pid,
2209 },
2210 #endif
2211 {
2212 .procname = "threads-max",
2213 .data = NULL,
2214 .maxlen = sizeof(int),
2215 .mode = 0644,
2216 .proc_handler = sysctl_max_threads,
2217 },
2218 {
2219 .procname = "random",
2220 .mode = 0555,
2221 .child = random_table,
2222 },
2223 {
2224 .procname = "usermodehelper",
2225 .mode = 0555,
2226 .child = usermodehelper_table,
2227 },
2228 #ifdef CONFIG_FW_LOADER_USER_HELPER
2229 {
2230 .procname = "firmware_config",
2231 .mode = 0555,
2232 .child = firmware_config_table,
2233 },
2234 #endif
2235 {
2236 .procname = "overflowuid",
2237 .data = &overflowuid,
2238 .maxlen = sizeof(int),
2239 .mode = 0644,
2240 .proc_handler = proc_dointvec_minmax,
2241 .extra1 = (void *)&minolduid,
2242 .extra2 = (void *)&maxolduid,
2243 },
2244 {
2245 .procname = "overflowgid",
2246 .data = &overflowgid,
2247 .maxlen = sizeof(int),
2248 .mode = 0644,
2249 .proc_handler = proc_dointvec_minmax,
2250 .extra1 = (void *)&minolduid,
2251 .extra2 = (void *)&maxolduid,
2252 },
2253 #ifdef CONFIG_S390
2254 {
2255 .procname = "userprocess_debug",
2256 .data = &show_unhandled_signals,
2257 .maxlen = sizeof(int),
2258 .mode = 0644,
2259 .proc_handler = proc_dointvec,
2260 },
2261 #endif
2262 #ifdef CONFIG_SMP
2263 {
2264 .procname = "oops_all_cpu_backtrace",
2265 .data = &sysctl_oops_all_cpu_backtrace,
2266 .maxlen = sizeof(int),
2267 .mode = 0644,
2268 .proc_handler = proc_dointvec_minmax,
2269 .extra1 = SYSCTL_ZERO,
2270 .extra2 = SYSCTL_ONE,
2271 },
2272 #endif /* CONFIG_SMP */
2273 {
2274 .procname = "pid_max",
2275 .data = &pid_max,
2276 .maxlen = sizeof (int),
2277 .mode = 0644,
2278 .proc_handler = proc_dointvec_minmax,
2279 .extra1 = &pid_max_min,
2280 .extra2 = &pid_max_max,
2281 },
2282 {
2283 .procname = "panic_on_oops",
2284 .data = &panic_on_oops,
2285 .maxlen = sizeof(int),
2286 .mode = 0644,
2287 .proc_handler = proc_dointvec,
2288 },
2289 {
2290 .procname = "panic_print",
2291 .data = &panic_print,
2292 .maxlen = sizeof(unsigned long),
2293 .mode = 0644,
2294 .proc_handler = proc_doulongvec_minmax,
2295 },
2296 #if defined CONFIG_PRINTK
2297 {
2298 .procname = "printk",
2299 .data = &console_loglevel,
2300 .maxlen = 4*sizeof(int),
2301 .mode = 0644,
2302 .proc_handler = proc_dointvec,
2303 },
2304 {
2305 .procname = "printk_ratelimit",
2306 .data = &printk_ratelimit_state.interval,
2307 .maxlen = sizeof(int),
2308 .mode = 0644,
2309 .proc_handler = proc_dointvec_jiffies,
2310 },
2311 {
2312 .procname = "printk_ratelimit_burst",
2313 .data = &printk_ratelimit_state.burst,
2314 .maxlen = sizeof(int),
2315 .mode = 0644,
2316 .proc_handler = proc_dointvec,
2317 },
2318 {
2319 .procname = "printk_delay",
2320 .data = &printk_delay_msec,
2321 .maxlen = sizeof(int),
2322 .mode = 0644,
2323 .proc_handler = proc_dointvec_minmax,
2324 .extra1 = SYSCTL_ZERO,
2325 .extra2 = (void *)&ten_thousand,
2326 },
2327 {
2328 .procname = "printk_devkmsg",
2329 .data = devkmsg_log_str,
2330 .maxlen = DEVKMSG_STR_MAX_SIZE,
2331 .mode = 0644,
2332 .proc_handler = devkmsg_sysctl_set_loglvl,
2333 },
2334 {
2335 .procname = "dmesg_restrict",
2336 .data = &dmesg_restrict,
2337 .maxlen = sizeof(int),
2338 .mode = 0644,
2339 .proc_handler = proc_dointvec_minmax_sysadmin,
2340 .extra1 = SYSCTL_ZERO,
2341 .extra2 = SYSCTL_ONE,
2342 },
2343 {
2344 .procname = "kptr_restrict",
2345 .data = &kptr_restrict,
2346 .maxlen = sizeof(int),
2347 .mode = 0644,
2348 .proc_handler = proc_dointvec_minmax_sysadmin,
2349 .extra1 = SYSCTL_ZERO,
2350 .extra2 = SYSCTL_TWO,
2351 },
2352 #endif
2353 {
2354 .procname = "ngroups_max",
2355 .data = (void *)&ngroups_max,
2356 .maxlen = sizeof (int),
2357 .mode = 0444,
2358 .proc_handler = proc_dointvec,
2359 },
2360 {
2361 .procname = "cap_last_cap",
2362 .data = (void *)&cap_last_cap,
2363 .maxlen = sizeof(int),
2364 .mode = 0444,
2365 .proc_handler = proc_dointvec,
2366 },
2367 #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86)
2368 {
2369 .procname = "unknown_nmi_panic",
2370 .data = &unknown_nmi_panic,
2371 .maxlen = sizeof (int),
2372 .mode = 0644,
2373 .proc_handler = proc_dointvec,
2374 },
2375 #endif
2376
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 1 week