drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c:817 dpu_crtc_enable() error: uninitialized symbol 'request_bandwidth'.
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: 241b507c166fef3e461e5daf562d8e41aa41bf15 drm/msm/dpu: fix "frame done" timeouts
date: 11 months ago
config: arm64-randconfig-m031-20200811 (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>
smatch warnings:
drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c:817 dpu_crtc_enable() error: uninitialized symbol 'request_bandwidth'.
vim +/request_bandwidth +817 drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c
786
787 static void dpu_crtc_enable(struct drm_crtc *crtc,
788 struct drm_crtc_state *old_crtc_state)
789 {
790 struct dpu_crtc *dpu_crtc;
791 struct drm_encoder *encoder;
792 struct msm_drm_private *priv;
793 bool request_bandwidth;
794
795 if (!crtc || !crtc->dev || !crtc->dev->dev_private) {
796 DPU_ERROR("invalid crtc\n");
797 return;
798 }
799 priv = crtc->dev->dev_private;
800
801 pm_runtime_get_sync(crtc->dev->dev);
802
803 DRM_DEBUG_KMS("crtc%d\n", crtc->base.id);
804 dpu_crtc = to_dpu_crtc(crtc);
805
806 drm_for_each_encoder_mask(encoder, crtc->dev, crtc->state->encoder_mask) {
807 /* in video mode, we hold an extra bandwidth reference
808 * as we cannot drop bandwidth at frame-done if any
809 * crtc is being used in video mode.
810 */
811 if (dpu_encoder_get_intf_mode(encoder) == INTF_MODE_VIDEO)
812 request_bandwidth = true;
813 dpu_encoder_register_frame_event_callback(encoder,
814 dpu_crtc_frame_event_cb, (void *)crtc);
815 }
816
> 817 if (request_bandwidth)
818 atomic_inc(&_dpu_crtc_get_kms(crtc)->bandwidth_ref);
819
820 trace_dpu_crtc_enable(DRMID(crtc), true, dpu_crtc);
821 dpu_crtc->enabled = true;
822
823 drm_for_each_encoder_mask(encoder, crtc->dev, crtc->state->encoder_mask)
824 dpu_encoder_assign_crtc(encoder, crtc);
825
826 /* Enable/restore vblank irq handling */
827 drm_crtc_vblank_on(crtc);
828 }
829
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
[intel-linux-intel-lts:5.4/yocto 1516/9195] drivers/i2c/busses/i2c-virtio.c:80:46: sparse: sparse: incorrect type in argument 1 (different base types)
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: 87241c08286384feb3ddc57d4cb0daca4be1e384
commit: eb1a47484bcfad11d9299b9ae659bde9290e8649 [1516/9195] add support for virtio-i2c FE driver
config: nios2-randconfig-s031-20200811 (attached as .config)
compiler: nios2-linux-gcc (GCC) 9.3.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.2-168-g9554805c-dirty
git checkout eb1a47484bcfad11d9299b9ae659bde9290e8649
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=nios2
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 >>)
drivers/i2c/busses/i2c-virtio.c:75:24: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __virtio16 [usertype] addr @@ got unsigned short [usertype] addr @@
drivers/i2c/busses/i2c-virtio.c:75:24: sparse: expected restricted __virtio16 [usertype] addr
drivers/i2c/busses/i2c-virtio.c:75:24: sparse: got unsigned short [usertype] addr
drivers/i2c/busses/i2c-virtio.c:76:25: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __virtio16 [usertype] flags @@ got unsigned short [usertype] flags @@
drivers/i2c/busses/i2c-virtio.c:76:25: sparse: expected restricted __virtio16 [usertype] flags
drivers/i2c/busses/i2c-virtio.c:76:25: sparse: got unsigned short [usertype] flags
drivers/i2c/busses/i2c-virtio.c:77:23: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __virtio16 [usertype] len @@ got unsigned short [usertype] len @@
drivers/i2c/busses/i2c-virtio.c:77:23: sparse: expected restricted __virtio16 [usertype] len
drivers/i2c/busses/i2c-virtio.c:77:23: sparse: got unsigned short [usertype] len
>> drivers/i2c/busses/i2c-virtio.c:80:46: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int [usertype] size @@ got restricted __virtio16 [usertype] len @@
>> drivers/i2c/busses/i2c-virtio.c:80:46: sparse: expected unsigned int [usertype] size
drivers/i2c/busses/i2c-virtio.c:80:46: sparse: got restricted __virtio16 [usertype] len
drivers/i2c/busses/i2c-virtio.c:85:30: sparse: sparse: restricted __virtio16 degrades to integer
drivers/i2c/busses/i2c-virtio.c:167:40: sparse: sparse: restricted __virtio16 degrades to integer
>> drivers/i2c/busses/i2c-virtio.c:168:75: sparse: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned int [usertype] count @@ got restricted __virtio16 [usertype] len @@
>> drivers/i2c/busses/i2c-virtio.c:168:75: sparse: expected unsigned int [usertype] count
drivers/i2c/busses/i2c-virtio.c:168:75: sparse: got restricted __virtio16 [usertype] len
vim +80 drivers/i2c/busses/i2c-virtio.c
67
68 static int virtio_queue_add_msg(struct virtqueue *vq,
69 struct virtio_i2c_msg *vmsg,
70 struct i2c_msg *msg)
71 {
72 struct scatterlist *sgs[3], hdr, bout, bin, status;
73 int outcnt = 0, incnt = 0;
74
75 vmsg->hdr.addr = msg->addr;
76 vmsg->hdr.flags = msg->flags;
77 vmsg->hdr.len = msg->len;
78
79 if (vmsg->hdr.len)
> 80 vmsg->buf = kzalloc(vmsg->hdr.len, GFP_KERNEL);
81
82 sg_init_one(&hdr, &vmsg->hdr, sizeof(struct virtio_i2c_hdr));
83 sgs[outcnt++] = &hdr;
84 if (vmsg->buf) {
85 if (vmsg->hdr.flags & I2C_M_RD) {
86 sg_init_one(&bin, vmsg->buf, msg->len);
87 sgs[outcnt + incnt++] = &bin;
88 } else {
89 memcpy(vmsg->buf, msg->buf, msg->len);
90 sg_init_one(&bout, vmsg->buf, msg->len);
91 sgs[outcnt++] = &bout;
92 }
93 }
94 sg_init_one(&status, &vmsg->status, 1);
95 sgs[outcnt + incnt++] = &status;
96
97 return virtqueue_add_sgs(vq, sgs, outcnt, incnt, vmsg, GFP_KERNEL);
98 }
99
100 static int virtio_xfer(struct i2c_adapter *adap, struct i2c_msg *msgs, int num)
101 {
102 struct virtio_i2c *virtio_i2c = i2c_get_adapdata(adap);
103 struct virtqueue *vq = virtio_i2c->msg_vq.vq;
104 struct virtio_i2c_msg *vmsg, *msg_r;
105 int len, i, ret;
106 unsigned long time_left;
107
108 ret = 0;
109 if (unlikely(!vq))
110 return ret;
111
112 vmsg = kzalloc(sizeof(*vmsg), GFP_KERNEL);
113 if (unlikely(!vmsg))
114 return ret;
115
116 mutex_lock(&virtio_i2c->i2c_lock);
117 vmsg->buf = NULL;
118 for (i = 0; i < num; i++) {
119 dev_dbg(&adap->dev,
120 "start to add msg[%d]: addr:0x%x \n",
121 i,
122 msgs[i].addr);
123
124 ret = virtio_queue_add_msg(vq, vmsg, &msgs[i]);
125 if (ret) {
126 dev_err(&adap->dev,
127 "failed to add msg[%d] to virtqueue\n",
128 i);
129 ret = 0;
130 goto err;
131 }
132
133 virtqueue_kick(vq);
134 dev_dbg(&adap->dev, "wait for complete...\n");
135 /*wait for complete*/
136 time_left = wait_for_completion_timeout(&virtio_i2c->completion,
137 adap->timeout);
138 if (!time_left) {
139 dev_err(&adap->dev,
140 "msg[%d]: addr=0x%x timeout\n",
141 i,
142 msgs[i].addr);
143 ret = i ? (i - 1) : 0;
144 goto err;
145 }
146 msg_r = (struct virtio_i2c_msg *)virtqueue_get_buf(vq, &len);
147 if (msg_r) {
148 /* msg_r should point to the same address with vmsg */
149 if (msg_r != vmsg) {
150 dev_err(&adap->dev,
151 "msg[%d]: addr=0x%x virtqueue error \n",
152 i,
153 msg_r->hdr.addr);
154 ret = i - 1;
155 goto err;
156 }
157
158 if (msg_r->status != VIRTIO_I2C_MSG_OK) {
159 dev_dbg(&adap->dev,
160 "msg[%d]: addr=0x%x error=%d \n",
161 i,
162 msg_r->hdr.addr,
163 msg_r->status);
164 ret = i - 1;
165 goto err;
166 }
167 if ((msg_r->hdr.flags & I2C_M_RD) && msg_r->hdr.len)
> 168 memcpy(msgs[i].buf, msg_r->buf, msg_r->hdr.len);
169 kfree(msg_r->buf);
170 msg_r->buf = NULL;
171 }
172 reinit_completion(&virtio_i2c->completion);
173 dev_dbg(&adap->dev, "msg[%d] ok \n", i);
174 }
175 if (i == num)
176 ret = num;
177
178 err:
179 mutex_unlock(&virtio_i2c->i2c_lock);
180 if (vmsg) {
181 kfree(vmsg->buf);
182 vmsg->buf = NULL;
183 kfree(vmsg);
184 }
185 return ret;
186 }
187
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
drivers/tty/cyclades.c:3084:41: sparse: sparse: incorrect type in argument 1 (different address spaces)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date: 8 weeks ago
config: mips-randconfig-s031-20200811 (attached as .config)
compiler: mips64-linux-gcc (GCC) 9.3.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.2-168-g9554805c-dirty
git checkout 670d0a4b10704667765f7d18f7592993d02783aa
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=mips
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 >>)
drivers/tty/cyclades.c:3077:68: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct FIRM_ID *firm_id @@ got void [noderef] __iomem * @@
drivers/tty/cyclades.c:3077:68: sparse: expected struct FIRM_ID *firm_id
drivers/tty/cyclades.c:3077:68: sparse: got void [noderef] __iomem *
>> drivers/tty/cyclades.c:3084:41: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int * @@
>> drivers/tty/cyclades.c:3084:41: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/cyclades.c:3084:41: sparse: got unsigned int *
drivers/tty/cyclades.c:3083:34: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct ZFW_CTRL *zfw_ctrl @@ got void [noderef] __iomem * @@
drivers/tty/cyclades.c:3083:34: sparse: expected struct ZFW_CTRL *zfw_ctrl
drivers/tty/cyclades.c:3083:34: sparse: got void [noderef] __iomem *
drivers/tty/cyclades.c:3085:45: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct CH_CTRL [noderef] __iomem *ch_ctrl @@ got struct CH_CTRL * @@
drivers/tty/cyclades.c:3085:45: sparse: expected struct CH_CTRL [noderef] __iomem *ch_ctrl
drivers/tty/cyclades.c:3085:45: sparse: got struct CH_CTRL *
drivers/tty/cyclades.c:3086:46: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct BUF_CTRL [noderef] __iomem *buf_ctrl @@ got struct BUF_CTRL * @@
drivers/tty/cyclades.c:3086:46: sparse: expected struct BUF_CTRL [noderef] __iomem *buf_ctrl
drivers/tty/cyclades.c:3086:46: sparse: got struct BUF_CTRL *
drivers/tty/cyclades.c: note: in included file (through arch/mips/include/asm/mmiowb.h, include/linux/spinlock.h, include/linux/seqlock.h, ...):
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
arch/mips/include/asm/io.h:354:1: sparse: sparse: cast to restricted __le32
--
>> drivers/tty/serial/ip22zilog.c:114:22: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
>> drivers/tty/serial/ip22zilog.c:114:22: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:114:22: sparse: got unsigned char volatile *
>> drivers/tty/serial/ip22zilog.c:116:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
>> drivers/tty/serial/ip22zilog.c:116:25: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:116:25: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:125:22: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:125:22: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:125:22: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:127:24: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:127:24: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:127:24: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:138:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:138:33: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:138:33: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:144:24: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:144:24: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:144:24: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:148:42: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:148:42: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:148:42: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:170:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:170:26: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:170:26: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:256:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:256:29: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:256:29: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:263:42: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:263:42: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:263:42: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:268:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:268:29: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:268:29: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:318:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:318:25: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:318:25: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:321:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:321:30: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:321:30: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:361:47: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:361:47: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:361:47: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:390:42: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:390:42: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:390:42: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:408:40: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:408:40: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:408:40: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:421:27: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:421:27: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:421:27: sparse: got unsigned char volatile *
>> drivers/tty/serial/ip22zilog.c:432:27: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:441:44: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:441:44: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:441:44: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:459:27: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:464:44: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:464:44: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:464:44: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:546:41: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:580:41: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:586:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:586:25: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:586:25: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:597:39: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:597:39: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:597:39: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:608:48: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:608:48: sparse: expected void volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:608:48: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:629:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:641:41: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:658:41: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:691:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:701:27: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:715:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:722:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:722:34: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:722:34: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:782:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:896:41: sparse: sparse: cast removes address space '__iomem' of expression
>> drivers/tty/serial/ip22zilog.c:1100:57: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected unsigned char [noderef] __iomem *membase @@ got char * @@
>> drivers/tty/serial/ip22zilog.c:1100:57: sparse: expected unsigned char [noderef] __iomem *membase
drivers/tty/serial/ip22zilog.c:1100:57: sparse: got char *
drivers/tty/serial/ip22zilog.c:1101:57: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected unsigned char [noderef] __iomem *membase @@ got char * @@
drivers/tty/serial/ip22zilog.c:1101:57: sparse: expected unsigned char [noderef] __iomem *membase
drivers/tty/serial/ip22zilog.c:1101:57: sparse: got char *
>> drivers/tty/serial/ip22zilog.c:1205:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got void * @@
>> drivers/tty/serial/ip22zilog.c:1205:29: sparse: expected void const volatile [noderef] __iomem *addr
drivers/tty/serial/ip22zilog.c:1205:29: sparse: got void *
drivers/tty/serial/ip22zilog.c:1209:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got void * @@
drivers/tty/serial/ip22zilog.c:1209:34: sparse: expected void const volatile [noderef] __iomem *addr
drivers/tty/serial/ip22zilog.c:1209:34: sparse: got void *
drivers/tty/serial/ip22zilog.c:494:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:495:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:495:25: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:495:25: sparse: got unsigned char volatile *
drivers/tty/serial/ip22zilog.c:494:19: sparse: sparse: cast removes address space '__iomem' of expression
drivers/tty/serial/ip22zilog.c:495:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
drivers/tty/serial/ip22zilog.c:495:25: sparse: expected void const volatile [noderef] __iomem *mem
drivers/tty/serial/ip22zilog.c:495:25: sparse: got unsigned char volatile *
--
>> drivers/misc/mic/vop/vop_main.c:551:58: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got restricted __le64 * @@
>> drivers/misc/mic/vop/vop_main.c:551:58: sparse: expected void const volatile [noderef] __iomem *mem
drivers/misc/mic/vop/vop_main.c:551:58: sparse: got restricted __le64 *
drivers/misc/mic/vop/vop_main.c:560:49: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct mic_device_ctrl *dc @@ got struct mic_device_ctrl [noderef] __iomem *dc @@
drivers/misc/mic/vop/vop_main.c:560:49: sparse: expected struct mic_device_ctrl *dc
drivers/misc/mic/vop/vop_main.c:560:49: sparse: got struct mic_device_ctrl [noderef] __iomem *dc
drivers/misc/mic/vop/vop_main.c:579:49: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct mic_device_ctrl *dc @@ got struct mic_device_ctrl [noderef] __iomem *dc @@
drivers/misc/mic/vop/vop_main.c:579:49: sparse: expected struct mic_device_ctrl *dc
drivers/misc/mic/vop/vop_main.c:579:49: sparse: got struct mic_device_ctrl [noderef] __iomem *dc
drivers/misc/mic/vop/vop_main.c: note: in included file (through arch/mips/include/asm/mmiowb.h, include/linux/spinlock.h, include/linux/seqlock.h, ...):
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
arch/mips/include/asm/io.h:356:1: sparse: sparse: cast to restricted __le64
vim +3084 drivers/tty/cyclades.c
f0737579424dd2 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3040
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3041 /*
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3042 * ---------------------------------------------------------------------
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3043 * cy_init() and friends
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3044 *
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3045 * cy_init() is called at boot-time to initialize the serial driver.
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3046 * ---------------------------------------------------------------------
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3047 */
^1da177e4c3f41 drivers/char/cyclades.c Linus Torvalds 2005-04-16 3048
9671f09921d93e drivers/tty/cyclades.c Bill Pemberton 2012-11-19 3049 static int cy_init_card(struct cyclades_card *cinfo)
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3050 {
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3051 struct cyclades_port *info;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3052 unsigned int channel, port;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3053
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3054 spin_lock_init(&cinfo->card_lock);
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3055 cinfo->intr_enabled = 0;
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3056
963118eef9e670 drivers/char/cyclades.c Jiri Slaby 2009-06-11 3057 cinfo->ports = kcalloc(cinfo->nports, sizeof(*cinfo->ports),
963118eef9e670 drivers/char/cyclades.c Jiri Slaby 2009-06-11 3058 GFP_KERNEL);
dd025c0c7a047b drivers/char/cyclades.c Jiri Slaby 2007-05-08 3059 if (cinfo->ports == NULL) {
dd025c0c7a047b drivers/char/cyclades.c Jiri Slaby 2007-05-08 3060 printk(KERN_ERR "Cyclades: cannot allocate ports\n");
dd025c0c7a047b drivers/char/cyclades.c Jiri Slaby 2007-05-08 3061 return -ENOMEM;
dd025c0c7a047b drivers/char/cyclades.c Jiri Slaby 2007-05-08 3062 }
dd025c0c7a047b drivers/char/cyclades.c Jiri Slaby 2007-05-08 3063
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3064 for (channel = 0, port = cinfo->first_line; channel < cinfo->nports;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3065 channel++, port++) {
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3066 info = &cinfo->ports[channel];
44b7d1b37f786c drivers/char/cyclades.c Alan Cox 2008-07-16 3067 tty_port_init(&info->port);
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3068 info->magic = CYCLADES_MAGIC;
875b206b5f4971 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3069 info->card = cinfo;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3070 info->line = port;
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3071
44b7d1b37f786c drivers/char/cyclades.c Alan Cox 2008-07-16 3072 info->port.closing_wait = CLOSING_WAIT_DELAY;
44b7d1b37f786c drivers/char/cyclades.c Alan Cox 2008-07-16 3073 info->port.close_delay = 5 * HZ / 10;
2c7fea992104b5 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3074 init_completion(&info->shutdown_wait);
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3075
2693f485c22d18 drivers/char/cyclades.c Jiri Slaby 2009-06-11 3076 if (cy_is_Z(cinfo)) {
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3077 struct FIRM_ID *firm_id = cinfo->base_addr + ID_ADDRESS;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3078 struct ZFW_CTRL *zfw_ctrl;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3079
f0737579424dd2 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3080 info->port.ops = &cyz_port_ops;
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3081 info->type = PORT_STARTECH;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3082
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3083 zfw_ctrl = cinfo->base_addr +
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 @3084 (readl(&firm_id->zfwctrl_addr) & 0xfffff);
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3085 info->u.cyz.ch_ctrl = &zfw_ctrl->ch_ctrl[channel];
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3086 info->u.cyz.buf_ctrl = &zfw_ctrl->buf_ctrl[channel];
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3087
101b81590d8df0 drivers/char/cyclades.c Jiri Slaby 2009-06-11 3088 if (cinfo->hw_ver == ZO_V1)
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3089 info->xmit_fifo_size = CYZ_FIFO_SIZE;
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3090 else
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3091 info->xmit_fifo_size = 4 * CYZ_FIFO_SIZE;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3092 #ifdef CONFIG_CYZ_INTR
a8497b31fee650 drivers/tty/cyclades.c Kees Cook 2017-10-24 3093 timer_setup(&info->rx_full_timer, cyz_rx_restart, 0);
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3094 #endif
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3095 } else {
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3096 unsigned short chip_number;
963118eef9e670 drivers/char/cyclades.c Jiri Slaby 2009-06-11 3097 int index = cinfo->bus_index;
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3098
f0737579424dd2 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3099 info->port.ops = &cyy_port_ops;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3100 info->type = PORT_CIRRUS;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3101 info->xmit_fifo_size = CyMAX_CHAR_FIFO;
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3102 info->cor1 = CyPARITY_NONE | Cy_1_STOP | Cy_8_BITS;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3103 info->cor2 = CyETC;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3104 info->cor3 = 0x08; /* _very_ small rcv threshold */
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3105
f0eefdc30e55e7 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3106 chip_number = channel / CyPORTS_PER_CHIP;
3aeea5b9221008 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3107 info->u.cyy.base_addr = cinfo->base_addr +
3aeea5b9221008 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3108 (cy_chip_offset[chip_number] << index);
3aeea5b9221008 drivers/char/cyclades.c Jiri Slaby 2009-09-19 3109 info->chip_rev = cyy_readb(info, CyGFRCR);
15ed6cc0ba6b7b drivers/char/cyclades.c Alan Cox 2008-04-30 3110
15ed6cc0ba6b7b drivers/char/cyclades.c Alan Cox 2008-04-30 3111 if (info->chip_rev >= CD1400_REV_J) {
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3112 /* It is a CD1400 rev. J or later */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3113 info->tbpr = baud_bpr_60[13]; /* Tx BPR */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3114 info->tco = baud_co_60[13]; /* Tx CO */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3115 info->rbpr = baud_bpr_60[13]; /* Rx BPR */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3116 info->rco = baud_co_60[13]; /* Rx CO */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3117 info->rtsdtr_inv = 1;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3118 } else {
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3119 info->tbpr = baud_bpr_25[13]; /* Tx BPR */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3120 info->tco = baud_co_25[13]; /* Tx CO */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3121 info->rbpr = baud_bpr_25[13]; /* Rx BPR */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3122 info->rco = baud_co_25[13]; /* Rx CO */
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3123 info->rtsdtr_inv = 0;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3124 }
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3125 info->read_status_mask = CyTIMEOUT | CySPECHAR |
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3126 CyBREAK | CyPARITY | CyFRAME | CyOVERRUN;
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3127 }
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3128
0809e2671d804f drivers/char/cyclades.c Jiri Slaby 2007-05-08 3129 }
3046d50ea58676 drivers/char/cyclades.c Jiri Slaby 2007-05-08 3130
:::::: The code at line 3084 was first introduced by commit
:::::: f0eefdc30e55e761facf645bd1be1339b21c30e6 cyclades: avoid addresses recomputation
:::::: TO: Jiri Slaby <jirislaby(a)gmail.com>
:::::: CC: Live-CD User <linux(a)linux.site>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
[intel-linux-intel-lts:5.4/yocto 192/9195] drivers/net/ethernet/stmicro/stmmac/hwif.c:287:43: warning: the omitted middle operand in will always be 'true', suggest explicit middle operand
by kernel test robot
Hi Kim,
FYI, the error/warning still remains.
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: 87241c08286384feb3ddc57d4cb0daca4be1e384
commit: 41e55459e543de8850eff28ca732757370cd5da5 [192/9195] net: stmmac: Add support for MDIO interrupts
config: parisc-randconfig-r021-20200811 (attached as .config)
compiler: hppa-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
git checkout 41e55459e543de8850eff28ca732757370cd5da5
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=parisc
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 >>):
In file included from include/linux/mm.h:99,
from include/linux/bvec.h:13,
from include/linux/skbuff.h:17,
from include/linux/if_ether.h:19,
from include/linux/etherdevice.h:20,
from drivers/net/ethernet/stmicro/stmmac/common.h:14,
from drivers/net/ethernet/stmicro/stmmac/hwif.c:7:
include/asm-generic/pgtable.h: In function 'pte_clear_not_present_full':
arch/parisc/include/asm/pgtable.h:91:9: warning: variable 'old_pte' set but not used [-Wunused-but-set-variable]
91 | pte_t old_pte; \
| ^~~~~~~
arch/parisc/include/asm/pgtable.h:316:34: note: in expansion of macro 'set_pte_at'
316 | #define pte_clear(mm, addr, xp) set_pte_at(mm, addr, xp, __pte(0))
| ^~~~~~~~~~
include/asm-generic/pgtable.h:201:2: note: in expansion of macro 'pte_clear'
201 | pte_clear(mm, address, ptep);
| ^~~~~~~~~
include/asm-generic/pgtable.h: In function '__ptep_modify_prot_commit':
arch/parisc/include/asm/pgtable.h:91:9: warning: variable 'old_pte' set but not used [-Wunused-but-set-variable]
91 | pte_t old_pte; \
| ^~~~~~~
include/asm-generic/pgtable.h:629:2: note: in expansion of macro 'set_pte_at'
629 | set_pte_at(vma->vm_mm, addr, ptep, pte);
| ^~~~~~~~~~
drivers/net/ethernet/stmicro/stmmac/hwif.c: In function 'stmmac_hwif_init':
>> drivers/net/ethernet/stmicro/stmmac/hwif.c:287:43: warning: the omitted middle operand in ?: will always be 'true', suggest explicit middle operand [-Wparentheses]
287 | mac->mdio_intr_en = mac->mdio_intr_en ? : entry->mdio_intr_en;
| ^
vim +/true +287 drivers/net/ethernet/stmicro/stmmac/hwif.c
225
226 int stmmac_hwif_init(struct stmmac_priv *priv)
227 {
228 bool needs_xgmac = priv->plat->has_xgmac;
229 bool needs_gmac4 = priv->plat->has_gmac4;
230 bool needs_gmac = priv->plat->has_gmac;
231 const struct stmmac_hwif_entry *entry;
232 struct mac_device_info *mac;
233 bool needs_setup = true;
234 int i, ret;
235 u32 id;
236
237 if (needs_gmac) {
238 id = stmmac_get_id(priv, GMAC_VERSION);
239 } else if (needs_gmac4 || needs_xgmac) {
240 id = stmmac_get_id(priv, GMAC4_VERSION);
241 } else {
242 id = 0;
243 }
244
245 /* Save ID for later use */
246 priv->synopsys_id = id;
247
248 /* Lets assume some safe values first */
249 priv->ptpaddr = priv->ioaddr +
250 (needs_gmac4 ? PTP_GMAC4_OFFSET : PTP_GMAC3_X_OFFSET);
251 priv->mmcaddr = priv->ioaddr +
252 (needs_gmac4 ? MMC_GMAC4_OFFSET : MMC_GMAC3_X_OFFSET);
253
254 /* Check for HW specific setup first */
255 if (priv->plat->setup) {
256 mac = priv->plat->setup(priv);
257 needs_setup = false;
258 } else {
259 mac = devm_kzalloc(priv->device, sizeof(*mac), GFP_KERNEL);
260 }
261
262 if (!mac)
263 return -ENOMEM;
264
265 /* Fallback to generic HW */
266 for (i = ARRAY_SIZE(stmmac_hw) - 1; i >= 0; i--) {
267 entry = &stmmac_hw[i];
268
269 if (needs_gmac ^ entry->gmac)
270 continue;
271 if (needs_gmac4 ^ entry->gmac4)
272 continue;
273 if (needs_xgmac ^ entry->xgmac)
274 continue;
275 /* Use synopsys_id var because some setups can override this */
276 if (priv->synopsys_id < entry->min_id)
277 continue;
278
279 /* Only use generic HW helpers if needed */
280 mac->desc = mac->desc ? : entry->desc;
281 mac->dma = mac->dma ? : entry->dma;
282 mac->mac = mac->mac ? : entry->mac;
283 mac->ptp = mac->ptp ? : entry->hwtimestamp;
284 mac->mode = mac->mode ? : entry->mode;
285 mac->tc = mac->tc ? : entry->tc;
286 mac->mmc = mac->mmc ? : entry->mmc;
> 287 mac->mdio_intr_en = mac->mdio_intr_en ? : entry->mdio_intr_en;
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
drivers/net/wireless/ti/wlcore/main.c:643:34: sparse: sparse: context imbalance in 'wlcore_irq_locked' - different lock contexts for basic block
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: f0325e38ab39c2e270770b72c79795772ac3b49e wlcore: Use spin_trylock in wlcore_irq_locked() for running the queue
date: 4 weeks ago
config: mips-randconfig-s032-20200811 (attached as .config)
compiler: mips64-linux-gcc (GCC) 9.3.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.2-168-g9554805c-dirty
git checkout f0325e38ab39c2e270770b72c79795772ac3b49e
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=mips
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 >>)
>> drivers/net/wireless/ti/wlcore/main.c:643:34: sparse: sparse: context imbalance in 'wlcore_irq_locked' - different lock contexts for basic block
vim +/wlcore_irq_locked +643 drivers/net/wireless/ti/wlcore/main.c
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 518
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 519 static int wlcore_irq_locked(struct wl1271 *wl)
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 520 {
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 521 int ret = 0;
c15f63bffabb99 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-12 522 u32 intr;
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 523 int loopcount = WL1271_IRQ_MAX_LOOPS;
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 524 bool run_tx_queue = true;
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 525 bool done = false;
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 526 unsigned int defer_count;
b07d4037051318 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 527 unsigned long flags;
b07d4037051318 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 528
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 529 /*
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 530 * In case edge triggered interrupt must be used, we cannot iterate
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 531 * more than once without introducing race conditions with the hardirq.
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 532 */
6f921fab584494 drivers/net/wireless/ti/wlcore/main.c Luciano Coelho 2015-03-18 533 if (wl->irq_flags & (IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING))
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 534 loopcount = 1;
341b7cde6ccc60 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-31 535
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 536 wl1271_debug(DEBUG_IRQ, "IRQ work");
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 537
4cc533830b7e6b drivers/net/wireless/ti/wlcore/main.c Ido Yariv 2012-07-24 538 if (unlikely(wl->state != WLCORE_STATE_ON))
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 539 goto out;
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 540
fa2648a34e73fb drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 541 ret = pm_runtime_get_sync(wl->dev);
fa2648a34e73fb drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 542 if (ret < 0) {
fa2648a34e73fb drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 543 pm_runtime_put_noidle(wl->dev);
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 544 goto out;
fa2648a34e73fb drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 545 }
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 546
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 547 while (!done && loopcount--) {
4e857c58efeb99 drivers/net/wireless/ti/wlcore/main.c Peter Zijlstra 2014-03-17 548 smp_mb__after_atomic();
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 549
75fb4df7f80422 drivers/net/wireless/ti/wlcore/main.c Eliad Peller 2014-02-10 550 ret = wlcore_fw_status(wl, wl->fw_status);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 551 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 552 goto err_ret;
53d67a50cd17ac drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2011-12-12 553
53d67a50cd17ac drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2011-12-12 554 wlcore_hw_tx_immediate_compl(wl);
53d67a50cd17ac drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2011-12-12 555
75fb4df7f80422 drivers/net/wireless/ti/wlcore/main.c Eliad Peller 2014-02-10 556 intr = wl->fw_status->intr;
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 557 intr &= WLCORE_ALL_INTR_MASK;
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 558 if (!intr) {
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 559 done = true;
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 560 continue;
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 561 }
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 562
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 563 if (unlikely(intr & WL1271_ACX_INTR_WATCHDOG)) {
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 564 wl1271_error("HW watchdog interrupt received! starting recovery.");
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 565 wl->watchdog_recovery = true;
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 566 ret = -EIO;
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 567
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 568 /* restarting the chip. ignore any other interrupt. */
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 569 goto err_ret;
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 570 }
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 571
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 572 if (unlikely(intr & WL1271_ACX_SW_INTR_WATCHDOG)) {
f5755fe96cb010 drivers/net/wireless/ti/wlcore/main.c Ido Reis 2012-04-23 573 wl1271_error("SW watchdog interrupt received! "
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 574 "starting recovery.");
afbe37185c0eca drivers/net/wireless/ti/wlcore/main.c Yoni Divinsky 2012-05-16 575 wl->watchdog_recovery = true;
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 576 ret = -EIO;
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 577
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 578 /* restarting the chip. ignore any other interrupt. */
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 579 goto err_ret;
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 580 }
ccc83b046c0337 drivers/net/wireless/wl12xx/wl1271_main.c Eliad Peller 2010-10-27 581
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 582 if (likely(intr & WL1271_ACX_INTR_DATA)) {
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 583 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_DATA");
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 584
75fb4df7f80422 drivers/net/wireless/ti/wlcore/main.c Eliad Peller 2014-02-10 585 ret = wlcore_rx(wl, wl->fw_status);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 586 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 587 goto err_ret;
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 588
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 589 /* Check if any tx blocks were freed */
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 590 if (!test_bit(WL1271_FLAG_FW_TX_BUSY, &wl->flags)) {
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 591 if (spin_trylock_irqsave(&wl->wl_lock, flags)) {
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 592 if (!wl1271_tx_total_queue_count(wl))
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 593 run_tx_queue = false;
b07d4037051318 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 594 spin_unlock_irqrestore(&wl->wl_lock, flags);
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 595 }
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 596
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 597 /*
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 598 * In order to avoid starvation of the TX path,
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 599 * call the work function directly.
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 600 */
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 601 if (run_tx_queue) {
eb96f841b9563b drivers/net/wireless/ti/wlcore/main.c Ido Yariv 2012-06-18 602 ret = wlcore_tx_work_locked(wl);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 603 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 604 goto err_ret;
f0325e38ab39c2 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2020-07-02 605 }
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 606 }
a522550a283de3 drivers/net/wireless/wl12xx/wl1271_main.c Ido Yariv 2010-10-12 607
8aad24642a7c06 drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 608 /* check for tx results */
045b9b5f4172b2 drivers/net/wireless/ti/wlcore/main.c Ido Yariv 2012-06-18 609 ret = wlcore_hw_tx_delayed_compl(wl);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 610 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 611 goto err_ret;
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 612
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 613 /* Make sure the deferred queues don't get too long */
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 614 defer_count = skb_queue_len(&wl->deferred_tx_queue) +
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 615 skb_queue_len(&wl->deferred_rx_queue);
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 616 if (defer_count > WL1271_DEFERRED_QUEUE_LIMIT)
a620865edf62ea drivers/net/wireless/wl12xx/main.c Ido Yariv 2011-03-01 617 wl1271_flush_deferred_work(wl);
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 618 }
1e73eb62cec7cf drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2010-02-22 619
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 620 if (intr & WL1271_ACX_INTR_EVENT_A) {
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 621 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_EVENT_A");
045b9b5f4172b2 drivers/net/wireless/ti/wlcore/main.c Ido Yariv 2012-06-18 622 ret = wl1271_event_handle(wl, 0);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 623 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 624 goto err_ret;
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 625 }
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 626
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 627 if (intr & WL1271_ACX_INTR_EVENT_B) {
1fd2794f369139 drivers/net/wireless/wl12xx/wl1271_main.c Juuso Oikarinen 2009-10-13 628 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_EVENT_B");
045b9b5f4172b2 drivers/net/wireless/ti/wlcore/main.c Ido Yariv 2012-06-18 629 ret = wl1271_event_handle(wl, 1);
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 630 if (ret < 0)
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 631 goto err_ret;
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 632 }
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 633
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 634 if (intr & WL1271_ACX_INTR_INIT_COMPLETE)
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 635 wl1271_debug(DEBUG_IRQ,
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 636 "WL1271_ACX_INTR_INIT_COMPLETE");
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 637
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 638 if (intr & WL1271_ACX_INTR_HW_AVAILABLE)
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 639 wl1271_debug(DEBUG_IRQ, "WL1271_ACX_INTR_HW_AVAILABLE");
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 640 }
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 641
da74b6933b3ba2 drivers/net/wireless/ti/wlcore/main.c Dinghao Liu 2020-05-22 642 err_ret:
9b71578de08748 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 @643 pm_runtime_mark_last_busy(wl->dev);
9b71578de08748 drivers/net/wireless/ti/wlcore/main.c Tony Lindgren 2018-06-19 644 pm_runtime_put_autosuspend(wl->dev);
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 645
f5fc0f86b02afe drivers/net/wireless/wl12xx/wl1271_main.c Luciano Coelho 2009-08-06 646 out:
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 647 return ret;
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 648 }
b5b45b3cbd5616 drivers/net/wireless/ti/wlcore/main.c Arik Nemtsov 2012-06-21 649
:::::: The code at line 643 was first introduced by commit
:::::: 9b71578de08748defb3bcae3ce8ed1a75cb6a8d7 wlcore: Enable runtime PM autosuspend support
:::::: TO: Tony Lindgren <tony(a)atomide.com>
:::::: CC: Kalle Valo <kvalo(a)codeaurora.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
ERROR: "min_low_pfn" undefined!
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: 652b4afb240e5dc196995597942309e89e89c767 staging: wfx: load firmware
date: 10 months ago
config: microblaze-randconfig-r006-20200811 (attached as .config)
compiler: microblaze-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
git checkout 652b4afb240e5dc196995597942309e89e89c767
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=microblaze
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 >>):
ERROR: "min_low_pfn" [net/mac80211/mac80211.ko] undefined!
>> ERROR: "min_low_pfn" [drivers/staging/wfx/wfx.ko] undefined!
ERROR: "min_low_pfn" [drivers/mmc/core/mmc_core.ko] undefined!
ERROR: "min_low_pfn" [drivers/media/common/videobuf2/videobuf2-dma-contig.ko] undefined!
ERROR: "min_low_pfn" [drivers/dma/fsl-edma-common.ko] undefined!
ERROR: "min_low_pfn" [crypto/ccm.ko] undefined!
ERROR: "min_low_pfn" [crypto/gcm.ko] undefined!
ERROR: "min_low_pfn" [crypto/asymmetric_keys/asym_tpm.ko] undefined!
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
[intel-linux-intel-lts:5.4/yocto 8458/9195] drivers/misc/vpusmm/vpusmm_driver.c:406:6: warning: no previous prototype for function 'vpusmm_dmabuf_release'
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: 87241c08286384feb3ddc57d4cb0daca4be1e384
commit: 25008f6f07f24ad55251a3f30505723f1c985338 [8458/9195] misc: vpusmm: add alloc/import DMABuf for VPU
config: x86_64-randconfig-r023-20200811 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 4f2ad15db535873dda9bfe248a2771023b64a43c)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git checkout 25008f6f07f24ad55251a3f30505723f1c985338
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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/misc/vpusmm/vpusmm_driver.c:406:6: warning: no previous prototype for function 'vpusmm_dmabuf_release' [-Wmissing-prototypes]
void vpusmm_dmabuf_release(struct dma_buf *dmabuf)
^
drivers/misc/vpusmm/vpusmm_driver.c:406:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void vpusmm_dmabuf_release(struct dma_buf *dmabuf)
^
static
1 warning generated.
vim +/vpusmm_dmabuf_release +406 drivers/misc/vpusmm/vpusmm_driver.c
405
> 406 void vpusmm_dmabuf_release(struct dma_buf *dmabuf)
407 {
408 // this buffer is only referencec by dmabuf
409 struct vpusmm_buffer *buff = dmabuf->priv;
410
411 if (buff) {
412 if (buff->cookie) {
413 dma_free_attrs(buff->dev, buff->size, buff->cookie, buff->dma_addr, buff->dma_attrs);
414 buff->cookie = NULL;
415 }
416 kfree(buff);
417 }
418 }
419
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
[f2fs-stable:linux-5.4.y 175/304] fs/f2fs/compress.c:433 zstd_decompress_pages() warn: should '((1) << 12) << dic->log_cluster_size' be a 64 bit
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-stable.git linux-5.4.y
head: 32f28e611d66c134f14ab2a9c4e825899360185c
commit: 6a881d4790ecb0b526712a358073a364ca67d95b [175/304] f2fs: compress: support zstd compress algorithm
config: i386-randconfig-m021-20200811 (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>
New smatch warnings:
fs/f2fs/compress.c:433 zstd_decompress_pages() warn: should '((1) << 12) << dic->log_cluster_size' be a 64 bit type?
Old smatch warnings:
fs/f2fs/compress.c:277 lz4_decompress_pages() warn: should '((1) << 12) << dic->log_cluster_size' be a 64 bit type?
vim +433 fs/f2fs/compress.c
408
409 static int zstd_decompress_pages(struct decompress_io_ctx *dic)
410 {
411 ZSTD_DStream *stream = dic->private2;
412 ZSTD_inBuffer inbuf;
413 ZSTD_outBuffer outbuf;
414 int ret;
415
416 inbuf.pos = 0;
417 inbuf.src = dic->cbuf->cdata;
418 inbuf.size = dic->clen;
419
420 outbuf.pos = 0;
421 outbuf.dst = dic->rbuf;
422 outbuf.size = dic->rlen;
423
424 ret = ZSTD_decompressStream(stream, &outbuf, &inbuf);
425 if (ZSTD_isError(ret)) {
426 printk_ratelimited("%sF2FS-fs (%s): %s ZSTD_compressStream failed, ret: %d\n",
427 KERN_ERR, F2FS_I_SB(dic->inode)->sb->s_id,
428 __func__, ZSTD_getErrorCode(ret));
429 return -EIO;
430 }
431
432 if (dic->rlen != outbuf.pos) {
> 433 printk_ratelimited("%sF2FS-fs (%s): %s ZSTD invalid rlen:%zu, "
434 "expected:%lu\n", KERN_ERR,
435 F2FS_I_SB(dic->inode)->sb->s_id,
436 __func__, dic->rlen,
437 PAGE_SIZE << dic->log_cluster_size);
438 return -EIO;
439 }
440
441 return 0;
442 }
443
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month
[intel-linux-intel-lts:5.4/yocto 8351/9195] drivers/crypto/keembay/keembay-ocs-ecc-core.c:574:5: warning: no previous prototype for function 'kmb_ecc_gen_privkey'
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: 87241c08286384feb3ddc57d4cb0daca4be1e384
commit: 0550f2bb919be2d4a8c99eb0bf18f61a27c096bd [8351/9195] crypto: keembay: Add Keem Bay offload ECC Driver
config: x86_64-randconfig-r023-20200811 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 4f2ad15db535873dda9bfe248a2771023b64a43c)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git checkout 0550f2bb919be2d4a8c99eb0bf18f61a27c096bd
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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/crypto/keembay/keembay-ocs-ecc-core.c:574:5: warning: no previous prototype for function 'kmb_ecc_gen_privkey' [-Wmissing-prototypes]
int kmb_ecc_gen_privkey(unsigned int curve_id, unsigned int ndigits,
^
drivers/crypto/keembay/keembay-ocs-ecc-core.c:574:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int kmb_ecc_gen_privkey(unsigned int curve_id, unsigned int ndigits,
^
static
>> drivers/crypto/keembay/keembay-ocs-ecc-core.c:680:12: warning: address of array 'ctx->private_key' will always evaluate to 'true' [-Wpointer-bool-conversion]
if (!ctx->private_key || !curve ||
~~~~~~^~~~~~~~~~~
2 warnings generated.
vim +/kmb_ecc_gen_privkey +574 drivers/crypto/keembay/keembay-ocs-ecc-core.c
561
562 /*
563 * ECC private keys are generated using the method of extra random bits,
564 * equivalent to that described in FIPS 186-4, Appendix B.4.1.
565 *
566 * d = (c mod(n–1)) + 1 where c is a string of random bits, 64 bits longer
567 * than requested
568 * 0 <= c mod(n-1) <= n-2 and implies that
569 * 1 <= d <= n-1
570 *
571 * This method generates a private key uniformly distributed in the range
572 * [1, n-1].
573 */
> 574 int kmb_ecc_gen_privkey(unsigned int curve_id, unsigned int ndigits,
575 u64 *privkey)
576 {
577 u64 priv[KMB_ECC_MAX_DIGITS];
578
579 const struct ecc_curve *curve = ecc_get_curve(curve_id);
580 unsigned int nbytes = ndigits << ECC_DIGITS_TO_BYTES_SHIFT;
581 unsigned int nbits = vli_num_bits(curve->n, ndigits);
582 int err = 0;
583
584 /* Check that N is included in Table 1 of FIPS 186-4, section 6.1.1 */
585 if (nbits < 160 || ndigits > ARRAY_SIZE(priv))
586 return -EINVAL;
587
588 /*
589 * FIPS 186-4 recommends that the private key should be obtained from a
590 * RBG with a security strength equal to or greater than the security
591 * strength associated with N.
592 *
593 * The maximum security strength identified by NIST SP800-57pt1r4 for
594 * ECC is 256 (N >= 512).
595 *
596 * This condition is met by the default RNG because it selects a favored
597 * DRBG with a security strength of 256.
598 */
599 if (crypto_get_default_rng())
600 return -EFAULT;
601
602 err = crypto_rng_get_bytes(crypto_default_rng, (u8 *)priv, nbytes);
603 crypto_put_default_rng();
604 if (err)
605 goto cleanup;
606
607 err = kmb_ecc_is_key_valid(curve_id, ndigits, priv, nbytes);
608 if (err)
609 goto cleanup;
610
611 memcpy(privkey, priv, nbytes);
612
613 cleanup:
614 memzero_explicit(&priv, sizeof(priv));
615
616 return err;
617 }
618
619 static int kmb_ocs_ecdh_set_secret(struct crypto_kpp *tfm, const void *buf,
620 unsigned int len)
621 {
622 struct ecdh params;
623 unsigned int ndigits;
624
625 int ret = 0;
626 struct ocs_ecc_ctx *ctx = kpp_tfm_ctx(tfm);
627
628 ret = crypto_ecdh_decode_key(buf, len, ¶ms);
629 if (ret)
630 goto cleanup;
631
632 ndigits = kmb_ocs_ecdh_supported_curve(params.curve_id);
633
634 if (!ndigits) {
635 ret = -EOPNOTSUPP;
636 goto cleanup;
637 }
638
639 ctx->curve_id = params.curve_id;
640 ctx->ndigits = ndigits;
641
642 if (!params.key || !params.key_size) {
643 ret = -EINVAL;
644 #ifdef CONFIG_CRYPTO_DEV_KEEMBAY_OCS_ECDH_GEN_PRIV_KEY_SUPPORT
645 ret = kmb_ecc_gen_privkey(ctx->curve_id, ctx->ndigits,
646 ctx->private_key);
647 #endif /* CONFIG_CRYPTO_DEV_KEEMBAY_OCS_ECDH_GEN_PRIV_KEY_SUPPORT */
648 if (ret)
649 goto cleanup;
650 goto swap_digits;
651 }
652
653 ret = kmb_ecc_is_key_valid(ctx->curve_id, ctx->ndigits,
654 (const u64 *)params.key, params.key_size);
655 if (ret)
656 goto cleanup;
657
658 swap_digits:
659 ecc_swap_digits((u64 *)params.key, ctx->private_key, ctx->ndigits);
660 cleanup:
661 memzero_explicit(¶ms, sizeof(params));
662
663 return ret;
664 }
665
666 static int kmb_ocs_ecc_do_one_request(struct crypto_engine *engine,
667 void *areq)
668 {
669 size_t copied, nbytes;
670 struct ecc_point *pk;
671
672 u64 *public_key = NULL;
673 int ret = -ENOMEM;
674 size_t public_key_sz = 0;
675 struct kpp_request *req = container_of(areq, struct kpp_request,
676 base);
677 struct ocs_ecc_ctx *ctx = kmb_ocs_kpp_ctx(req);
678 const struct ecc_curve *curve = ecc_get_curve(ctx->curve_id);
679
> 680 if (!ctx->private_key || !curve ||
681 (ctx->ndigits > KMB_ECC_MAX_DIGITS)) {
682 ret = -EINVAL;
683 goto out;
684 }
685
686 /* No spurious request checked at top level.*/
687 if ((!req->src) && (!req->dst)) {
688 ret = -EINVAL;
689 goto out;
690 }
691
692 /* Store the request flag in ctx. */
693 ctx->gfp = (req->base.flags & CRYPTO_TFM_REQ_MAY_SLEEP) ? GFP_KERNEL
694 : GFP_ATOMIC;
695
696 pk = ecc_alloc_point(ctx->ndigits, ctx->gfp);
697 if (!pk) {
698 ret = -ENOMEM;
699 goto out;
700 }
701
702 /* Store the kpp_request struct in the device context. */
703 ctx->ecc_dev->req = req;
704
705 /* In case shared_secret branch not taken. */
706 ctx->pk = NULL;
707
708 nbytes = data_size_u64_to_u8(ctx->ndigits);
709 /* Public part is a point thus it has both coordinates */
710 public_key_sz = 2 * nbytes;
711
712 public_key = kzalloc(public_key_sz, ctx->gfp);
713 if (!public_key) {
714 ret = -ENOMEM;
715 goto free_all;
716 }
717
718 if (req->src) {
719 /* from here on it's invalid parameters */
720 ret = -EINVAL;
721
722 /* must have exactly two points to be on the curve */
723 if (public_key_sz != req->src_len)
724 goto free_all;
725
726 copied = sg_copy_to_buffer(req->src,
727 sg_nents_for_len(req->src,
728 public_key_sz),
729 public_key, public_key_sz);
730 if (copied != public_key_sz)
731 goto free_all;
732 /* Store pk in the device context. */
733 ctx->pk = pk;
734 ecc_swap_digits(public_key, pk->x, ctx->ndigits);
735 ecc_swap_digits(&public_key[ctx->ndigits], pk->y, ctx->ndigits);
736 /*
737 * Check the public key for following
738 * Check 1: Verify key is not the zero point.
739 * Check 2: Verify key is in the range [1, p-1].
740 * Check 3: Verify that y^2 == (x^3 + a·x + b) mod p
741 */
742 ret = kmb_ocs_ecc_is_pubkey_valid_partial(ctx->ecc_dev, curve,
743 pk);
744 } else {
745 /* Public Key(pk) = priv * G. */
746 ret = ecc_point_mult(ctx->ecc_dev, pk, &curve->g,
747 ctx->private_key, curve, ctx->ndigits);
748 }
749
750 if (ret)
751 goto free_all;
752 goto return_success;
753
754 /* follow through */
755 free_all:
756 ecc_free_point(pk);
757 out:
758 crypto_finalize_kpp_request(ctx->ecc_dev->engine,
759 req, ret);
760 return_success:
761 if (public_key) {
762 memzero_explicit(public_key, public_key_sz);
763 kzfree(public_key);
764 }
765 return 0;
766 }
767
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 1 month