linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] ARM: Kconfig: Style cleanups
@ 2022-05-17 14:14 Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments Juerg Haefliger
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Juerg Haefliger @ 2022-05-17 14:14 UTC (permalink / raw)
  To: linux, linux-arm-kernel; +Cc: linux-kernel, Juerg Haefliger

The majority of the Kconfig files use a single tab for basic indentation
and a single tab followed by two whitespaces for help text indentation.
Fix the lines that don't follow this convention.

While at it:
  - Add trailing comments to endif/endmenu statements for better
    readability.
  - CLeanup some stray/extra/erronous tabs and/or single quotes
    and/or whitespaces.

Juerg Haefliger (3):
  ARM: Kconfig: Fix indentation and add comments
  ARM: Kconfig-nommu: Fix indentation and quotes
  ARM: Kconfig.debug: Fix indentation

 arch/arm/Kconfig       | 38 +++++++++++++++++++-------------------
 arch/arm/Kconfig-nommu | 34 +++++++++++++++++-----------------
 arch/arm/Kconfig.debug | 35 +++++++++++++++++------------------
 3 files changed, 53 insertions(+), 54 deletions(-)

-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments
  2022-05-17 14:14 [PATCH 0/3] ARM: Kconfig: Style cleanups Juerg Haefliger
@ 2022-05-17 14:14 ` Juerg Haefliger
  2022-05-17 14:33   ` Russell King (Oracle)
  2022-05-17 14:14 ` [PATCH 2/3] ARM: Kconfig-nommu: Fix indentation and quotes Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 3/3] ARM: Kconfig.debug: Fix indentation Juerg Haefliger
  2 siblings, 1 reply; 6+ messages in thread
From: Juerg Haefliger @ 2022-05-17 14:14 UTC (permalink / raw)
  To: linux, linux-arm-kernel; +Cc: linux-kernel, Juerg Haefliger

The convention for indentation seems to be a single tab. Help text is
further indented by an additional two whitespaces. Fix the lines that
violate these rules.

While add it, add trailing comments to endif and endmenu statements for
better readability.

Signed-off-by: Juerg Haefliger <juergh@canonical.com>
---
 arch/arm/Kconfig | 38 +++++++++++++++++++-------------------
 1 file changed, 19 insertions(+), 19 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 2e8091e2d8a8..912716c99c82 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -181,7 +181,7 @@ config ARM_DMA_IOMMU_ALIGNMENT
 	  specified order. The order is expressed as a power of two multiplied
 	  by the PAGE_SIZE.
 
-endif
+endif # ARM_DMA_USE_IOMMU
 
 config SYS_SUPPORTS_APM_EMULATION
 	bool
@@ -549,7 +549,7 @@ config ARCH_MULTI_CPU_AUTO
 	def_bool !(ARCH_MULTI_V4 || ARCH_MULTI_V4T || ARCH_MULTI_V6_V7)
 	select ARCH_MULTI_V5
 
-endmenu
+endmenu # "Multiple platform selection"
 
 config ARCH_VIRT
 	bool "Dummy Virtual Machine"
@@ -771,7 +771,7 @@ config IWMMXT
 
 if !MMU
 source "arch/arm/Kconfig-nommu"
-endif
+endif # !MMU
 
 config PJ4B_ERRATA_4742
 	bool "PJ4B Errata 4742: IDLE Wake Up Commands can Cause the CPU Core to Cease Operation"
@@ -973,14 +973,14 @@ config ARM_ERRATA_764369
 	  in the diagnostic control register of the SCU.
 
 config ARM_ERRATA_775420
-       bool "ARM errata: A data cache maintenance operation which aborts, might lead to deadlock"
-       depends on CPU_V7
-       help
-	 This option enables the workaround for the 775420 Cortex-A9 (r2p2,
-	 r2p6,r2p8,r2p10,r3p0) erratum. In case a data cache maintenance
-	 operation aborts with MMU exception, it might cause the processor
-	 to deadlock. This workaround puts DSB before executing ISB if
-	 an abort may occur on cache maintenance.
+	bool "ARM errata: A data cache maintenance operation which aborts, might lead to deadlock"
+	depends on CPU_V7
+	help
+	  This option enables the workaround for the 775420 Cortex-A9 (r2p2,
+	  r2p6,r2p8,r2p10,r3p0) erratum. In case a data cache maintenance
+	  operation aborts with MMU exception, it might cause the processor
+	  to deadlock. This workaround puts DSB before executing ISB if
+	  an abort may occur on cache maintenance.
 
 config ARM_ERRATA_798181
 	bool "ARM errata: TLBI/DSB failure on Cortex-A15"
@@ -1073,7 +1073,7 @@ config ARM_ERRATA_857272
 	  config option from the A12 erratum due to the way errata are checked
 	  for and handled.
 
-endmenu
+endmenu # "System Type"
 
 source "arch/arm/common/Kconfig"
 
@@ -1115,7 +1115,7 @@ config ARM_ERRATA_814220
 	  This ERRATA only affected the Cortex-A7 and present in r0p2, r0p3,
 	  r0p4, r0p5.
 
-endmenu
+endmenu # "Bus support"
 
 menu "Kernel Features"
 
@@ -1631,7 +1631,7 @@ config STACKPROTECTOR_PER_TASK
 	  Enable this option to switch to a different method that uses a
 	  different canary value for each task.
 
-endmenu
+endmenu # "Kernel Features"
 
 menu "Boot options"
 
@@ -1903,7 +1903,7 @@ config DMI
 	  firmware need to be enabled. This would require the DMI subsystem
 	  to be enabled much earlier than we do on ARM, which is non-trivial.
 
-endmenu
+endmenu # "Boot options"
 
 menu "CPU Power Management"
 
@@ -1911,7 +1911,7 @@ source "drivers/cpufreq/Kconfig"
 
 source "drivers/cpuidle/Kconfig"
 
-endmenu
+endmenu # "CPU Power Management"
 
 menu "Floating point emulation"
 
@@ -1985,7 +1985,7 @@ config KERNEL_MODE_NEON
 	help
 	  Say Y to include support for NEON in kernel mode.
 
-endmenu
+endmenu # "Floating point emulation"
 
 menu "Power management options"
 
@@ -2005,10 +2005,10 @@ config ARCH_HIBERNATION_POSSIBLE
 	depends on MMU
 	default y if ARCH_SUSPEND_POSSIBLE
 
-endmenu
+endmenu # "Power management options"
 
 if CRYPTO
 source "arch/arm/crypto/Kconfig"
-endif
+endif # CRYPTO
 
 source "arch/arm/Kconfig.assembler"
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/3] ARM: Kconfig-nommu: Fix indentation and quotes
  2022-05-17 14:14 [PATCH 0/3] ARM: Kconfig: Style cleanups Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments Juerg Haefliger
@ 2022-05-17 14:14 ` Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 3/3] ARM: Kconfig.debug: Fix indentation Juerg Haefliger
  2 siblings, 0 replies; 6+ messages in thread
From: Juerg Haefliger @ 2022-05-17 14:14 UTC (permalink / raw)
  To: linux, linux-arm-kernel; +Cc: linux-kernel, Juerg Haefliger

The convention for indentation seems to be a single tab. Help text is
further indented by an additional two whitespaces. Fix the lines that
violate these rules.

While add it, replace single quotes with double-quotes.

Signed-off-by: Juerg Haefliger <juergh@canonical.com>
---
 arch/arm/Kconfig-nommu | 34 +++++++++++++++++-----------------
 1 file changed, 17 insertions(+), 17 deletions(-)

diff --git a/arch/arm/Kconfig-nommu b/arch/arm/Kconfig-nommu
index 36c80d3dd93f..5bc1b6d6526b 100644
--- a/arch/arm/Kconfig-nommu
+++ b/arch/arm/Kconfig-nommu
@@ -7,29 +7,29 @@
 config SET_MEM_PARAM
 	bool "Set flash/sdram size and base addr"
 	help
-	 Say Y to manually set the base addresses and sizes.
-	 otherwise, the default values are assigned.
+	  Say Y to manually set the base addresses and sizes.
+	  otherwise, the default values are assigned.
 
 config DRAM_BASE
-	hex '(S)DRAM Base Address' if SET_MEM_PARAM
+	hex "(S)DRAM Base Address" if SET_MEM_PARAM
 	default 0x00800000
 
 config DRAM_SIZE
-	hex '(S)DRAM SIZE' if SET_MEM_PARAM
+	hex "(S)DRAM SIZE" if SET_MEM_PARAM
 	default 0x00800000
 
 config FLASH_MEM_BASE
-	hex 'FLASH Base Address' if SET_MEM_PARAM
+	hex "FLASH Base Address" if SET_MEM_PARAM
 	depends on CPU_ARM740T || CPU_ARM946E || CPU_ARM940T
 	default 0x00400000
 
 config FLASH_SIZE
-	hex 'FLASH Size' if SET_MEM_PARAM
+	hex "FLASH Size" if SET_MEM_PARAM
 	depends on CPU_ARM740T || CPU_ARM946E || CPU_ARM940T
 	default 0x00400000
 
 config PROCESSOR_ID
-	hex 'Hard wire the processor ID'
+	hex "Hard wire the processor ID"
 	default 0x00007700
 	depends on !(CPU_CP15 || CPU_V7M)
 	help
@@ -37,7 +37,7 @@ config PROCESSOR_ID
 	  used instead of the auto-probing which utilizes the register.
 
 config REMAP_VECTORS_TO_RAM
-	bool 'Install vectors to the beginning of RAM'
+	bool "Install vectors to the beginning of RAM"
 	help
 	  The kernel needs to change the hardware exception vectors.
 	  In nommu mode, the hardware exception vectors are normally
@@ -54,13 +54,13 @@ config REMAP_VECTORS_TO_RAM
 	  the writable versions located at DRAM_BASE.
 
 config ARM_MPU
-       bool 'Use the ARM v7 PMSA Compliant MPU'
-       depends on CPU_V7 || CPU_V7M
-       default y if CPU_V7
-       help
-         Some ARM systems without an MMU have instead a Memory Protection
-         Unit (MPU) that defines the type and permissions for regions of
-         memory.
+	bool "Use the ARM v7 PMSA Compliant MPU"
+	depends on CPU_V7 || CPU_V7M
+	default y if CPU_V7
+	help
+	  Some ARM systems without an MMU have instead a Memory Protection
+	  Unit (MPU) that defines the type and permissions for regions of
+	  memory.
 
-         If your CPU has an MPU then you should choose 'y' here unless you
-         know that you do not want to use the MPU.
+	  If your CPU has an MPU then you should choose 'y' here unless you
+	  know that you do not want to use the MPU.
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/3] ARM: Kconfig.debug: Fix indentation
  2022-05-17 14:14 [PATCH 0/3] ARM: Kconfig: Style cleanups Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments Juerg Haefliger
  2022-05-17 14:14 ` [PATCH 2/3] ARM: Kconfig-nommu: Fix indentation and quotes Juerg Haefliger
@ 2022-05-17 14:14 ` Juerg Haefliger
  2 siblings, 0 replies; 6+ messages in thread
From: Juerg Haefliger @ 2022-05-17 14:14 UTC (permalink / raw)
  To: linux, linux-arm-kernel; +Cc: linux-kernel, Juerg Haefliger

The convention for indentation seems to be a single tab. Help text is
further indented by an additional two whitespaces. Fix the lines that
violate these rules.

Signed-off-by: Juerg Haefliger <juergh@canonical.com>
---
 arch/arm/Kconfig.debug | 35 +++++++++++++++++------------------
 1 file changed, 17 insertions(+), 18 deletions(-)

diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 0c9497d549e3..4b00b1fd9ab3 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -22,28 +22,28 @@ config DEBUG_WX
 	depends on MMU
 	select ARM_PTDUMP_CORE
 	help
-		Generate a warning if any W+X mappings are found at boot.
+	  Generate a warning if any W+X mappings are found at boot.
 
-		This is useful for discovering cases where the kernel is leaving
-		W+X mappings after applying NX, as such mappings are a security risk.
+	  This is useful for discovering cases where the kernel is leaving
+	  W+X mappings after applying NX, as such mappings are a security risk.
 
-		Look for a message in dmesg output like this:
+	  Look for a message in dmesg output like this:
 
-			arm/mm: Checked W+X mappings: passed, no W+X pages found.
+		arm/mm: Checked W+X mappings: passed, no W+X pages found.
 
-		or like this, if the check failed:
+	  or like this, if the check failed:
 
-			arm/mm: Checked W+X mappings: FAILED, <N> W+X pages found.
+		arm/mm: Checked W+X mappings: FAILED, <N> W+X pages found.
 
-		Note that even if the check fails, your kernel is possibly
-		still fine, as W+X mappings are not a security hole in
-		themselves, what they do is that they make the exploitation
-		of other unfixed kernel bugs easier.
+	  Note that even if the check fails, your kernel is possibly
+	  still fine, as W+X mappings are not a security hole in
+	  themselves, what they do is that they make the exploitation
+	  of other unfixed kernel bugs easier.
 
-		There is no runtime or memory usage effect of this option
-		once the kernel has booted up - it's a one time check.
+	  There is no runtime or memory usage effect of this option
+	  once the kernel has booted up - it's a one time check.
 
-		If in doubt, say "Y".
+	  If in doubt, say "Y".
 
 choice
 	prompt "Choose kernel unwinder"
@@ -293,7 +293,7 @@ choice
 		select DEBUG_UART_8250
 		help
 		  Say Y here if you want the debug print routines to direct
-                  their output to the CNS3xxx UART0.
+		  their output to the CNS3xxx UART0.
 
 	config DEBUG_DAVINCI_DA8XX_UART1
 		bool "Kernel low-level debugging on DaVinci DA8XX using UART1"
@@ -847,7 +847,7 @@ choice
 		select DEBUG_UART_8250
 		help
 		  Say Y here if you want kernel low-level debugging support
-                  on Rockchip RV1108 based platforms.
+		  on Rockchip RV1108 based platforms.
 
 	config DEBUG_RV1108_UART1
 		bool "Kernel low-level debugging messages via Rockchip RV1108 UART1"
@@ -1724,7 +1724,7 @@ config DEBUG_UART_PHYS
 	default 0xffffee00 if DEBUG_AT91_SAM9263_DBGU
 	default 0xfffff200 if DEBUG_AT91_RM9200_DBGU
 	depends on ARCH_EP93XX || \
-	        DEBUG_LL_UART_8250 || DEBUG_LL_UART_PL01X || \
+		DEBUG_LL_UART_8250 || DEBUG_LL_UART_PL01X || \
 		DEBUG_UART_8250 || DEBUG_UART_PL01X || DEBUG_MESON_UARTAO || \
 		DEBUG_QCOM_UARTDM || DEBUG_R7S72100_SCIF2 || \
 		DEBUG_R7S9210_SCIF2 || DEBUG_R7S9210_SCIF4 || \
@@ -1895,7 +1895,6 @@ config DEBUG_UNCOMPRESS
 	  When this option is set, the selected DEBUG_LL output method
 	  will be re-used for normal decompressor output on multiplatform
 	  kernels.
-	  
 
 config UNCOMPRESS_INCLUDE
 	string
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments
  2022-05-17 14:14 ` [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments Juerg Haefliger
@ 2022-05-17 14:33   ` Russell King (Oracle)
  2022-05-18  6:43     ` [PATCH v2 1/3] ARM: Kconfig: Fix indentation Juerg Haefliger
  0 siblings, 1 reply; 6+ messages in thread
From: Russell King (Oracle) @ 2022-05-17 14:33 UTC (permalink / raw)
  To: Juerg Haefliger; +Cc: linux-arm-kernel, linux-kernel, Juerg Haefliger

Hi,

On Tue, May 17, 2022 at 04:14:22PM +0200, Juerg Haefliger wrote:
> The convention for indentation seems to be a single tab. Help text is
> further indented by an additional two whitespaces. Fix the lines that
> violate these rules.
> 
> While add it, add trailing comments to endif and endmenu statements for
> better readability.

I have never been a fan of that practice, but I understand that some
people really like it. At the end of the day, it's subjective, so
let's leave it as-is for the time being.

The other changes are worth having though. Please send a patch making
just those changes.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v2 1/3] ARM: Kconfig: Fix indentation
  2022-05-17 14:33   ` Russell King (Oracle)
@ 2022-05-18  6:43     ` Juerg Haefliger
  0 siblings, 0 replies; 6+ messages in thread
From: Juerg Haefliger @ 2022-05-18  6:43 UTC (permalink / raw)
  To: linux, linux-arm-kernel; +Cc: linux-kernel, Juerg Haefliger

The convention for indentation seems to be a single tab. Help text is
further indented by an additional two whitespaces. Fix the lines that
violate these rules.

Signed-off-by: Juerg Haefliger <juergh@canonical.com>

---
v2:
  Drop endif/endmenu trailing comments.
---
 arch/arm/Kconfig | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 2e8091e2d8a8..e93653709f07 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -973,14 +973,14 @@ config ARM_ERRATA_764369
 	  in the diagnostic control register of the SCU.
 
 config ARM_ERRATA_775420
-       bool "ARM errata: A data cache maintenance operation which aborts, might lead to deadlock"
-       depends on CPU_V7
-       help
-	 This option enables the workaround for the 775420 Cortex-A9 (r2p2,
-	 r2p6,r2p8,r2p10,r3p0) erratum. In case a data cache maintenance
-	 operation aborts with MMU exception, it might cause the processor
-	 to deadlock. This workaround puts DSB before executing ISB if
-	 an abort may occur on cache maintenance.
+	bool "ARM errata: A data cache maintenance operation which aborts, might lead to deadlock"
+	depends on CPU_V7
+	help
+	  This option enables the workaround for the 775420 Cortex-A9 (r2p2,
+	  r2p6,r2p8,r2p10,r3p0) erratum. In case a data cache maintenance
+	  operation aborts with MMU exception, it might cause the processor
+	  to deadlock. This workaround puts DSB before executing ISB if
+	  an abort may occur on cache maintenance.
 
 config ARM_ERRATA_798181
 	bool "ARM errata: TLBI/DSB failure on Cortex-A15"
-- 
2.32.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-05-18  6:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-17 14:14 [PATCH 0/3] ARM: Kconfig: Style cleanups Juerg Haefliger
2022-05-17 14:14 ` [PATCH 1/3] ARM: Kconfig: Fix indentation and add comments Juerg Haefliger
2022-05-17 14:33   ` Russell King (Oracle)
2022-05-18  6:43     ` [PATCH v2 1/3] ARM: Kconfig: Fix indentation Juerg Haefliger
2022-05-17 14:14 ` [PATCH 2/3] ARM: Kconfig-nommu: Fix indentation and quotes Juerg Haefliger
2022-05-17 14:14 ` [PATCH 3/3] ARM: Kconfig.debug: Fix indentation Juerg Haefliger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).