Skip to content

Commit fa7dfea

Browse files
fujitakuba-moo
authored andcommitted
net: phy: qt2025: Fix warning: unused import DeviceId
Fix the following warning when the driver is compiled as built-in: warning: unused import: `DeviceId` --> drivers/net/phy/qt2025.rs:18:5 | 18 | DeviceId, Driver, | ^^^^^^^^ | = note: `#[warn(unused_imports)]` on by default device_table in module_phy_driver macro is defined only when the driver is built as a module. Use phy::DeviceId in the macro instead of importing `DeviceId` since `phy` is always used. Fixes: fd3eaad ("net: phy: add Applied Micro QT2025 PHY driver") Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202409190717.i135rfVo-lkp@intel.com/ Reviewed-by: Alice Ryhl <aliceryhl@google.com> Reviewed-by: Trevor Gross <tmgross@umich.edu> Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Reviewed-by: Fiona Behrens <me@kloenk.dev> Acked-by: Miguel Ojeda <ojeda@kernel.org> Link: https://patch.msgid.link/20240926121404.242092-1-fujita.tomonori@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent a1e40ac commit fa7dfea

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

drivers/net/phy/qt2025.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,15 @@ use kernel::firmware::Firmware;
1515
use kernel::net::phy::{
1616
self,
1717
reg::{Mmd, C45},
18-
DeviceId, Driver,
18+
Driver,
1919
};
2020
use kernel::prelude::*;
2121
use kernel::sizes::{SZ_16K, SZ_8K};
2222

2323
kernel::module_phy_driver! {
2424
drivers: [PhyQT2025],
2525
device_table: [
26-
DeviceId::new_with_driver::<PhyQT2025>(),
26+
phy::DeviceId::new_with_driver::<PhyQT2025>(),
2727
],
2828
name: "qt2025_phy",
2929
author: "FUJITA Tomonori <fujita.tomonori@gmail.com>",

0 commit comments

Comments
 (0)