diff options
author | Suraj Upadhyay <usuraj35@gmail.com> | 2020-07-13 17:52:22 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-07-13 15:37:47 +0200 |
commit | caaba08f8c0dbe5c8fcb497faa7e3b394c21ff39 (patch) | |
tree | 18660a3b2e1ea3e70466d3fb0d92219a1cfb0b0e /drivers/staging/qlge | |
parent | 45170f100a8d2a96a3569519f5968144e6542940 (diff) |
staging: qlge: qlge_ethtool: Remove one byte memset.
Use direct assignment instead of using memset with just one byte as an
argument.
Issue found by checkpatch.pl.
Signed-off-by: Suraj Upadhyay <usuraj35@gmail.com>
Link: https://lore.kernel.org/r/b5eb87576cef4bf1b968481d6341013e6c7e9650.1594642213.git.usuraj35@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/qlge')
-rw-r--r-- | drivers/staging/qlge/qlge_ethtool.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/qlge/qlge_ethtool.c b/drivers/staging/qlge/qlge_ethtool.c index 16fcdefa9687..d44b2dae9213 100644 --- a/drivers/staging/qlge/qlge_ethtool.c +++ b/drivers/staging/qlge/qlge_ethtool.c @@ -516,8 +516,8 @@ static void ql_create_lb_frame(struct sk_buff *skb, memset(skb->data, 0xFF, frame_size); frame_size &= ~1; memset(&skb->data[frame_size / 2], 0xAA, frame_size / 2 - 1); - memset(&skb->data[frame_size / 2 + 10], 0xBE, 1); - memset(&skb->data[frame_size / 2 + 12], 0xAF, 1); + skb->data[frame_size / 2 + 10] = (unsigned char)0xBE; + skb->data[frame_size / 2 + 12] = (unsigned char)0xAF; } void ql_check_lb_frame(struct ql_adapter *qdev, |