[leon-rdma:devlink 4/16] drivers/net/ethernet/intel/ice/ice_devlink.c:501:17: warning: variable 'dev' set but not used
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git devlink
head: 75088f5c533815580092fd7dca787c06e75ba7ba
commit: 3c73f365d81cf18adf846a4ef36e605ad52acd0a [4/16] devlink: Clean registration of devlink port
config: i386-debian-10.3 (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/leon/linux-rdma.git/commi...
git remote add leon-rdma https://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git
git fetch --no-tags leon-rdma devlink
git checkout 3c73f365d81cf18adf846a4ef36e605ad52acd0a
# save the attached .config to linux build tree
make W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/net/ethernet/intel/ice/ice_devlink.c: In function 'ice_devlink_create_pf_port':
>> drivers/net/ethernet/intel/ice/ice_devlink.c:501:17: warning: variable 'dev' set but not used [-Wunused-but-set-variable]
501 | struct device *dev;
| ^~~
drivers/net/ethernet/intel/ice/ice_devlink.c: In function 'ice_devlink_create_vf_port':
drivers/net/ethernet/intel/ice/ice_devlink.c:550:17: warning: variable 'dev' set but not used [-Wunused-but-set-variable]
550 | struct device *dev;
| ^~~
vim +/dev +501 drivers/net/ethernet/intel/ice/ice_devlink.c
1adf7ead8204094 Jacob Keller 2020-03-11 486
1adf7ead8204094 Jacob Keller 2020-03-11 487 /**
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 488 * ice_devlink_create_pf_port - Create a devlink port for this PF
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 489 * @pf: the PF to create a devlink port for
1adf7ead8204094 Jacob Keller 2020-03-11 490 *
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 491 * Create and register a devlink_port for this PF.
1adf7ead8204094 Jacob Keller 2020-03-11 492 *
1adf7ead8204094 Jacob Keller 2020-03-11 493 * Return: zero on success or an error code on failure.
1adf7ead8204094 Jacob Keller 2020-03-11 494 */
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 495 int ice_devlink_create_pf_port(struct ice_pf *pf)
1adf7ead8204094 Jacob Keller 2020-03-11 496 {
71ad8d55f8e5ea1 Danielle Ratson 2020-07-09 497 struct devlink_port_attrs attrs = {};
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 498 struct devlink_port *devlink_port;
48d40025b5392dc Jacob Keller 2020-10-07 499 struct devlink *devlink;
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 500 struct ice_vsi *vsi;
48d40025b5392dc Jacob Keller 2020-10-07 @501 struct device *dev;
1adf7ead8204094 Jacob Keller 2020-03-11 502
48d40025b5392dc Jacob Keller 2020-10-07 503 dev = ice_pf_to_dev(pf);
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 504
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 505 devlink_port = &pf->devlink_port;
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 506
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 507 vsi = ice_get_main_vsi(pf);
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 508 if (!vsi)
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 509 return -EIO;
1adf7ead8204094 Jacob Keller 2020-03-11 510
71ad8d55f8e5ea1 Danielle Ratson 2020-07-09 511 attrs.flavour = DEVLINK_PORT_FLAVOUR_PHYSICAL;
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 512 attrs.phys.port_number = pf->hw.bus.func;
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 513 devlink_port_attrs_set(devlink_port, &attrs);
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 514 devlink = priv_to_devlink(pf);
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 515
3c73f365d81cf18 Leon Romanovsky 2021-11-03 516 devlink_port_register(devlink, devlink_port, vsi->idx);
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 517 return 0;
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 518 }
2ae0aa4758b0f4a Wojciech Drewek 2021-08-19 519
:::::: The code at line 501 was first introduced by commit
:::::: 48d40025b5392dc9010eec3c99a5a4b6e5a29d1e ice: refactor devlink_port to be per-VSI
:::::: TO: Jacob Keller <jacob.e.keller(a)intel.com>
:::::: CC: Jakub Kicinski <kuba(a)kernel.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
arch/arm/mach-ixp4xx/common-pci.c:143:5: warning: no previous prototype for 'ixp4xx_pci_write'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: cb690f5238d71f543f4ce874aa59237cf53a877c
commit: d5d9f7ac58ea1041375a028f143ca5784693ea86 ARM/ixp4xx: Make NEED_MACH_IO_H optional
date: 5 months ago
config: arm-randconfig-r011-20211018 (attached as .config)
compiler: arm-linux-gnueabi-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/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout d5d9f7ac58ea1041375a028f143ca5784693ea86
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
arch/arm/mach-ixp4xx/common-pci.c:94:5: warning: no previous prototype for 'ixp4xx_pci_read_errata' [-Wmissing-prototypes]
94 | int ixp4xx_pci_read_errata(u32 addr, u32 cmd, u32* data)
| ^~~~~~~~~~~~~~~~~~~~~~
arch/arm/mach-ixp4xx/common-pci.c:121:5: warning: no previous prototype for 'ixp4xx_pci_read_no_errata' [-Wmissing-prototypes]
121 | int ixp4xx_pci_read_no_errata(u32 addr, u32 cmd, u32* data)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/arm/mach-ixp4xx/common-pci.c:143:5: warning: no previous prototype for 'ixp4xx_pci_write' [-Wmissing-prototypes]
143 | int ixp4xx_pci_write(u32 addr, u32 cmd, u32 data)
| ^~~~~~~~~~~~~~~~
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for QCOM_SCM
Depends on (ARM || ARM64) && HAVE_ARM_SMCCC
Selected by
- ARM_QCOM_SPM_CPUIDLE && CPU_IDLE && (ARM || ARM64) && (ARCH_QCOM || COMPILE_TEST && !ARM64 && MMU
vim +/ixp4xx_pci_write +143 arch/arm/mach-ixp4xx/common-pci.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 93
^1da177e4c3f41 Linus Torvalds 2005-04-16 @94 int ixp4xx_pci_read_errata(u32 addr, u32 cmd, u32* data)
^1da177e4c3f41 Linus Torvalds 2005-04-16 95 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 96 unsigned long flags;
^1da177e4c3f41 Linus Torvalds 2005-04-16 97 int retval = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 98 int i;
^1da177e4c3f41 Linus Torvalds 2005-04-16 99
bd31b85960a7fc Thomas Gleixner 2009-07-03 100 raw_spin_lock_irqsave(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 101
^1da177e4c3f41 Linus Torvalds 2005-04-16 102 *PCI_NP_AD = addr;
^1da177e4c3f41 Linus Torvalds 2005-04-16 103
^1da177e4c3f41 Linus Torvalds 2005-04-16 104 /*
^1da177e4c3f41 Linus Torvalds 2005-04-16 105 * PCI workaround - only works if NP PCI space reads have
^1da177e4c3f41 Linus Torvalds 2005-04-16 106 * no side effects!!! Read 8 times. last one will be good.
^1da177e4c3f41 Linus Torvalds 2005-04-16 107 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 108 for (i = 0; i < 8; i++) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 109 *PCI_NP_CBE = cmd;
^1da177e4c3f41 Linus Torvalds 2005-04-16 110 *data = *PCI_NP_RDATA;
^1da177e4c3f41 Linus Torvalds 2005-04-16 111 *data = *PCI_NP_RDATA;
^1da177e4c3f41 Linus Torvalds 2005-04-16 112 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 113
^1da177e4c3f41 Linus Torvalds 2005-04-16 114 if(check_master_abort())
^1da177e4c3f41 Linus Torvalds 2005-04-16 115 retval = 1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 116
bd31b85960a7fc Thomas Gleixner 2009-07-03 117 raw_spin_unlock_irqrestore(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 118 return retval;
^1da177e4c3f41 Linus Torvalds 2005-04-16 119 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 120
^1da177e4c3f41 Linus Torvalds 2005-04-16 121 int ixp4xx_pci_read_no_errata(u32 addr, u32 cmd, u32* data)
^1da177e4c3f41 Linus Torvalds 2005-04-16 122 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 123 unsigned long flags;
^1da177e4c3f41 Linus Torvalds 2005-04-16 124 int retval = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 125
bd31b85960a7fc Thomas Gleixner 2009-07-03 126 raw_spin_lock_irqsave(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 127
^1da177e4c3f41 Linus Torvalds 2005-04-16 128 *PCI_NP_AD = addr;
^1da177e4c3f41 Linus Torvalds 2005-04-16 129
^1da177e4c3f41 Linus Torvalds 2005-04-16 130 /* set up and execute the read */
^1da177e4c3f41 Linus Torvalds 2005-04-16 131 *PCI_NP_CBE = cmd;
^1da177e4c3f41 Linus Torvalds 2005-04-16 132
^1da177e4c3f41 Linus Torvalds 2005-04-16 133 /* the result of the read is now in NP_RDATA */
^1da177e4c3f41 Linus Torvalds 2005-04-16 134 *data = *PCI_NP_RDATA;
^1da177e4c3f41 Linus Torvalds 2005-04-16 135
^1da177e4c3f41 Linus Torvalds 2005-04-16 136 if(check_master_abort())
^1da177e4c3f41 Linus Torvalds 2005-04-16 137 retval = 1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 138
bd31b85960a7fc Thomas Gleixner 2009-07-03 139 raw_spin_unlock_irqrestore(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 140 return retval;
^1da177e4c3f41 Linus Torvalds 2005-04-16 141 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 142
^1da177e4c3f41 Linus Torvalds 2005-04-16 @143 int ixp4xx_pci_write(u32 addr, u32 cmd, u32 data)
^1da177e4c3f41 Linus Torvalds 2005-04-16 144 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 145 unsigned long flags;
^1da177e4c3f41 Linus Torvalds 2005-04-16 146 int retval = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 147
bd31b85960a7fc Thomas Gleixner 2009-07-03 148 raw_spin_lock_irqsave(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 149
^1da177e4c3f41 Linus Torvalds 2005-04-16 150 *PCI_NP_AD = addr;
^1da177e4c3f41 Linus Torvalds 2005-04-16 151
^1da177e4c3f41 Linus Torvalds 2005-04-16 152 /* set up the write */
^1da177e4c3f41 Linus Torvalds 2005-04-16 153 *PCI_NP_CBE = cmd;
^1da177e4c3f41 Linus Torvalds 2005-04-16 154
^1da177e4c3f41 Linus Torvalds 2005-04-16 155 /* execute the write by writing to NP_WDATA */
^1da177e4c3f41 Linus Torvalds 2005-04-16 156 *PCI_NP_WDATA = data;
^1da177e4c3f41 Linus Torvalds 2005-04-16 157
^1da177e4c3f41 Linus Torvalds 2005-04-16 158 if(check_master_abort())
^1da177e4c3f41 Linus Torvalds 2005-04-16 159 retval = 1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 160
bd31b85960a7fc Thomas Gleixner 2009-07-03 161 raw_spin_unlock_irqrestore(&ixp4xx_pci_lock, flags);
^1da177e4c3f41 Linus Torvalds 2005-04-16 162 return retval;
^1da177e4c3f41 Linus Torvalds 2005-04-16 163 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 164
:::::: The code at line 143 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2
:::::: TO: Linus Torvalds <torvalds(a)ppc970.osdl.org>
:::::: CC: Linus Torvalds <torvalds(a)ppc970.osdl.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
drivers/ptp/ptp_clockmatrix.c:1679: warning: This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: cb690f5238d71f543f4ce874aa59237cf53a877c
commit: da9facf1c1825201956c2553e06d455dea3e0313 ptp: ptp_clockmatrix: Add support for pll_mode=0 and manual ref switch of WF and WP
date: 8 weeks ago
config: i386-randconfig-a001-20211109 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project f3798ad5fa845771846599f3c088016e3aef800c)
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/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout da9facf1c1825201956c2553e06d455dea3e0313
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> drivers/ptp/ptp_clockmatrix.c:1679: warning: This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst
* Maximum absolute value for write phase offset in picoseconds
vim +1679 drivers/ptp/ptp_clockmatrix.c
1677
1678 /**
> 1679 * Maximum absolute value for write phase offset in picoseconds
1680 *
1681 * @channel: channel
1682 * @delta_ns: delta in nanoseconds
1683 *
1684 * Destination signed register is 32-bit register in resolution of 50ps
1685 *
1686 * 0x7fffffff * 50 = 2147483647 * 50 = 107374182350
1687 */
1688 static int _idtcm_adjphase(struct idtcm_channel *channel, s32 delta_ns)
1689 {
1690 struct idtcm *idtcm = channel->idtcm;
1691 int err;
1692 u8 i;
1693 u8 buf[4] = {0};
1694 s32 phase_50ps;
1695 s64 offset_ps;
1696
1697 if (channel->mode != PTP_PLL_MODE_WRITE_PHASE) {
1698 err = channel->configure_write_phase(channel);
1699 if (err)
1700 return err;
1701 }
1702
1703 offset_ps = (s64)delta_ns * 1000;
1704
1705 /*
1706 * Check for 32-bit signed max * 50:
1707 *
1708 * 0x7fffffff * 50 = 2147483647 * 50 = 107374182350
1709 */
1710 if (offset_ps > MAX_ABS_WRITE_PHASE_PICOSECONDS)
1711 offset_ps = MAX_ABS_WRITE_PHASE_PICOSECONDS;
1712 else if (offset_ps < -MAX_ABS_WRITE_PHASE_PICOSECONDS)
1713 offset_ps = -MAX_ABS_WRITE_PHASE_PICOSECONDS;
1714
1715 phase_50ps = div_s64(offset_ps, 50);
1716
1717 for (i = 0; i < 4; i++) {
1718 buf[i] = phase_50ps & 0xff;
1719 phase_50ps >>= 8;
1720 }
1721
1722 err = idtcm_write(idtcm, channel->dpll_phase, DPLL_WR_PHASE,
1723 buf, sizeof(buf));
1724
1725 return err;
1726 }
1727
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
[kabel:net-queue-work2 79/79] drivers/net/phy/mdio_debugfs.c:43:5: error: no previous prototype for 'mdiobus_register_debugfs'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kabel/linux.git net-queue-work2
head: 6e6c882b9f9314372cef270671a39ea67460ea6b
commit: 6e6c882b9f9314372cef270671a39ea67460ea6b [79/79] net: mdiobus: add support to access PHY registers via debugfs [*not for mainline*]
config: arc-allyesconfig (attached as .config)
compiler: arceb-elf-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/kabel/linux.git/commit/?i...
git remote add kabel https://git.kernel.org/pub/scm/linux/kernel/git/kabel/linux.git
git fetch --no-tags kabel net-queue-work2
git checkout 6e6c882b9f9314372cef270671a39ea67460ea6b
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arc
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 >>):
>> drivers/net/phy/mdio_debugfs.c:43:5: error: no previous prototype for 'mdiobus_register_debugfs' [-Werror=missing-prototypes]
43 | int mdiobus_register_debugfs(struct mii_bus *bus)
| ^~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/phy/mdio_debugfs.c:65:6: error: no previous prototype for 'mdiobus_unregister_debugfs' [-Werror=missing-prototypes]
65 | void mdiobus_unregister_debugfs(struct mii_bus *bus)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/phy/mdio_debugfs.c:76:5: error: no previous prototype for 'mdiobus_debugfs_init' [-Werror=missing-prototypes]
76 | int mdiobus_debugfs_init(void)
| ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/phy/mdio_debugfs.c:89:6: error: no previous prototype for 'mdiobus_debugfs_exit' [-Werror=missing-prototypes]
89 | void mdiobus_debugfs_exit(void)
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/mdiobus_register_debugfs +43 drivers/net/phy/mdio_debugfs.c
42
> 43 int mdiobus_register_debugfs(struct mii_bus *bus)
44 {
45 struct dentry *dir, *entry;
46
47 dir = debugfs_create_dir(dev_name(&bus->dev), mdiobus_dentry);
48 if (IS_ERR(dir))
49 return PTR_ERR(dir);
50
51 debugfs_create_u32("addr", 0600, dir, &bus->debug_addr);
52 debugfs_create_u32("reg", 0600, dir, &bus->debug_reg);
53
54 entry = debugfs_create_file_unsafe("val", 0600, dir, bus, &val_fops);
55 if (IS_ERR(entry))
56 goto fail;
57
58 return 0;
59
60 fail:
61 debugfs_remove_recursive(dir);
62 return PTR_ERR(entry);
63 }
64
> 65 void mdiobus_unregister_debugfs(struct mii_bus *bus)
66 {
67 struct dentry *dir;
68
69 dir = debugfs_lookup(dev_name(&bus->dev), mdiobus_dentry);
70 if (!dir)
71 return;
72
73 debugfs_remove_recursive(dir);
74 }
75
> 76 int mdiobus_debugfs_init(void)
77 {
78 struct dentry *dentry;
79
80 dentry = debugfs_create_dir("mdio_bus", NULL);
81 if (IS_ERR(dentry))
82 return PTR_ERR(dentry);
83
84 mdiobus_dentry = dentry;
85
86 return 0;
87 }
88
> 89 void mdiobus_debugfs_exit(void)
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
[djwong-xfs:zero-initialize-pmem-5.16 18/28] fs/xfs/libxfs/xfs_ialloc_btree.c:552:53: sparse: sparse: cast truncates bits from constant value (100000000 becomes 0)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git zero-initialize-pmem-5.16
head: 34b80c3d1203abd5fd64242ef25898c7d64166ca
commit: c0ef00d1e835bfd24399aaa069b2b608dd60b485 [18/28] xfs: check absolute maximum nlevels for each btree type
config: csky-randconfig-s032-20211008 (attached as .config)
compiler: csky-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/djwong/xfs-linux.git/comm...
git remote add djwong-xfs https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git
git fetch --no-tags djwong-xfs zero-initialize-pmem-5.16
git checkout c0ef00d1e835bfd24399aaa069b2b608dd60b485
# 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__' O=build_dir ARCH=csky SHELL=/bin/bash fs/xfs/ mm/
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 >>)
fs/xfs/libxfs/xfs_ialloc_btree.c: note: in included file (through include/linux/bitops.h, include/linux/kernel.h, include/linux/list.h, ...):
arch/csky/include/asm/bitops.h:77:9: sparse: sparse: preprocessor token __clear_bit redefined
fs/xfs/libxfs/xfs_ialloc_btree.c: note: in included file (through arch/csky/include/asm/bitops.h, include/linux/bitops.h, include/linux/kernel.h, ...):
include/asm-generic/bitops/non-atomic.h:34:9: sparse: this was the original definition
>> fs/xfs/libxfs/xfs_ialloc_btree.c:552:53: sparse: sparse: cast truncates bits from constant value (100000000 becomes 0)
vim +552 fs/xfs/libxfs/xfs_ialloc_btree.c
543
544 unsigned int
545 xfs_inobt_absolute_maxlevels(void)
546 {
547 unsigned int minrecs[2];
548
549 xfs_btree_absolute_minrecs(minrecs, 0, sizeof(xfs_inobt_rec_t),
550 sizeof(xfs_inobt_key_t) + sizeof(xfs_inobt_ptr_t));
551
> 552 return xfs_btree_compute_maxlevels(minrecs, XFS_MAX_AG_INODES);
553 }
554
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
Re: [PATCH] [RFC] dt-bindings: clk: Introduce 'critical-clocks' property
by kernel test robot
Hi Marek,
[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on clk/clk-next]
[also build test WARNING on v5.15 next-20211110]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Marek-Vasut/dt-bindings-clk-Intr...
base: https://git.kernel.org/pub/scm/linux/kernel/git/clk/linux.git clk-next
config: nios2-defconfig (attached as .config)
compiler: nios2-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://github.com/0day-ci/linux/commit/6f73b7f399440eee282d746b1907e28f4...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Marek-Vasut/dt-bindings-clk-Introduce-critical-clocks-property/20211109-064424
git checkout 6f73b7f399440eee282d746b1907e28f45b81a14
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=nios2
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/clk/clk.c: In function '__clk_register':
>> drivers/clk/clk.c:3852:9: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
3852 | struct of_phandle_args clkspec;
| ^~~~~~
vim +3852 drivers/clk/clk.c
3806
3807 static struct clk *
3808 __clk_register(struct device *dev, struct device_node *np, struct clk_hw *hw)
3809 {
3810 int ret;
3811 struct clk_core *core;
3812 const struct clk_init_data *init = hw->init;
3813
3814 /*
3815 * The init data is not supposed to be used outside of registration path.
3816 * Set it to NULL so that provider drivers can't use it either and so that
3817 * we catch use of hw->init early on in the core.
3818 */
3819 hw->init = NULL;
3820
3821 core = kzalloc(sizeof(*core), GFP_KERNEL);
3822 if (!core) {
3823 ret = -ENOMEM;
3824 goto fail_out;
3825 }
3826
3827 core->name = kstrdup_const(init->name, GFP_KERNEL);
3828 if (!core->name) {
3829 ret = -ENOMEM;
3830 goto fail_name;
3831 }
3832
3833 if (WARN_ON(!init->ops)) {
3834 ret = -EINVAL;
3835 goto fail_ops;
3836 }
3837 core->ops = init->ops;
3838
3839 if (dev && pm_runtime_enabled(dev))
3840 core->rpm_enabled = true;
3841 core->dev = dev;
3842 core->of_node = np;
3843 if (dev && dev->driver)
3844 core->owner = dev->driver->owner;
3845 core->hw = hw;
3846 core->flags = init->flags;
3847 core->num_parents = init->num_parents;
3848 core->min_rate = 0;
3849 core->max_rate = ULONG_MAX;
3850 hw->core = core;
3851
> 3852 struct of_phandle_args clkspec;
3853 u32 clksize, clktotal;
3854 int i, index;
3855
3856 if (np && core->ops->match_clkspec && !of_property_read_u32(np, "#clock-cells", &clksize)) {
3857 if (clksize == 0) {
3858 if (of_property_read_bool(np, "critical-clocks"))
3859 core->flags |= CLK_IS_CRITICAL;
3860 clktotal = 0;
3861 } else {
3862 clkspec.np = np;
3863 clktotal = of_property_count_u32_elems(np, "critical-clocks");
3864 clktotal /= clksize;
3865 for (index = 0; index < clktotal; index++) {
3866 for (i = 0; i < clksize; i++) {
3867 ret = of_property_read_u32_index(np, "critical-clocks",
3868 (index * clksize) + i,
3869 &(clkspec.args[i]));
3870 }
3871 if (!core->ops->match_clkspec(hw, &clkspec))
3872 core->flags |= CLK_IS_CRITICAL;
3873 }
3874 }
3875 }
3876
3877 ret = clk_core_populate_parent_map(core, init);
3878 if (ret)
3879 goto fail_parents;
3880
3881 INIT_HLIST_HEAD(&core->clks);
3882
3883 /*
3884 * Don't call clk_hw_create_clk() here because that would pin the
3885 * provider module to itself and prevent it from ever being removed.
3886 */
3887 hw->clk = alloc_clk(core, NULL, NULL);
3888 if (IS_ERR(hw->clk)) {
3889 ret = PTR_ERR(hw->clk);
3890 goto fail_create_clk;
3891 }
3892
3893 clk_core_link_consumer(hw->core, hw->clk);
3894
3895 ret = __clk_core_init(core);
3896 if (!ret)
3897 return hw->clk;
3898
3899 clk_prepare_lock();
3900 clk_core_unlink_consumer(hw->clk);
3901 clk_prepare_unlock();
3902
3903 free_clk(hw->clk);
3904 hw->clk = NULL;
3905
3906 fail_create_clk:
3907 clk_core_free_parent_map(core);
3908 fail_parents:
3909 fail_ops:
3910 kfree_const(core->name);
3911 fail_name:
3912 kfree(core);
3913 fail_out:
3914 return ERR_PTR(ret);
3915 }
3916
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
include/linux/compiler_types.h:338:45: error: call to '__compiletime_assert_270' declared with attribute error: BUILD_BUG_ON failed: IS_ENABLED(CONFIG_32BIT) && (_PFN_SHIFT > PAGE_SHIFT)
by kernel test robot
Hi Will,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: cb690f5238d71f543f4ce874aa59237cf53a877c
commit: eb5c2d4b45e3d2d5d052ea6b8f1463976b1020d5 compiler.h: Move compiletime_assert() macros into compiler_types.h
date: 1 year, 4 months ago
config: mips-randconfig-r035-20211029 (attached as .config)
compiler: mipsel-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/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout eb5c2d4b45e3d2d5d052ea6b8f1463976b1020d5
# 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=mips SHELL=/bin/bash arch/mips/
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 >>):
arch/mips/mm/init.c:61:6: warning: no previous prototype for 'setup_zero_pages' [-Wmissing-prototypes]
61 | void setup_zero_pages(void)
| ^~~~~~~~~~~~~~~~
In file included from <command-line>:
arch/mips/mm/init.c: In function 'mem_init':
>> include/linux/compiler_types.h:338:45: error: call to '__compiletime_assert_270' declared with attribute error: BUILD_BUG_ON failed: IS_ENABLED(CONFIG_32BIT) && (_PFN_SHIFT > PAGE_SHIFT)
338 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^
include/linux/compiler_types.h:319:25: note: in definition of macro '__compiletime_assert'
319 | prefix ## suffix(); \
| ^~~~~~
include/linux/compiler_types.h:338:9: note: in expansion of macro '_compiletime_assert'
338 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
| ^~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:50:9: note: in expansion of macro 'BUILD_BUG_ON_MSG'
50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
| ^~~~~~~~~~~~~~~~
arch/mips/mm/init.c:458:9: note: in expansion of macro 'BUILD_BUG_ON'
458 | BUILD_BUG_ON(IS_ENABLED(CONFIG_32BIT) && (_PFN_SHIFT > PAGE_SHIFT));
| ^~~~~~~~~~~~
vim +/__compiletime_assert_270 +338 include/linux/compiler_types.h
324
325 #define _compiletime_assert(condition, msg, prefix, suffix) \
326 __compiletime_assert(condition, msg, prefix, suffix)
327
328 /**
329 * compiletime_assert - break build and emit msg if condition is false
330 * @condition: a compile-time constant condition to check
331 * @msg: a message to emit if condition is false
332 *
333 * In tradition of POSIX assert, this macro will break the build if the
334 * supplied condition is *false*, emitting the supplied error message if the
335 * compiler has support to do so.
336 */
337 #define compiletime_assert(condition, msg) \
> 338 _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
339
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks
[freescale-fslc:5.10-2.1.x-imx 13017/15242] sound/soc/sof/imx/imx8ulp.c:277:9: error: implicit declaration of function 'arm_smccc_smc'
by kernel test robot
Hi Zhang,
FYI, the error/warning still remains.
tree: https://github.com/Freescale/linux-fslc 5.10-2.1.x-imx
head: 3b81a70be1099d44fdafaa6766bf75a2bd9e297e
commit: b8f017dd505c9a64b8a1a1cd39f829d2c3178a15 [13017/15242] LF-4230-1: ASoC: SOF: Support SOF on 8ULP platform
config: ia64-allyesconfig (attached as .config)
compiler: ia64-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://github.com/Freescale/linux-fslc/commit/b8f017dd505c9a64b8a1a1cd39...
git remote add freescale-fslc https://github.com/Freescale/linux-fslc
git fetch --no-tags freescale-fslc 5.10-2.1.x-imx
git checkout b8f017dd505c9a64b8a1a1cd39f829d2c3178a15
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=ia64
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 >>):
sound/soc/sof/imx/imx8ulp.c:80:5: warning: no previous prototype for 'imx8ulp_configure_sim_lpav' [-Wmissing-prototypes]
80 | int imx8ulp_configure_sim_lpav(struct imx8ulp_priv *priv)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c: In function 'imx8ulp_reset':
>> sound/soc/sof/imx/imx8ulp.c:277:9: error: implicit declaration of function 'arm_smccc_smc' [-Werror=implicit-function-declaration]
277 | arm_smccc_smc(FSL_SIP_HIFI_XRDC, 0, 0, 0, 0, 0, 0, 0, &smc_resource);
| ^~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c: At top level:
sound/soc/sof/imx/imx8ulp.c:435:5: warning: no previous prototype for 'imx8ulp_suspend' [-Wmissing-prototypes]
435 | int imx8ulp_suspend(struct snd_sof_dev *sdev)
| ^~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:448:5: warning: no previous prototype for 'imx8ulp_resume' [-Wmissing-prototypes]
448 | int imx8ulp_resume(struct snd_sof_dev *sdev)
| ^~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:461:5: warning: no previous prototype for 'imx8ulp_dsp_runtime_resume' [-Wmissing-prototypes]
461 | int imx8ulp_dsp_runtime_resume(struct snd_sof_dev *sdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:473:5: warning: no previous prototype for 'imx8ulp_dsp_runtime_suspend' [-Wmissing-prototypes]
473 | int imx8ulp_dsp_runtime_suspend(struct snd_sof_dev *sdev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:486:5: warning: no previous prototype for 'imx8ulp_dsp_suspend' [-Wmissing-prototypes]
486 | int imx8ulp_dsp_suspend(struct snd_sof_dev *sdev, unsigned int target_state)
| ^~~~~~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:499:5: warning: no previous prototype for 'imx8ulp_dsp_resume' [-Wmissing-prototypes]
499 | int imx8ulp_dsp_resume(struct snd_sof_dev *sdev)
| ^~~~~~~~~~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:533:5: warning: no previous prototype for 'imx8ulp_dsp_set_power_state' [-Wmissing-prototypes]
533 | int imx8ulp_dsp_set_power_state(struct snd_sof_dev *sdev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from include/sound/asound.h:24,
from include/sound/pcm.h:11,
from include/sound/soc.h:23,
from include/sound/sof.h:15,
from sound/soc/sof/imx/imx8ulp.c:19:
include/uapi/sound/asound.h:281:41: warning: initialized field overwritten [-Woverride-init]
281 | #define SNDRV_PCM_INFO_MMAP 0x00000001 /* hardware supports mmap */
| ^~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:601:25: note: in expansion of macro 'SNDRV_PCM_INFO_MMAP'
601 | .hw_info = SNDRV_PCM_INFO_MMAP |
| ^~~~~~~~~~~~~~~~~~~
include/uapi/sound/asound.h:281:41: note: (near initialization for 'sof_imx8ulp_ops.hw_info')
281 | #define SNDRV_PCM_INFO_MMAP 0x00000001 /* hardware supports mmap */
| ^~~~~~~~~~
sound/soc/sof/imx/imx8ulp.c:601:25: note: in expansion of macro 'SNDRV_PCM_INFO_MMAP'
601 | .hw_info = SNDRV_PCM_INFO_MMAP |
| ^~~~~~~~~~~~~~~~~~~
>> sound/soc/sof/imx/imx8ulp.c:31:22: error: storage size of 'smc_resource' isn't known
31 | struct arm_smccc_res smc_resource;
| ^~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/arm_smccc_smc +277 sound/soc/sof/imx/imx8ulp.c
78
79 /* System integration module(SIM) control dsp configurtion */
> 80 int imx8ulp_configure_sim_lpav(struct imx8ulp_priv *priv)
81 {
82 priv->regmap_sim = syscon_regmap_lookup_by_compatible("nxp,imx8ulp-avd-sim");
83 if (IS_ERR(priv->regmap_sim))
84 return -EPROBE_DEFER;
85 return 0;
86 }
87
88 static void imx8ulp_sim_lpav_start(struct imx8ulp_priv *priv)
89 {
90 /* Controls the HiFi4 DSP Reset: 1 in reset, 0 out of reset */
91 regmap_update_bits(priv->regmap_sim, SYSCTRL0, RESET_BIT, 0);
92 /* Reset HiFi4 DSP Debug logic: 1 reset, 0 not set */
93 regmap_update_bits(priv->regmap_sim, SYSCTRL0, DEBUG_LOGIC_BIT, 0);
94 /* Stall HIFI4 DSP Execution: 1 stall, 0 not stall */
95 regmap_update_bits(priv->regmap_sim, SYSCTRL0, EXECUTE_BIT, 0);
96 }
97
98 static int imx8ulp_init_clocks(struct snd_sof_dev *sdev)
99 {
100 int i;
101 struct imx8ulp_priv *priv = (struct imx8ulp_priv *)sdev->pdata->hw_pdata;
102
103 for (i = 0; i < IMX8ULP_DSP_CLK_NUM; i++) {
104 priv->dsp_clks[i] = devm_clk_get(priv->dev, imx8ulp_dsp_clks_names[i]);
105 if (IS_ERR(priv->dsp_clks[i]))
106 return PTR_ERR(priv->dsp_clks[i]);
107 }
108
109 for (i = 0; i < IMX8ULP_DAI_CLK_NUM; i++)
110 priv->dai_clks[i] = devm_clk_get_optional(priv->dev, imx8ulp_dai_clks_names[i]);
111
112 return 0;
113 }
114
115 static int imx8ulp_prepare_clocks(struct snd_sof_dev *sdev)
116 {
117 int i, j, ret;
118 struct imx8ulp_priv *priv = (struct imx8ulp_priv *)sdev->pdata->hw_pdata;
119
120 for (i = 0; i < IMX8ULP_DSP_CLK_NUM; i++) {
121 ret = clk_prepare_enable(priv->dsp_clks[i]);
122 if (ret < 0) {
123 dev_err(priv->dev, "Failed to enable clk %s\n",
124 imx8ulp_dsp_clks_names[i]);
125 goto err_dsp_clks;
126 }
127 }
128
129 for (j = 0; j < IMX8ULP_DAI_CLK_NUM; j++) {
130 ret = clk_prepare_enable(priv->dai_clks[j]);
131 if (ret < 0) {
132 dev_err(priv->dev, "Failed to enable clk %s\n",
133 imx8ulp_dai_clks_names[j]);
134 goto err_dai_clks;
135 }
136 }
137
138 return 0;
139
140 err_dai_clks:
141 while (--j >= 0)
142 clk_disable_unprepare(priv->dai_clks[j]);
143
144 err_dsp_clks:
145 while (--i >= 0)
146 clk_disable_unprepare(priv->dsp_clks[i]);
147
148 return ret;
149 }
150
151 static void imx8ulp_disable_clocks(struct snd_sof_dev *sdev)
152 {
153 int i;
154 struct imx8ulp_priv *priv = (struct imx8ulp_priv *)sdev->pdata->hw_pdata;
155
156 for (i = 0; i < IMX8ULP_DSP_CLK_NUM; i++)
157 clk_disable_unprepare(priv->dsp_clks[i]);
158
159 for (i = 0; i < IMX8ULP_DAI_CLK_NUM; i++)
160 clk_disable_unprepare(priv->dai_clks[i]);
161 }
162
163 static void imx8ulp_get_reply(struct snd_sof_dev *sdev)
164 {
165 struct snd_sof_ipc_msg *msg = sdev->msg;
166 struct sof_ipc_reply reply;
167 int ret = 0;
168
169 if (!msg) {
170 dev_warn(sdev->dev, "unexpected ipc interrupt\n");
171 return;
172 }
173
174 /* get reply */
175 sof_mailbox_read(sdev, sdev->host_box.offset, &reply, sizeof(reply));
176
177 if (reply.error < 0) {
178 memcpy(msg->reply_data, &reply, sizeof(reply));
179 ret = reply.error;
180 } else {
181 /* reply has correct size? */
182 if (reply.hdr.size != msg->reply_size) {
183 dev_err(sdev->dev, "error: reply expected %zu got %u bytes\n",
184 msg->reply_size, reply.hdr.size);
185 ret = -EINVAL;
186 }
187
188 /* read the message */
189 if (msg->reply_size > 0)
190 sof_mailbox_read(sdev, sdev->host_box.offset,
191 msg->reply_data, msg->reply_size);
192 }
193
194 msg->reply_error = ret;
195 }
196
197 static int imx8ulp_get_mailbox_offset(struct snd_sof_dev *sdev)
198 {
199 return MBOX_OFFSET;
200 }
201
202 static int imx8ulp_get_window_offset(struct snd_sof_dev *sdev, u32 id)
203 {
204 return MBOX_OFFSET;
205 }
206
207 static void imx8ulp_dsp_handle_reply(struct imx_dsp_ipc *ipc)
208 {
209 struct imx8ulp_priv *priv = imx_dsp_get_data(ipc);
210 unsigned long flags;
211
212 spin_lock_irqsave(&priv->sdev->ipc_lock, flags);
213
214 imx8ulp_get_reply(priv->sdev);
215 snd_sof_ipc_reply(priv->sdev, 0);
216 spin_unlock_irqrestore(&priv->sdev->ipc_lock, flags);
217 }
218
219 static void imx8ulp_dsp_handle_request(struct imx_dsp_ipc *ipc)
220 {
221 struct imx8ulp_priv *priv = imx_dsp_get_data(ipc);
222 u32 p; /* panic code */
223
224 /* Read the message from the debug box. */
225 sof_mailbox_read(priv->sdev, priv->sdev->debug_box.offset + 4, &p, sizeof(p));
226
227 /* Check to see if the message is a panic code (0x0dead***) */
228 if ((p & SOF_IPC_PANIC_MAGIC_MASK) == SOF_IPC_PANIC_MAGIC)
229 snd_sof_dsp_panic(priv->sdev, p);
230 else
231 snd_sof_ipc_msgs_rx(priv->sdev);
232 }
233
234 static struct imx_dsp_ops dsp_ops = {
235 .handle_reply = imx8ulp_dsp_handle_reply,
236 .handle_request = imx8ulp_dsp_handle_request,
237 };
238
239 static int imx8ulp_send_msg(struct snd_sof_dev *sdev, struct snd_sof_ipc_msg *msg)
240 {
241 struct imx8ulp_priv *priv = sdev->pdata->hw_pdata;
242
243 sof_mailbox_write(sdev, sdev->host_box.offset, msg->msg_data,
244 msg->msg_size);
245 imx_dsp_ring_doorbell(priv->dsp_ipc, 0);
246
247 return 0;
248 }
249
250 /* config sc firmware */
251 static int imx8ulp_run(struct snd_sof_dev *sdev)
252 {
253 struct imx8ulp_priv *priv = sdev->pdata->hw_pdata;
254
255 imx8ulp_sim_lpav_start(priv);
256
257 return 0;
258 }
259
260 static int imx8ulp_reset(struct snd_sof_dev *sdev)
261 {
262 struct imx8ulp_priv *priv = sdev->pdata->hw_pdata;
263
264 /* HiFi4 Platform Clock Enable: 1 enabled, 0 disabled */
265 regmap_update_bits(priv->regmap_sim, SYSCTRL0, PLAT_CLK_BIT, PLAT_CLK_BIT);
266 /* HiFi4 PBCLK clock enable: 1 enabled, 0 disabled */
267 regmap_update_bits(priv->regmap_sim, SYSCTRL0, PB_CLK_BIT, PB_CLK_BIT);
268 /* HiFi4 Clock Enable: 1 enabled, 0 disabled */
269 regmap_update_bits(priv->regmap_sim, SYSCTRL0, HIFI4_CLK_BIT, HIFI4_CLK_BIT);
270
271 regmap_update_bits(priv->regmap_sim, SYSCTRL0, RESET_BIT, RESET_BIT);
272 usleep_range(1, 2);
273 /* Stall HIFI4 DSP Execution: 1 stall, 0 not stall */
274 regmap_update_bits(priv->regmap_sim, SYSCTRL0, EXECUTE_BIT, EXECUTE_BIT);
275 usleep_range(1, 2);
276
> 277 arm_smccc_smc(FSL_SIP_HIFI_XRDC, 0, 0, 0, 0, 0, 0, 0, &smc_resource);
278
279 return 0;
280 }
281
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months, 2 weeks