From: Lei Huang <huanglei814@163.com>
To: mchehab@kernel.org
Cc: johan@kernel.org, hverkuil+cisco@kernel.org,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org,
Lei Huang <huanglei@kylinos.cn>
Subject: [PATCH v2 03/17] media: s2255: Remove unnecessary spaces after casts
Date: Mon, 20 Jul 2026 10:54:32 +0800 [thread overview]
Message-ID: <20260720025438.207149-4-huanglei814@163.com> (raw)
In-Reply-To: <20260720025438.207149-1-huanglei814@163.com>
From: Lei Huang <huanglei@kylinos.cn>
Fix all 8 'CHECK: No space is necessary after a cast' issues reported by
checkpatch.pl in s2255drv.c. Remove the space between the cast type and
the value being cast.
Signed-off-by: Lei Huang <huanglei@kylinos.cn>
---
drivers/media/usb/s2255/s2255drv.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/media/usb/s2255/s2255drv.c b/drivers/media/usb/s2255/s2255drv.c
index 0f98a4cc18a4..78011f5fe99c 100644
--- a/drivers/media/usb/s2255/s2255drv.c
+++ b/drivers/media/usb/s2255/s2255drv.c
@@ -521,7 +521,7 @@ static void s2255_fwchunk_complete(struct urb *urb)
memset(data->pfw_data, 0, CHUNK_SIZE);
memcpy(data->pfw_data,
- (char *) data->fw->data + data->fw_loaded, len);
+ (char *)data->fw->data + data->fw_loaded, len);
usb_fill_bulk_urb(data->fw_urb, udev, usb_sndbulkpipe(udev, 2),
data->pfw_data, CHUNK_SIZE,
@@ -875,7 +875,7 @@ static int vidioc_s_fmt_vid_cap(struct file *file, void *priv,
else if (mode.format != vc->mode.format)
mode.restart = 1;
vc->mode = mode;
- (void) s2255_set_mode(vc, &mode);
+ (void)s2255_set_mode(vc, &mode);
return 0;
}
@@ -1001,7 +1001,7 @@ static int s2255_set_mode(struct s2255_vc *vc,
dprintk(dev, 1, "%s: reqsize %ld\n", __func__, vc->req_image_size);
/* set the mode */
buffer[0] = IN_DATA_TOKEN;
- buffer[1] = (__le32) cpu_to_le32(chn_rev);
+ buffer[1] = (__le32)cpu_to_le32(chn_rev);
buffer[2] = CMD_SET_MODE;
for (i = 0; i < sizeof(struct s2255_mode) / sizeof(u32); i++)
buffer[3 + i] = cpu_to_le32(((u32 *)&vc->mode)[i]);
@@ -1038,7 +1038,7 @@ static int s2255_cmd_status(struct s2255_vc *vc, u32 *pstatus)
dprintk(dev, 4, "%s chan %d\n", __func__, vc->idx);
/* form the get vid status command */
buffer[0] = IN_DATA_TOKEN;
- buffer[1] = (__le32) cpu_to_le32(chn_rev);
+ buffer[1] = (__le32)cpu_to_le32(chn_rev);
buffer[2] = CMD_STATUS;
*pstatus = 0;
vc->vidstatus_ready = 0;
@@ -1078,7 +1078,7 @@ static void stop_streaming(struct vb2_queue *vq)
struct s2255_vc *vc = vb2_get_drv_priv(vq);
struct s2255_buffer *buf, *node;
unsigned long flags;
- (void) s2255_stop_acquire(vc);
+ (void)s2255_stop_acquire(vc);
spin_lock_irqsave(&vc->qlock, flags);
list_for_each_entry_safe(buf, node, &vc->buf_list, list) {
list_del(&buf->list);
@@ -2129,7 +2129,7 @@ static int s2255_start_acquire(struct s2255_vc *vc)
/* send the start command */
buffer[0] = IN_DATA_TOKEN;
- buffer[1] = (__le32) cpu_to_le32(chn_rev);
+ buffer[1] = (__le32)cpu_to_le32(chn_rev);
buffer[2] = CMD_START;
res = s2255_write_config(dev->udev, (unsigned char *)buffer, 512);
if (res != 0)
@@ -2151,7 +2151,7 @@ static int s2255_stop_acquire(struct s2255_vc *vc)
chn_rev = G_chnmap[vc->idx];
/* send the stop command */
buffer[0] = IN_DATA_TOKEN;
- buffer[1] = (__le32) cpu_to_le32(chn_rev);
+ buffer[1] = (__le32)cpu_to_le32(chn_rev);
buffer[2] = CMD_STOP;
res = s2255_write_config(dev->udev, (unsigned char *)buffer, 512);
@@ -2282,7 +2282,7 @@ static int s2255_probe(struct usb_interface *interface,
retval = -ENODEV;
goto err_fwmarker;
}
- pdata = (__le32 *) &dev->fw_data->fw->data[fw_size - 8];
+ pdata = (__le32 *)&dev->fw_data->fw->data[fw_size - 8];
if (*pdata != S2255_FW_MARKER) {
dev_err(&interface->dev, "Firmware invalid.\n");
--
2.25.1
next prev parent reply other threads:[~2026-07-20 2:55 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-20 2:54 [PATCH v2 00/17] media: s2255: Coding style cleanup Lei Huang
2026-07-20 2:54 ` [PATCH v2 01/17] media: s2255: Rename CamelCase goto labels to snake_case Lei Huang
2026-07-20 2:54 ` [PATCH v2 02/17] media: s2255: Rename remaining CamelCase identifiers " Lei Huang
2026-07-20 2:54 ` Lei Huang [this message]
2026-07-20 2:54 ` [PATCH v2 04/17] media: s2255: Use consistent braces on all arms of if/else statements Lei Huang
2026-07-20 2:54 ` [PATCH v2 05/17] media: s2255: Replace NULL comparisons with ! notation Lei Huang
2026-07-20 2:54 ` [PATCH v2 06/17] media: s2255: Fix alignment to match open parenthesis Lei Huang
2026-07-20 2:54 ` [PATCH v2 07/17] media: s2255: Remove multiple blank lines and before close braces Lei Huang
2026-07-20 2:54 ` [PATCH v2 08/17] media: s2255: Add blank lines after function/struct/enum declarations Lei Huang
2026-07-20 2:54 ` [PATCH v2 09/17] media: s2255: Add spaces around multiplication operators Lei Huang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260720025438.207149-4-huanglei814@163.com \
--to=huanglei814@163.com \
--cc=huanglei@kylinos.cn \
--cc=hverkuil+cisco@kernel.org \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®