All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] pwm: th1520: use vertical import style
@ 2026-07-06  2:52 ` Guru Das Srinagesh
  0 siblings, 0 replies; 4+ messages in thread
From: Guru Das Srinagesh @ 2026-07-06  2:52 UTC (permalink / raw)
  To: Michal Wilczynski, Drew Fustini, Guo Ren, Fu Wei,
	Uwe Kleine-König, Miguel Ojeda, Boqun Feng, Gary Guo,
	Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
	Trevor Gross, Danilo Krummrich, Daniel Almeida, Tamir Duberstein,
	Alexandre Courbot, Onur Özkan, Nathan Chancellor,
	Nick Desaulniers, Bill Wendling, Justin Stitt
  Cc: linux-riscv, linux-pwm, linux-kernel, rust-for-linux, llvm,
	Guru Das Srinagesh

Convert `use` imports to vertical layout for better readability and
maintainability.

Signed-off-by: Guru Das Srinagesh <linux@gurudas.dev>
---
Came across a recent commit bc58905eb07 ("samples: rust_misc_device: use
vertical import style") and found a few more locations that could
benefit from this cleanup. No functional changes.

Separating out patches per-subsystem as per the review feedback in [0].

Tested via:

    $ make LLVM=1 rustfmtcheck || echo "fail"
    $

[0]: https://lore.kernel.org/lkml/20260628-b4-rust-vertical-imports-v1-0-98bc71d4810b@gurudas.dev/
---
 drivers/pwm/pwm_th1520.rs | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/drivers/pwm/pwm_th1520.rs b/drivers/pwm/pwm_th1520.rs
index 3e3fa51ccef9..2a3b107157ac 100644
--- a/drivers/pwm/pwm_th1520.rs
+++ b/drivers/pwm/pwm_th1520.rs
@@ -23,15 +23,21 @@
 use core::ops::Deref;
 use kernel::{
     clk::Clk,
-    device::{Bound, Core, Device},
+    device::{
+        Bound,
+        Core,
+        Device, //
+    },
     devres,
     io::{
         mem::IoMem,
         Io, //
     },
-    of, platform,
+    of,
+    platform, //
     prelude::*,
-    pwm, time,
+    pwm,
+    time, //
 };
 
 const TH1520_MAX_PWM_NUM: u32 = 6;

---
base-commit: 1a4920940ebfd8d907858abd8f8dd09b13752946
change-id: 20260705-pwm-rust-vert-imp-59a3d18bd0cf

Best regards,
--  
Guru Das Srinagesh <linux@gurudas.dev>


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

* [PATCH] pwm: th1520: use vertical import style
@ 2026-07-06  2:52 ` Guru Das Srinagesh
  0 siblings, 0 replies; 4+ messages in thread
From: Guru Das Srinagesh @ 2026-07-06  2:52 UTC (permalink / raw)
  To: Michal Wilczynski, Drew Fustini, Guo Ren, Fu Wei,
	Uwe Kleine-König, Miguel Ojeda, Boqun Feng, Gary Guo,
	Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
	Trevor Gross, Danilo Krummrich, Daniel Almeida, Tamir Duberstein,
	Alexandre Courbot, Onur Özkan, Nathan Chancellor,
	Nick Desaulniers, Bill Wendling, Justin Stitt
  Cc: linux-riscv, linux-pwm, linux-kernel, rust-for-linux, llvm,
	Guru Das Srinagesh

Convert `use` imports to vertical layout for better readability and
maintainability.

Signed-off-by: Guru Das Srinagesh <linux@gurudas.dev>
---
Came across a recent commit bc58905eb07 ("samples: rust_misc_device: use
vertical import style") and found a few more locations that could
benefit from this cleanup. No functional changes.

Separating out patches per-subsystem as per the review feedback in [0].

Tested via:

    $ make LLVM=1 rustfmtcheck || echo "fail"
    $

[0]: https://lore.kernel.org/lkml/20260628-b4-rust-vertical-imports-v1-0-98bc71d4810b@gurudas.dev/
---
 drivers/pwm/pwm_th1520.rs | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/drivers/pwm/pwm_th1520.rs b/drivers/pwm/pwm_th1520.rs
index 3e3fa51ccef9..2a3b107157ac 100644
--- a/drivers/pwm/pwm_th1520.rs
+++ b/drivers/pwm/pwm_th1520.rs
@@ -23,15 +23,21 @@
 use core::ops::Deref;
 use kernel::{
     clk::Clk,
-    device::{Bound, Core, Device},
+    device::{
+        Bound,
+        Core,
+        Device, //
+    },
     devres,
     io::{
         mem::IoMem,
         Io, //
     },
-    of, platform,
+    of,
+    platform, //
     prelude::*,
-    pwm, time,
+    pwm,
+    time, //
 };
 
 const TH1520_MAX_PWM_NUM: u32 = 6;

---
base-commit: 1a4920940ebfd8d907858abd8f8dd09b13752946
change-id: 20260705-pwm-rust-vert-imp-59a3d18bd0cf

Best regards,
--  
Guru Das Srinagesh <linux@gurudas.dev>


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

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

* Re: [PATCH] pwm: th1520: use vertical import style
  2026-07-06  2:52 ` Guru Das Srinagesh
@ 2026-07-08  7:39   ` Link Mauve
  -1 siblings, 0 replies; 4+ messages in thread
From: Link Mauve @ 2026-07-08  7:39 UTC (permalink / raw)
  To: Guru Das Srinagesh
  Cc: Michal Wilczynski, Drew Fustini, Guo Ren, Fu Wei,
	Uwe Kleine-König, Miguel Ojeda, Boqun Feng, Gary Guo,
	Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
	Trevor Gross, Danilo Krummrich, Daniel Almeida, Tamir Duberstein,
	Alexandre Courbot, Onur Özkan, Nathan Chancellor,
	Nick Desaulniers, Bill Wendling, Justin Stitt, linux-riscv,
	linux-pwm, linux-kernel, rust-for-linux, llvm

On Sun, Jul 05, 2026 at 07:52:05PM -0700, Guru Das Srinagesh wrote:
> Convert `use` imports to vertical layout for better readability and
> maintainability.
> 
> Signed-off-by: Guru Das Srinagesh <linux@gurudas.dev>
> ---
> Came across a recent commit bc58905eb07 ("samples: rust_misc_device: use
> vertical import style") and found a few more locations that could
> benefit from this cleanup. No functional changes.
> 
> Separating out patches per-subsystem as per the review feedback in [0].
> 
> Tested via:
> 
>     $ make LLVM=1 rustfmtcheck || echo "fail"
>     $
> 
> [0]: https://lore.kernel.org/lkml/20260628-b4-rust-vertical-imports-v1-0-98bc71d4810b@gurudas.dev/
> ---
>  drivers/pwm/pwm_th1520.rs | 12 +++++++++---
>  1 file changed, 9 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/pwm/pwm_th1520.rs b/drivers/pwm/pwm_th1520.rs
> index 3e3fa51ccef9..2a3b107157ac 100644
> --- a/drivers/pwm/pwm_th1520.rs
> +++ b/drivers/pwm/pwm_th1520.rs
> @@ -23,15 +23,21 @@
>  use core::ops::Deref;
>  use kernel::{
>      clk::Clk,
> -    device::{Bound, Core, Device},
> +    device::{
> +        Bound,
> +        Core,
> +        Device, //
> +    },
>      devres,
>      io::{
>          mem::IoMem,
>          Io, //
>      },
> -    of, platform,
> +    of,
> +    platform, //

Same here, you just need the empty comment after time, not the one after
platform.

>      prelude::*,
> -    pwm, time,
> +    pwm,
> +    time, //
>  };
>  
>  const TH1520_MAX_PWM_NUM: u32 = 6;
> 
> ---
> base-commit: 1a4920940ebfd8d907858abd8f8dd09b13752946
> change-id: 20260705-pwm-rust-vert-imp-59a3d18bd0cf
> 
> Best regards,
> --  
> Guru Das Srinagesh <linux@gurudas.dev>
> 
> 

-- 
Link Mauve

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

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

* Re: [PATCH] pwm: th1520: use vertical import style
@ 2026-07-08  7:39   ` Link Mauve
  0 siblings, 0 replies; 4+ messages in thread
From: Link Mauve @ 2026-07-08  7:39 UTC (permalink / raw)
  To: Guru Das Srinagesh
  Cc: Michal Wilczynski, Drew Fustini, Guo Ren, Fu Wei,
	Uwe Kleine-König, Miguel Ojeda, Boqun Feng, Gary Guo,
	Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
	Trevor Gross, Danilo Krummrich, Daniel Almeida, Tamir Duberstein,
	Alexandre Courbot, Onur Özkan, Nathan Chancellor,
	Nick Desaulniers, Bill Wendling, Justin Stitt, linux-riscv,
	linux-pwm, linux-kernel, rust-for-linux, llvm

On Sun, Jul 05, 2026 at 07:52:05PM -0700, Guru Das Srinagesh wrote:
> Convert `use` imports to vertical layout for better readability and
> maintainability.
> 
> Signed-off-by: Guru Das Srinagesh <linux@gurudas.dev>
> ---
> Came across a recent commit bc58905eb07 ("samples: rust_misc_device: use
> vertical import style") and found a few more locations that could
> benefit from this cleanup. No functional changes.
> 
> Separating out patches per-subsystem as per the review feedback in [0].
> 
> Tested via:
> 
>     $ make LLVM=1 rustfmtcheck || echo "fail"
>     $
> 
> [0]: https://lore.kernel.org/lkml/20260628-b4-rust-vertical-imports-v1-0-98bc71d4810b@gurudas.dev/
> ---
>  drivers/pwm/pwm_th1520.rs | 12 +++++++++---
>  1 file changed, 9 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/pwm/pwm_th1520.rs b/drivers/pwm/pwm_th1520.rs
> index 3e3fa51ccef9..2a3b107157ac 100644
> --- a/drivers/pwm/pwm_th1520.rs
> +++ b/drivers/pwm/pwm_th1520.rs
> @@ -23,15 +23,21 @@
>  use core::ops::Deref;
>  use kernel::{
>      clk::Clk,
> -    device::{Bound, Core, Device},
> +    device::{
> +        Bound,
> +        Core,
> +        Device, //
> +    },
>      devres,
>      io::{
>          mem::IoMem,
>          Io, //
>      },
> -    of, platform,
> +    of,
> +    platform, //

Same here, you just need the empty comment after time, not the one after
platform.

>      prelude::*,
> -    pwm, time,
> +    pwm,
> +    time, //
>  };
>  
>  const TH1520_MAX_PWM_NUM: u32 = 6;
> 
> ---
> base-commit: 1a4920940ebfd8d907858abd8f8dd09b13752946
> change-id: 20260705-pwm-rust-vert-imp-59a3d18bd0cf
> 
> Best regards,
> --  
> Guru Das Srinagesh <linux@gurudas.dev>
> 
> 

-- 
Link Mauve

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

end of thread, other threads:[~2026-07-08  7:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-06  2:52 [PATCH] pwm: th1520: use vertical import style Guru Das Srinagesh
2026-07-06  2:52 ` Guru Das Srinagesh
2026-07-08  7:39 ` Link Mauve
2026-07-08  7:39   ` Link Mauve

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.