public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: rts5208: Fix coding style issues
@ 2024-01-18 14:42 Jacob Lott
  2024-01-18 14:51 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: Jacob Lott @ 2024-01-18 14:42 UTC (permalink / raw)
  To: gregkh, linux-staging, linux-kernel, wei_wang, micky_ching; +Cc: jklott.git

Help text in a module should describe the module and give
some guidance on whether or not to enable it.

The BIT macro should be used instead of 1UL << n. This
makes the code more readable and easier to maintain.

Signed-off-by: Jacob Lott <jklott.git@gmail.com>
---
  drivers/staging/rts5208/Kconfig     | 10 +++++++---
  drivers/staging/rts5208/rtsx_card.h |  4 ++--
  2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/rts5208/Kconfig 
b/drivers/staging/rts5208/Kconfig
index b864023d3ccb..bb293cbf6230 100644
--- a/drivers/staging/rts5208/Kconfig
+++ b/drivers/staging/rts5208/Kconfig
@@ -3,7 +3,11 @@ config RTS5208
         tristate "Realtek PCI-E Card Reader RTS5208/5288 support"
         depends on PCI && SCSI
         help
-         Say Y here to include driver code to support the Realtek
-         PCI-E card reader rts5208/rts5288.
+      Choose Y here to enable support for the Realtek PCI-E card reader 
RTS5208/5288.
+         This driver facilitates communication between the Linux kernel 
and the Realtek
+         PCI-E card reader.

-         If this driver is compiled as a module, it will be named rts5208.
+         If you opt to compile this driver as a module, it will be 
named rts5208. Selecting
+         N will exclude this driver from the kernel build. Choose 
option Y if your system includes
+         the Realtek PCI-E card reader rts5208/rts5288. When in doubt, 
it is generally safe
+         to select N.
diff --git a/drivers/staging/rts5208/rtsx_card.h 
b/drivers/staging/rts5208/rtsx_card.h
index 39727371cd7a..9d2504fddb13 100644
--- a/drivers/staging/rts5208/rtsx_card.h
+++ b/drivers/staging/rts5208/rtsx_card.h
@@ -338,7 +338,7 @@
  #define DMA_DIR_FROM_CARD              0x02
  #define DMA_EN                         0x01
  #define DMA_128                                (0 << 4)
-#define DMA_256                                (1 << 4)
+#define DMA_256                                BIT(4)
  #define DMA_512                                (2 << 4)
  #define DMA_1024                       (3 << 4)
  #define DMA_PACK_SIZE_MASK             0x30
@@ -542,7 +542,7 @@

  #define BLINK_EN                       0x08
  #define LED_GPIO0                      (0 << 4)
-#define LED_GPIO1                      (1 << 4)
+#define LED_GPIO1                      BIT(4)
  #define LED_GPIO2                      (2 << 4)

  #define SDIO_BUS_CTRL          0x01
-- 
2.34.1


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

end of thread, other threads:[~2024-01-18 14:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-18 14:42 [PATCH] staging: rts5208: Fix coding style issues Jacob Lott
2024-01-18 14:51 ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox