[sashal-linux-stable:queue-5.10 217/477] drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c:183:54: error: 'struct mtk_ddp_comp' has no member named 'dev'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git queue-5.10
head: d4d12e36e0e5b2c5a7e81258672dc628ad952f36
commit: c89dab15acdcdcfa6f2d342c8f3e627bebcce60b [217/477] drm/mediatek: Fix aal size config
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.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/sashal/linux-stable.git/c...
git remote add sashal-linux-stable https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
git fetch --no-tags sashal-linux-stable queue-5.10
git checkout c89dab15acdcdcfa6f2d342c8f3e627bebcce60b
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm64
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/gpu/drm/mediatek/mtk_drm_ddp_comp.c: In function 'mtk_aal_config':
>> drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c:183:54: error: 'struct mtk_ddp_comp' has no member named 'dev'
183 | struct mtk_ddp_comp_dev *priv = dev_get_drvdata(comp->dev);
| ^~
>> drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c:185:44: error: dereferencing pointer to incomplete type 'struct mtk_ddp_comp_dev'
185 | mtk_ddp_write(cmdq_pkt, w << 16 | h, &priv->cmdq_reg, priv->regs, DISP_AAL_SIZE);
| ^~
>> drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c:185:2: error: too many arguments to function 'mtk_ddp_write'
185 | mtk_ddp_write(cmdq_pkt, w << 16 | h, &priv->cmdq_reg, priv->regs, DISP_AAL_SIZE);
| ^~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c:89:6: note: declared here
89 | void mtk_ddp_write(struct cmdq_pkt *cmdq_pkt, unsigned int value,
| ^~~~~~~~~~~~~
vim +183 drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c
178
179 static void mtk_aal_config(struct mtk_ddp_comp *comp, unsigned int w,
180 unsigned int h, unsigned int vrefresh,
181 unsigned int bpc, struct cmdq_pkt *cmdq_pkt)
182 {
> 183 struct mtk_ddp_comp_dev *priv = dev_get_drvdata(comp->dev);
184
> 185 mtk_ddp_write(cmdq_pkt, w << 16 | h, &priv->cmdq_reg, priv->regs, DISP_AAL_SIZE);
186 }
187
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [PATCH] hugetlb_cgroup: fix imbalanced css_get and css_put pair for shared mappings
by kernel test robot
Hi Miaohe,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on next-20210125]
[also build test ERROR on v5.11-rc7]
[cannot apply to linux/master linus/master hnaz-linux-mm/master v5.11-rc7 v5.11-rc6 v5.11-rc5]
[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/Miaohe-Lin/hugetlb_cgroup-fix-im...
base: 59fa6a163ffabc1bf25c5e0e33899e268a96d3cc
config: arm64-randconfig-r025-20210209 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project c9439ca36342fb6013187d0a69aef92736951476)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://github.com/0day-ci/linux/commit/68f4ed1b80aa7c51a921c3ad913ee7e6e...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Miaohe-Lin/hugetlb_cgroup-fix-imbalanced-css_get-and-css_put-pair-for-shared-mappings/20210210-171736
git checkout 68f4ed1b80aa7c51a921c3ad913ee7e6e00618d0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64
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 >>):
>> mm/hugetlb.c:5222:17: error: incomplete definition of type 'struct hugetlb_cgroup'
css_put(&h_cg->css);
~~~~^
include/linux/hugetlb_cgroup.h:20:8: note: forward declaration of 'struct hugetlb_cgroup'
struct hugetlb_cgroup;
^
1 error generated.
vim +5222 mm/hugetlb.c
5091
5092 /* Return true if reservation was successful, false otherwise. */
5093 bool hugetlb_reserve_pages(struct inode *inode,
5094 long from, long to,
5095 struct vm_area_struct *vma,
5096 vm_flags_t vm_flags)
5097 {
5098 long chg, add = -1;
5099 struct hstate *h = hstate_inode(inode);
5100 struct hugepage_subpool *spool = subpool_inode(inode);
5101 struct resv_map *resv_map;
5102 struct hugetlb_cgroup *h_cg = NULL;
5103 long gbl_reserve, regions_needed = 0;
5104
5105 /* This should never happen */
5106 if (from > to) {
5107 VM_WARN(1, "%s called with a negative range\n", __func__);
5108 return false;
5109 }
5110
5111 /*
5112 * Only apply hugepage reservation if asked. At fault time, an
5113 * attempt will be made for VM_NORESERVE to allocate a page
5114 * without using reserves
5115 */
5116 if (vm_flags & VM_NORESERVE)
5117 return true;
5118
5119 /*
5120 * Shared mappings base their reservation on the number of pages that
5121 * are already allocated on behalf of the file. Private mappings need
5122 * to reserve the full area even if read-only as mprotect() may be
5123 * called to make the mapping read-write. Assume !vma is a shm mapping
5124 */
5125 if (!vma || vma->vm_flags & VM_MAYSHARE) {
5126 /*
5127 * resv_map can not be NULL as hugetlb_reserve_pages is only
5128 * called for inodes for which resv_maps were created (see
5129 * hugetlbfs_get_inode).
5130 */
5131 resv_map = inode_resv_map(inode);
5132
5133 chg = region_chg(resv_map, from, to, ®ions_needed);
5134
5135 } else {
5136 /* Private mapping. */
5137 resv_map = resv_map_alloc();
5138 if (!resv_map)
5139 return false;
5140
5141 chg = to - from;
5142
5143 set_vma_resv_map(vma, resv_map);
5144 set_vma_resv_flags(vma, HPAGE_RESV_OWNER);
5145 }
5146
5147 if (chg < 0)
5148 goto out_err;
5149
5150 if (hugetlb_cgroup_charge_cgroup_rsvd(hstate_index(h),
5151 chg * pages_per_huge_page(h), &h_cg) < 0)
5152 goto out_err;
5153
5154 if (vma && !(vma->vm_flags & VM_MAYSHARE) && h_cg) {
5155 /* For private mappings, the hugetlb_cgroup uncharge info hangs
5156 * of the resv_map.
5157 */
5158 resv_map_set_hugetlb_cgroup_uncharge_info(resv_map, h_cg, h);
5159 }
5160
5161 /*
5162 * There must be enough pages in the subpool for the mapping. If
5163 * the subpool has a minimum size, there may be some global
5164 * reservations already in place (gbl_reserve).
5165 */
5166 gbl_reserve = hugepage_subpool_get_pages(spool, chg);
5167 if (gbl_reserve < 0)
5168 goto out_uncharge_cgroup;
5169
5170 /*
5171 * Check enough hugepages are available for the reservation.
5172 * Hand the pages back to the subpool if there are not
5173 */
5174 if (hugetlb_acct_memory(h, gbl_reserve) < 0)
5175 goto out_put_pages;
5176
5177 /*
5178 * Account for the reservations made. Shared mappings record regions
5179 * that have reservations as they are shared by multiple VMAs.
5180 * When the last VMA disappears, the region map says how much
5181 * the reservation was and the page cache tells how much of
5182 * the reservation was consumed. Private mappings are per-VMA and
5183 * only the consumed reservations are tracked. When the VMA
5184 * disappears, the original reservation is the VMA size and the
5185 * consumed reservations are stored in the map. Hence, nothing
5186 * else has to be done for private mappings here
5187 */
5188 if (!vma || vma->vm_flags & VM_MAYSHARE) {
5189 add = region_add(resv_map, from, to, regions_needed, h, h_cg);
5190
5191 if (unlikely(add < 0)) {
5192 hugetlb_acct_memory(h, -gbl_reserve);
5193 goto out_put_pages;
5194 } else if (unlikely(chg > add)) {
5195 /*
5196 * pages in this range were added to the reserve
5197 * map between region_chg and region_add. This
5198 * indicates a race with alloc_huge_page. Adjust
5199 * the subpool and reserve counts modified above
5200 * based on the difference.
5201 */
5202 long rsv_adjust;
5203
5204 /*
5205 * hugetlb_cgroup_uncharge_cgroup_rsvd() will put the
5206 * reference to h_cg->css. See comment below for detail.
5207 */
5208 hugetlb_cgroup_uncharge_cgroup_rsvd(
5209 hstate_index(h),
5210 (chg - add) * pages_per_huge_page(h), h_cg);
5211
5212 rsv_adjust = hugepage_subpool_put_pages(spool,
5213 chg - add);
5214 hugetlb_acct_memory(h, -rsv_adjust);
5215 } else if (h_cg) {
5216 /*
5217 * The file_regions will hold their own reference to
5218 * h_cg->css. So we should release the reference held
5219 * via hugetlb_cgroup_charge_cgroup_rsvd() when we are
5220 * done.
5221 */
> 5222 css_put(&h_cg->css);
5223 }
5224 }
5225 return true;
5226
5227 out_put_pages:
5228 /* put back original number of pages, chg */
5229 (void)hugepage_subpool_put_pages(spool, chg);
5230 out_uncharge_cgroup:
5231 hugetlb_cgroup_uncharge_cgroup_rsvd(hstate_index(h),
5232 chg * pages_per_huge_page(h), h_cg);
5233 out_err:
5234 if (!vma || vma->vm_flags & VM_MAYSHARE)
5235 /* Only call region_abort if the region_chg succeeded but the
5236 * region_add failed or didn't run.
5237 */
5238 if (chg >= 0 && add < 0)
5239 region_abort(resv_map, from, to, regions_needed);
5240 if (vma && is_vma_resv_set(vma, HPAGE_RESV_OWNER))
5241 kref_put(&resv_map->refs, resv_map_release);
5242 return false;
5243 }
5244
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
otg.c:undefined reference to `usb_gadget_vbus_disconnect'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: c3590c7656fb103db193e3538cb52b420985482c usb: host: ehci-tegra: Remove the driver
date: 7 weeks ago
config: arm64-randconfig-c004-20210301 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.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 c3590c7656fb103db193e3538cb52b420985482c
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm64
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 >>):
aarch64-linux-ld: Unexpected GOT/PLT entries detected!
aarch64-linux-ld: Unexpected run-time procedure linkages detected!
aarch64-linux-ld: drivers/usb/chipidea/otg.o: in function `ci_handle_vbus_change':
>> otg.c:(.text+0x258): undefined reference to `usb_gadget_vbus_disconnect'
>> aarch64-linux-ld: otg.c:(.text+0x268): undefined reference to `usb_gadget_vbus_connect'
aarch64-linux-ld: drivers/usb/chipidea/otg.o: in function `ci_otg_work':
otg.c:(.text+0x42c): undefined reference to `usb_gadget_vbus_disconnect'
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for USB_CHIPIDEA
Depends on USB_SUPPORT && (USB_EHCI_HCD && USB_GADGET || USB_EHCI_HCD && !USB_GADGET || !USB_EHCI_HCD && USB_GADGET && HAS_DMA
Selected by
- USB_EHCI_TEGRA && USB_SUPPORT && USB && USB_EHCI_HCD && ARCH_TEGRA
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
drivers/gpu/drm/msm/msm_gem_submit.c:202 submit_lookup_cmds() warn: impossible condition '(sz == (~0)) => (0-u32max == u64max)'
by Dan Carpenter
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: 20224d715a882210428ea62bba93f1bc4a0afe23 drm/msm/submit: Move copy_from_user ahead of locking bos
config: arm64-randconfig-m031-20210301 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Dan Carpenter <dan.carpenter(a)oracle.com>
smatch warnings:
drivers/gpu/drm/msm/msm_gem_submit.c:202 submit_lookup_cmds() warn: impossible condition '(sz == (~0)) => (0-u32max == u64max)'
vim +202 drivers/gpu/drm/msm/msm_gem_submit.c
20224d715a8822 Rob Clark 2020-10-23 158 static int submit_lookup_cmds(struct msm_gem_submit *submit,
20224d715a8822 Rob Clark 2020-10-23 159 struct drm_msm_gem_submit *args, struct drm_file *file)
20224d715a8822 Rob Clark 2020-10-23 160 {
20224d715a8822 Rob Clark 2020-10-23 161 unsigned i, sz;
20224d715a8822 Rob Clark 2020-10-23 162 int ret = 0;
20224d715a8822 Rob Clark 2020-10-23 163
20224d715a8822 Rob Clark 2020-10-23 164 for (i = 0; i < args->nr_cmds; i++) {
20224d715a8822 Rob Clark 2020-10-23 165 struct drm_msm_gem_submit_cmd submit_cmd;
20224d715a8822 Rob Clark 2020-10-23 166 void __user *userptr =
20224d715a8822 Rob Clark 2020-10-23 167 u64_to_user_ptr(args->cmds + (i * sizeof(submit_cmd)));
20224d715a8822 Rob Clark 2020-10-23 168
20224d715a8822 Rob Clark 2020-10-23 169 ret = copy_from_user(&submit_cmd, userptr, sizeof(submit_cmd));
20224d715a8822 Rob Clark 2020-10-23 170 if (ret) {
20224d715a8822 Rob Clark 2020-10-23 171 ret = -EFAULT;
20224d715a8822 Rob Clark 2020-10-23 172 goto out;
20224d715a8822 Rob Clark 2020-10-23 173 }
20224d715a8822 Rob Clark 2020-10-23 174
20224d715a8822 Rob Clark 2020-10-23 175 /* validate input from userspace: */
20224d715a8822 Rob Clark 2020-10-23 176 switch (submit_cmd.type) {
20224d715a8822 Rob Clark 2020-10-23 177 case MSM_SUBMIT_CMD_BUF:
20224d715a8822 Rob Clark 2020-10-23 178 case MSM_SUBMIT_CMD_IB_TARGET_BUF:
20224d715a8822 Rob Clark 2020-10-23 179 case MSM_SUBMIT_CMD_CTX_RESTORE_BUF:
20224d715a8822 Rob Clark 2020-10-23 180 break;
20224d715a8822 Rob Clark 2020-10-23 181 default:
20224d715a8822 Rob Clark 2020-10-23 182 DRM_ERROR("invalid type: %08x\n", submit_cmd.type);
20224d715a8822 Rob Clark 2020-10-23 183 return -EINVAL;
20224d715a8822 Rob Clark 2020-10-23 184 }
20224d715a8822 Rob Clark 2020-10-23 185
20224d715a8822 Rob Clark 2020-10-23 186 if (submit_cmd.size % 4) {
20224d715a8822 Rob Clark 2020-10-23 187 DRM_ERROR("non-aligned cmdstream buffer size: %u\n",
20224d715a8822 Rob Clark 2020-10-23 188 submit_cmd.size);
20224d715a8822 Rob Clark 2020-10-23 189 ret = -EINVAL;
20224d715a8822 Rob Clark 2020-10-23 190 goto out;
20224d715a8822 Rob Clark 2020-10-23 191 }
20224d715a8822 Rob Clark 2020-10-23 192
20224d715a8822 Rob Clark 2020-10-23 193 submit->cmd[i].type = submit_cmd.type;
20224d715a8822 Rob Clark 2020-10-23 194 submit->cmd[i].size = submit_cmd.size / 4;
20224d715a8822 Rob Clark 2020-10-23 195 submit->cmd[i].offset = submit_cmd.submit_offset / 4;
20224d715a8822 Rob Clark 2020-10-23 196 submit->cmd[i].idx = submit_cmd.submit_idx;
20224d715a8822 Rob Clark 2020-10-23 197 submit->cmd[i].nr_relocs = submit_cmd.nr_relocs;
20224d715a8822 Rob Clark 2020-10-23 198
20224d715a8822 Rob Clark 2020-10-23 199 sz = array_size(submit_cmd.nr_relocs,
20224d715a8822 Rob Clark 2020-10-23 200 sizeof(struct drm_msm_gem_submit_reloc));
20224d715a8822 Rob Clark 2020-10-23 201 /* check for overflow: */
20224d715a8822 Rob Clark 2020-10-23 @202 if (sz == SIZE_MAX) {
^^^^^^^^^^^^^^
"sz" is an u32 so it can't equal ULONG_MAX on 64 bit systems. I would
just leave this check out and let kmalloc() fail with a splat.
20224d715a8822 Rob Clark 2020-10-23 203 ret = -ENOMEM;
20224d715a8822 Rob Clark 2020-10-23 204 goto out;
20224d715a8822 Rob Clark 2020-10-23 205 }
20224d715a8822 Rob Clark 2020-10-23 206 submit->cmd[i].relocs = kmalloc(sz, GFP_KERNEL);
20224d715a8822 Rob Clark 2020-10-23 207 ret = copy_from_user(submit->cmd[i].relocs, userptr, sz);
20224d715a8822 Rob Clark 2020-10-23 208 if (ret) {
20224d715a8822 Rob Clark 2020-10-23 209 ret = -EFAULT;
20224d715a8822 Rob Clark 2020-10-23 210 goto out;
20224d715a8822 Rob Clark 2020-10-23 211 }
The zero day bot will probably send you an email suggesting memdup_user()
here:
tmp = memdup_user(userptr, sz);
if (IS_ERR(copy)) {
ret = PTR_ERR(tmp);
goto out;
}
submit->cmd[i].relocs = tmp;
20224d715a8822 Rob Clark 2020-10-23 212 }
20224d715a8822 Rob Clark 2020-10-23 213
20224d715a8822 Rob Clark 2020-10-23 214 out:
20224d715a8822 Rob Clark 2020-10-23 215 return ret;
20224d715a8822 Rob Clark 2020-10-23 216 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:183:37: warning: taking address of packed member 'rxchain_info' of class or structure 'iwl_phy_context_cmd_tail' may result in an unaligned pointer value
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: a86821069e87755d8f0f98a9bc3e848098dd28e8 iwlwifi: phy-ctxt: add new API VER 3 for phy context cmd
date: 5 months ago
config: mips-randconfig-r011-20210301 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project b077d82b00d81934c7c27ac89dd8b0e7f448bded)
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
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# 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 a86821069e87755d8f0f98a9bc3e848098dd28e8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
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/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:18:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:195:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:18:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:31:
In file included from include/linux/dma-mapping.h:7:
In file included from include/linux/device.h:16:
In file included from include/linux/energy_model.h:10:
include/linux/sched/topology.h:254:9: error: implicit declaration of function 'cpu_logical_map' [-Werror,-Wimplicit-function-declaration]
return cpu_to_node(task_cpu(p));
^
arch/mips/include/asm/mach-loongson64/topology.h:7:27: note: expanded from macro 'cpu_to_node'
#define cpu_to_node(cpu) (cpu_logical_map(cpu) >> 2)
^
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:20:
In file included from include/linux/ieee80211.h:20:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:554:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:20:
In file included from include/linux/ieee80211.h:20:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:554:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:22:
In file included from include/net/codel.h:48:
In file included from include/net/inet_ecn.h:9:
In file included from include/net/inet_sock.h:22:
In file included from include/net/sock.h:61:
include/linux/poll.h:142:27: warning: division by zero is undefined [-Wdivision-by-zero]
M(RDNORM) | M(RDBAND) | M(WRNORM) | M(WRBAND) |
^~~~~~~~~
include/linux/poll.h:140:32: note: expanded from macro 'M'
#define M(X) (__force __poll_t)__MAP(val, POLL##X, (__force __u16)EPOLL##X)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/poll.h:126:51: note: expanded from macro '__MAP'
(from < to ? (v & from) * (to/from) : (v & from) / (from/to))
^ ~~~~~~~~~
include/linux/poll.h:142:39: warning: division by zero is undefined [-Wdivision-by-zero]
M(RDNORM) | M(RDBAND) | M(WRNORM) | M(WRBAND) |
^~~~~~~~~
include/linux/poll.h:140:32: note: expanded from macro 'M'
#define M(X) (__force __poll_t)__MAP(val, POLL##X, (__force __u16)EPOLL##X)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/poll.h:126:51: note: expanded from macro '__MAP'
(from < to ? (v & from) * (to/from) : (v & from) / (from/to))
^ ~~~~~~~~~
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:22:
In file included from include/net/codel.h:48:
In file included from include/net/inet_ecn.h:9:
In file included from include/net/inet_sock.h:22:
include/net/sock.h:1969:12: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
old_dst = xchg((__force struct dst_entry **)&sk->sk_dst_cache, dst);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:64:
In file included from include/net/mac80211.h:22:
In file included from include/net/codel.h:48:
In file included from include/net/inet_ecn.h:9:
In file included from include/net/inet_sock.h:22:
include/net/sock.h:2219:8: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
err = xchg(&sk->sk_err, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
>> drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:183:37: warning: taking address of packed member 'rxchain_info' of class or structure 'iwl_phy_context_cmd_tail' may result in an unaligned pointer value [-Waddress-of-packed-member]
iwl_mvm_phy_ctxt_set_rxchain(mvm, &tail->rxchain_info,
^~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c:206:37: warning: taking address of packed member 'rxchain_info' of class or structure 'iwl_phy_context_cmd' may result in an unaligned pointer value [-Waddress-of-packed-member]
iwl_mvm_phy_ctxt_set_rxchain(mvm, &cmd->rxchain_info,
^~~~~~~~~~~~~~~~~
20 warnings and 5 errors generated.
vim +183 drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c
168
169 /*
170 * Add the phy configuration to the PHY context command
171 */
172 static void iwl_mvm_phy_ctxt_cmd_data_v1(struct iwl_mvm *mvm,
173 struct iwl_phy_context_cmd_v1 *cmd,
174 struct cfg80211_chan_def *chandef,
175 u8 chains_static, u8 chains_dynamic)
176 {
177 struct iwl_phy_context_cmd_tail *tail =
178 iwl_mvm_chan_info_cmd_tail(mvm, &cmd->ci);
179
180 /* Set the channel info data */
181 iwl_mvm_set_chan_info_chandef(mvm, &cmd->ci, chandef);
182
> 183 iwl_mvm_phy_ctxt_set_rxchain(mvm, &tail->rxchain_info,
184 chains_static, chains_dynamic);
185
186 tail->txchain_info = cpu_to_le32(iwl_mvm_get_valid_tx_ant(mvm));
187 }
188
189 /*
190 * Add the phy configuration to the PHY context command
191 */
192 static void iwl_mvm_phy_ctxt_cmd_data(struct iwl_mvm *mvm,
193 struct iwl_phy_context_cmd *cmd,
194 struct cfg80211_chan_def *chandef,
195 u8 chains_static, u8 chains_dynamic)
196 {
197 if (chandef->chan->band == NL80211_BAND_2GHZ ||
198 !iwl_mvm_is_cdb_supported(mvm))
199 cmd->lmac_id = cpu_to_le32(IWL_LMAC_24G_INDEX);
200 else
201 cmd->lmac_id = cpu_to_le32(IWL_LMAC_5G_INDEX);
202
203 /* Set the channel info data */
204 iwl_mvm_set_chan_info_chandef(mvm, &cmd->ci, chandef);
205
> 206 iwl_mvm_phy_ctxt_set_rxchain(mvm, &cmd->rxchain_info,
207 chains_static, chains_dynamic);
208 }
209
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
Re: [jarkko-linux-tpmdd:master 16/17] COPYING CREDITS Documentation Kbuild Kconfig LICENSES MAINTAINERS Makefile README arch block certs crypto drivers fs include init ipc kernel lib mm net samples scripts security sound tools usr virt No rule to make target 'security/keys/trusted-keys/tpm2key.asn1.h', needed by 'security/keys/trusted-keys/trusted_tpm2.o'.
by Jarkko Sakkinen
On Fri, Feb 26, 2021 at 05:06:18PM -0800, James Bottomley wrote:
> On Wed, 2021-02-24 at 18:49 +0200, Jarkko Sakkinen wrote:
> > On Sun, Feb 21, 2021 at 12:48:33PM -0800, James Bottomley wrote:
> > > On Sun, 2021-02-21 at 04:10 +0200, Jarkko Sakkinen wrote:
> > > > James,
> > > >
> > > > Any clue, I can fix this inline, if you could check the issue and
> > > > tell what to do. Thanks.
> > >
> > > OK, I found the issue. In commit
> > >
> > > commit 6bf16dc226a0593a197c4c9648d089a8a3e7799b
> > > Author: James Bottomley <James.Bottomley(a)HansenPartnership.com>
> > > Date: Wed Jan 27 11:06:16 2021 -0800
> > >
> > > security: keys: trusted: use ASN.1 TPM2 key format for the
> > > blobs
> > >
> > >
> > > You managed to lose the
> > >
> > > security/keys/trusted-keys/tpm2key.asn1
> > >
> > > File.
> > >
> > > So this isn't even a cross compile error.
> > >
> > > James
> > >
> > >
> > >
> >
> > Can you send a new version with fixes that I fixed manually, i.e.
> > checkpatch error and:
> >
> > $(obj)/trusted_tpm2.o: $(obj)/tpm2key.asn1.h
> > trusted-y += trusted_tpm2.o
> > trusted-y += tpm2key.asn1.o
> >
> > I.e. separate lines.
> >
> > I'll just apply that.
>
> This is the patch you did with tpm2key.asn1 manually added. It's
> passed all my build and run tests (so far).
>
> James
Send a full patch set so that I can then apply it from patchwork.
/Jarkko
1 year, 2 months
[kbuild] [chanwoo:devfreq-testing-passive-gov 3/3] drivers/devfreq/governor_passive.c:251 cpufreq_passive_notifier_call() warn: variable dereferenced before check 'freqs' (see line 247)
by Dan Carpenter
tree: https://git.kernel.org/pub/scm/linux/kernel/git/chanwoo/linux.git devfreq-testing-passive-gov
head: 82d4ff586ae2fb6d89cad871949004bed3438ccb
commit: 82d4ff586ae2fb6d89cad871949004bed3438ccb [3/3] PM / devfreq: Add cpu based scaling support to passive governor
config: x86_64-randconfig-m001-20210301 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Dan Carpenter <dan.carpenter(a)oracle.com>
New smatch warnings:
drivers/devfreq/governor_passive.c:251 cpufreq_passive_notifier_call() warn: variable dereferenced before check 'freqs' (see line 247)
drivers/devfreq/governor_passive.c:403 devfreq_passive_event_handler() warn: ignoring unreachable code.
Old smatch warnings:
drivers/devfreq/governor_passive.c:339 cpufreq_passive_register() warn: possible memory leak of 'state'
drivers/devfreq/governor_passive.c:348 cpufreq_passive_register() warn: possible memory leak of 'state'
vim +/freqs +251 drivers/devfreq/governor_passive.c
82d4ff586ae2fb Saravana Kannan 2021-03-01 239 static int cpufreq_passive_notifier_call(struct notifier_block *nb,
82d4ff586ae2fb Saravana Kannan 2021-03-01 240 unsigned long event, void *ptr)
82d4ff586ae2fb Saravana Kannan 2021-03-01 241 {
82d4ff586ae2fb Saravana Kannan 2021-03-01 242 struct devfreq_passive_data *data =
82d4ff586ae2fb Saravana Kannan 2021-03-01 243 container_of(nb, struct devfreq_passive_data, nb);
82d4ff586ae2fb Saravana Kannan 2021-03-01 244 struct devfreq *devfreq = (struct devfreq *)data->this;
82d4ff586ae2fb Saravana Kannan 2021-03-01 245 struct devfreq_cpu_state *cpu_state;
82d4ff586ae2fb Saravana Kannan 2021-03-01 246 struct cpufreq_freqs *freqs = ptr;
82d4ff586ae2fb Saravana Kannan 2021-03-01 @247 unsigned long freq = freqs->new;
^^^^^^^^^^
Dereferenced.
82d4ff586ae2fb Saravana Kannan 2021-03-01 248 unsigned int cur_freq;
82d4ff586ae2fb Saravana Kannan 2021-03-01 249 int ret;
82d4ff586ae2fb Saravana Kannan 2021-03-01 250
82d4ff586ae2fb Saravana Kannan 2021-03-01 @251 if (event != CPUFREQ_POSTCHANGE || !freqs ||
^^^^^^
Checked too late.
82d4ff586ae2fb Saravana Kannan 2021-03-01 252 !data->cpu_state[freqs->policy->cpu])
82d4ff586ae2fb Saravana Kannan 2021-03-01 253 return 0;
82d4ff586ae2fb Saravana Kannan 2021-03-01 254
82d4ff586ae2fb Saravana Kannan 2021-03-01 255 cpu_state = data->cpu_state[freqs->policy->cpu];
82d4ff586ae2fb Saravana Kannan 2021-03-01 256 if (cpu_state->freq == freqs->new)
82d4ff586ae2fb Saravana Kannan 2021-03-01 257 return 0;
82d4ff586ae2fb Saravana Kannan 2021-03-01 258
82d4ff586ae2fb Saravana Kannan 2021-03-01 259 /* Backup current freq and pre-update cpu state freq*/
82d4ff586ae2fb Saravana Kannan 2021-03-01 260 cur_freq = cpu_state->freq;
82d4ff586ae2fb Saravana Kannan 2021-03-01 261 cpu_state->freq = freqs->new;
82d4ff586ae2fb Saravana Kannan 2021-03-01 262
82d4ff586ae2fb Saravana Kannan 2021-03-01 263 mutex_lock(&devfreq->lock);
82d4ff586ae2fb Saravana Kannan 2021-03-01 264 ret = devfreq_update_target(devfreq, freq);
82d4ff586ae2fb Saravana Kannan 2021-03-01 265 mutex_unlock(&devfreq->lock);
82d4ff586ae2fb Saravana Kannan 2021-03-01 266 if (ret) {
82d4ff586ae2fb Saravana Kannan 2021-03-01 267 cpu_state->freq = cur_freq;
82d4ff586ae2fb Saravana Kannan 2021-03-01 268 dev_err(&devfreq->dev, "Couldn't update the frequency.\n");
82d4ff586ae2fb Saravana Kannan 2021-03-01 269 return ret;
82d4ff586ae2fb Saravana Kannan 2021-03-01 270 }
82d4ff586ae2fb Saravana Kannan 2021-03-01 271
82d4ff586ae2fb Saravana Kannan 2021-03-01 272 return 0;
82d4ff586ae2fb Saravana Kannan 2021-03-01 273 }
[ snip! ]
996133119f5733 Chanwoo Choi 2016-03-22 374 static int devfreq_passive_event_handler(struct devfreq *devfreq,
996133119f5733 Chanwoo Choi 2016-03-22 375 unsigned int event, void *data)
996133119f5733 Chanwoo Choi 2016-03-22 376 {
996133119f5733 Chanwoo Choi 2016-03-22 377 struct devfreq_passive_data *p_data
996133119f5733 Chanwoo Choi 2016-03-22 378 = (struct devfreq_passive_data *)devfreq->data;
996133119f5733 Chanwoo Choi 2016-03-22 379 struct devfreq *parent = (struct devfreq *)p_data->parent;
996133119f5733 Chanwoo Choi 2016-03-22 380 struct notifier_block *nb = &p_data->nb;
996133119f5733 Chanwoo Choi 2016-03-22 381 int ret = 0;
996133119f5733 Chanwoo Choi 2016-03-22 382
82d4ff586ae2fb Saravana Kannan 2021-03-01 383 if (p_data->parent_type == DEVFREQ_PARENT_DEV && !parent)
996133119f5733 Chanwoo Choi 2016-03-22 384 return -EPROBE_DEFER;
996133119f5733 Chanwoo Choi 2016-03-22 385
996133119f5733 Chanwoo Choi 2016-03-22 386 switch (event) {
996133119f5733 Chanwoo Choi 2016-03-22 387 case DEVFREQ_GOV_START:
996133119f5733 Chanwoo Choi 2016-03-22 388 if (!p_data->this)
996133119f5733 Chanwoo Choi 2016-03-22 389 p_data->this = devfreq;
996133119f5733 Chanwoo Choi 2016-03-22 390
82d4ff586ae2fb Saravana Kannan 2021-03-01 391 if (p_data->parent_type == DEVFREQ_PARENT_DEV) {
996133119f5733 Chanwoo Choi 2016-03-22 392 nb->notifier_call = devfreq_passive_notifier_call;
0ef7c7cce43f6e Leonard Crestez 2019-08-08 393 ret = devfreq_register_notifier(parent, nb,
996133119f5733 Chanwoo Choi 2016-03-22 394 DEVFREQ_TRANSITION_NOTIFIER);
82d4ff586ae2fb Saravana Kannan 2021-03-01 395 } else if (p_data->parent_type == CPUFREQ_PARENT_DEV) {
82d4ff586ae2fb Saravana Kannan 2021-03-01 396 ret = cpufreq_passive_register(&p_data);
82d4ff586ae2fb Saravana Kannan 2021-03-01 397 } else {
82d4ff586ae2fb Saravana Kannan 2021-03-01 398 ret = -EINVAL;
82d4ff586ae2fb Saravana Kannan 2021-03-01 399 }
996133119f5733 Chanwoo Choi 2016-03-22 400 break;
996133119f5733 Chanwoo Choi 2016-03-22 401 case DEVFREQ_GOV_STOP:
82d4ff586ae2fb Saravana Kannan 2021-03-01 402 break;
^^^^^^
82d4ff586ae2fb Saravana Kannan 2021-03-01 @403 if (p_data->parent_type == DEVFREQ_PARENT_DEV)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Unreachable code
0ef7c7cce43f6e Leonard Crestez 2019-08-08 404 WARN_ON(devfreq_unregister_notifier(parent, nb,
0ef7c7cce43f6e Leonard Crestez 2019-08-08 405 DEVFREQ_TRANSITION_NOTIFIER));
82d4ff586ae2fb Saravana Kannan 2021-03-01 406 else if (p_data->parent_type == CPUFREQ_PARENT_DEV)
82d4ff586ae2fb Saravana Kannan 2021-03-01 407 WARN_ON(cpufreq_passive_unregister(&p_data));
82d4ff586ae2fb Saravana Kannan 2021-03-01 408 else
82d4ff586ae2fb Saravana Kannan 2021-03-01 409 ret = -EINVAL;
996133119f5733 Chanwoo Choi 2016-03-22 410 break;
996133119f5733 Chanwoo Choi 2016-03-22 411 default:
996133119f5733 Chanwoo Choi 2016-03-22 412 break;
996133119f5733 Chanwoo Choi 2016-03-22 413 }
996133119f5733 Chanwoo Choi 2016-03-22 414
996133119f5733 Chanwoo Choi 2016-03-22 415 return ret;
996133119f5733 Chanwoo Choi 2016-03-22 416 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
_______________________________________________
kbuild mailing list -- kbuild(a)lists.01.org
To unsubscribe send an email to kbuild-leave(a)lists.01.org
1 year, 2 months
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: pasting "LOCHNAGAR1_" and "(" does not give a valid preprocessing token
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 61556703b610a104de324e4f061dc6cf7b218b46
commit: 0548448b719ac78fa18fdbcd03856952ba6cc7dc pinctrl: lochnagar: Add support for the Cirrus Logic Lochnagar
date: 1 year, 10 months ago
config: mips-randconfig-r012-20210209 (attached as .config)
compiler: mipsel-linux-gcc (GCC) 9.3.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 0548448b719ac78fa18fdbcd03856952ba6cc7dc
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross 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 >>):
>> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: pasting "LOCHNAGAR1_" and "(" does not give a valid preprocessing token
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: note: in expansion of macro 'LN1_PIN_GPIO'
200 | LN1_PIN_GPIO(CDC_RESET, "codec-reset", RST, CDC_RESET, 1);
| ^~~~~~~~~~~~
>> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: implicit declaration of function 'LOCHNAGAR1_'; did you mean 'LOCHNAGAR1_RST'? [-Werror=implicit-function-declaration]
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: note: in expansion of macro 'LN1_PIN_GPIO'
200 | LN1_PIN_GPIO(CDC_RESET, "codec-reset", RST, CDC_RESET, 1);
| ^~~~~~~~~~~~
>> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: initializer element is not constant
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: note: in expansion of macro 'LN1_PIN_GPIO'
200 | LN1_PIN_GPIO(CDC_RESET, "codec-reset", RST, CDC_RESET, 1);
| ^~~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: note: (near initialization for 'lochnagar1_CDC_RESET_pin.reg')
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: note: in expansion of macro 'LN1_PIN_GPIO'
200 | LN1_PIN_GPIO(CDC_RESET, "codec-reset", RST, CDC_RESET, 1);
| ^~~~~~~~~~~~
>> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: pasting "LOCHNAGAR1_" and "(" does not give a valid preprocessing token
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:201:1: note: in expansion of macro 'LN1_PIN_GPIO'
201 | LN1_PIN_GPIO(DSP_RESET, "dsp-reset", RST, DSP_RESET, 1);
| ^~~~~~~~~~~~
>> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: error: initializer element is not constant
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:201:1: note: in expansion of macro 'LN1_PIN_GPIO'
201 | LN1_PIN_GPIO(DSP_RESET, "dsp-reset", RST, DSP_RESET, 1);
| ^~~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:46: note: (near initialization for 'lochnagar1_DSP_RESET_pin.reg')
52 | .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
| ^~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: in expansion of macro 'LN_PIN_GPIO'
67 | LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
| ^~~~~~~~~~~
drivers/pinctrl/cirrus/pinctrl-lochnagar.c:201:1: note: in expansion of macro 'LN1_PIN_GPIO'
201 | LN1_PIN_GPIO(DSP_RESET, "dsp-reset", RST, DSP_RESET, 1);
| ^~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +52 drivers/pinctrl/cirrus/pinctrl-lochnagar.c
49
50 #define LN_PIN_GPIO(REV, ID, NAME, REG, SHIFT, INVERT) \
51 static const struct lochnagar_pin lochnagar##REV##_##ID##_pin = { \
> 52 .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
53 .shift = LOCHNAGAR##REV##_##SHIFT##_SHIFT, .invert = INVERT, \
54 }
55
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months