stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: linux-kernel@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	stable@vger.kernel.org, Philipp Klocke <philipp97kl@gmail.com>,
	Takashi Iwai <tiwai@suse.de>, Sasha Levin <sashal@kernel.org>
Subject: [PATCH 4.4 044/132] ALSA: i2c/cs8427: Fix int to char conversion
Date: Wed, 27 Nov 2019 21:30:35 +0100	[thread overview]
Message-ID: <20191127202939.896994447@linuxfoundation.org> (raw)
In-Reply-To: <20191127202857.270233486@linuxfoundation.org>

From: Philipp Klocke <philipp97kl@gmail.com>

[ Upstream commit eb7ebfa3c1989aa8e59d5e68ab3cddd7df1bfb27 ]

Compiling with clang yields the following warning:

sound/i2c/cs8427.c:140:31: warning: implicit conversion from 'int'
to 'char' changes value from 160 to -96 [-Wconstant-conversion]
    data[0] = CS8427_REG_AUTOINC | CS8427_REG_CORU_DATABUF;
            ~ ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~

Because CS8427_REG_AUTOINC is defined as 128, it is too big for a
char field.
So change data from char to unsigned char, that it can hold the value.

This patch does not change the generated code.

Signed-off-by: Philipp Klocke <philipp97kl@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 sound/i2c/cs8427.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/i2c/cs8427.c b/sound/i2c/cs8427.c
index 7e21621e492a4..7fd1b40008838 100644
--- a/sound/i2c/cs8427.c
+++ b/sound/i2c/cs8427.c
@@ -118,7 +118,7 @@ static int snd_cs8427_send_corudata(struct snd_i2c_device *device,
 	struct cs8427 *chip = device->private_data;
 	char *hw_data = udata ?
 		chip->playback.hw_udata : chip->playback.hw_status;
-	char data[32];
+	unsigned char data[32];
 	int err, idx;
 
 	if (!memcmp(hw_data, ndata, count))
-- 
2.20.1




  parent reply	other threads:[~2019-11-27 20:35 UTC|newest]

Thread overview: 142+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-27 20:29 [PATCH 4.4 000/132] 4.4.204-stable review Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 001/132] net/mlx4_en: fix mlx4 ethtool -N insertion Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 002/132] sfc: Only cancel the PPS workqueue if it exists Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 003/132] net/sched: act_pedit: fix WARN() in the traffic path Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 004/132] net: rtnetlink: prevent underflows in do_setvfinfo() Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 005/132] Revert "fs: ocfs2: fix possible null-pointer dereferences in ocfs2_xa_prepare_entry()" Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 006/132] mm/ksm.c: dont WARN if page is still mapped in remove_stable_node() Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 007/132] asus-wmi: Create quirk for airplane_mode LED Greg Kroah-Hartman
2019-11-27 20:29 ` [PATCH 4.4 008/132] asus-wmi: Add quirk_no_rfkill_wapf4 for the Asus X456UF Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 009/132] asus-wmi: Add quirk_no_rfkill for the Asus N552VW Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 010/132] asus-wmi: Add quirk_no_rfkill for the Asus U303LB Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 011/132] asus-wmi: Add quirk_no_rfkill for the Asus Z550MA Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 012/132] platform/x86: asus-wmi: Filter buggy scan codes on ASUS Q500A Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 013/132] platform/x86: asus-wmi: fix asus ux303ub brightness issue Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 014/132] platform/x86: asus-wmi: Set specified XUSB2PR value for X550LB Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 015/132] asus-wmi: provide access to ALS control Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 016/132] platform/x86: asus-wmi: try to set als by default Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 017/132] platform/x86: asus-nb-wmi: Support ALS on the Zenbook UX430UQ Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 018/132] platform/x86: asus-wmi: Only Tell EC the OS will handle display hotkeys from asus_nb_wmi Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 019/132] platform/x86: asus-wmi: add SERIO_I8042 dependency Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 020/132] mwifiex: Fix NL80211_TX_POWER_LIMITED Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 021/132] ALSA: isight: fix leak of reference to firewire unit in error path of .probe callback Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 022/132] printk: fix integer overflow in setup_log_buf() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 023/132] gfs2: Fix marking bitmaps non-full Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 024/132] synclink_gt(): fix compat_ioctl() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 025/132] powerpc: Fix signedness bug in update_flash_db() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 026/132] powerpc/eeh: Fix use of EEH_PE_KEEP on wrong field Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 027/132] brcmsmac: AP mode: update beacon when TIM changes Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 028/132] spi: sh-msiof: fix deferred probing Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 029/132] mmc: mediatek: fix cannot receive new request when msdc_cmd_is_ready fail Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 030/132] btrfs: handle error of get_old_root Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 031/132] gsmi: Fix bug in append_to_eventlog sysfs handler Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 032/132] misc: mic: fix a DMA pool free failure Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 033/132] amiflop: clean up on errors during setup Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 034/132] scsi: ips: fix missing break in switch Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 035/132] KVM/x86: Fix invvpid and invept register operand size in 64-bit mode Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 036/132] scsi: isci: Use proper enumerated type in atapi_d2h_reg_frame_handler Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 037/132] scsi: isci: Change sci_controller_start_tasks return type to sci_status Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 038/132] scsi: iscsi_tcp: Explicitly cast param in iscsi_sw_tcp_host_get_param Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 039/132] clk: mmp2: fix the clock id for sdh2_clk and sdh3_clk Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 040/132] scsi: dc395x: fix dma API usage in srb_done Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 041/132] scsi: dc395x: fix DMA API usage in sg_update_list Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 042/132] net: fix warning in af_unix Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 043/132] kprobes, x86/ptrace.h: Make regs_get_kernel_stack_nth() not fault on bad stack Greg Kroah-Hartman
2019-11-27 20:30 ` Greg Kroah-Hartman [this message]
2019-11-27 20:30 ` [PATCH 4.4 045/132] macintosh/windfarm_smu_sat: Fix debug output Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 046/132] USB: misc: appledisplay: fix backlight update_status return code Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 047/132] SUNRPC: Fix a compile warning for cmpxchg64() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 048/132] atm: zatm: Fix empty body Clang warnings Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 049/132] s390/perf: Return error when debug_register fails Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 050/132] spi: omap2-mcspi: Set FIFO DMA trigger level to word length Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 051/132] sparc: Fix parport build warnings Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 052/132] ceph: fix dentry leak in ceph_readdir_prepopulate Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 053/132] rtc: s35390a: Change bufs type to u8 in s35390a_init Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 054/132] mISDN: Fix type of switch control variable in ctrl_teimanager Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 055/132] qlcnic: fix a return in qlcnic_dcb_get_capability() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 056/132] mfd: mc13xxx-core: Fix PMIC shutdown when reading ADC values Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 057/132] mfd: max8997: Enale irq-wakeup unconditionally Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 058/132] selftests/ftrace: Fix to test kprobe $comm arg only if available Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 059/132] thermal: rcar_thermal: Prevent hardware access during system suspend Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 060/132] sparc64: Rework xchg() definition to avoid warnings Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 061/132] fs/ocfs2/dlm/dlmdebug.c: fix a sleep-in-atomic-context bug in dlm_print_one_mle() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 062/132] mm/page-writeback.c: fix range_cyclic writeback vs writepages deadlock Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 063/132] um: Make line/tty semantics use true write IRQ Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 064/132] linux/bitmap.h: handle constant zero-size bitmaps correctly Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 065/132] linux/bitmap.h: fix type of nbits in bitmap_shift_right() Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 066/132] hfsplus: fix BUG on bnode parent update Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 067/132] hfs: " Greg Kroah-Hartman
2019-11-27 20:30 ` [PATCH 4.4 068/132] hfsplus: prevent btree data loss on ENOSPC Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 069/132] hfs: " Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 070/132] hfsplus: fix return value of hfsplus_get_block() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 071/132] hfs: fix return value of hfs_get_block() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 072/132] fs/hfs/extent.c: fix array out of bounds read of array extent Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 073/132] igb: shorten maximum PHC timecounter update interval Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 074/132] ntb_netdev: fix sleep time mismatch Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 075/132] ntb: intel: fix return value for ndev_vec_mask() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 076/132] ocfs2: dont put and assigning null to bh allocated outside Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 077/132] ocfs2: fix clusters leak in ocfs2_defrag_extent() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 078/132] net: do not abort bulk send on BQL status Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 079/132] sched/fair: Dont increase sd->balance_interval on newidle balance Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 080/132] audit: print empty EXECVE args Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 081/132] wlcore: Fix the return value in case of error in wlcore_vendor_cmd_smart_config_start() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 082/132] rtl8xxxu: Fix missing break in switch Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 083/132] brcmsmac: never log "tid x is not aggable" by default Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 084/132] wireless: airo: potential buffer overflow in sprintf() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 085/132] rtlwifi: rtl8192de: Fix misleading REG_MCUFWDL information Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 086/132] scsi: mpt3sas: Fix Sync cache command failure during driver unload Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 087/132] scsi: mpt3sas: Fix driver modifying persistent data in Manufacturing page11 Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 088/132] scsi: megaraid_sas: Fix msleep granularity Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 089/132] scsi: lpfc: fcoe: Fix link down issue after 1000+ link bounces Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 090/132] dlm: fix invalid free Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 091/132] dlm: dont leak kernel pointer to userspace Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 092/132] net: bcmgenet: return correct value ret from bcmgenet_power_down Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 093/132] sock: Reset dst when changing sk_mark via setsockopt Greg Kroah-Hartman
2019-11-29  8:04   ` Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 094/132] pinctrl: qcom: spmi-gpio: fix gpio-hog related boot issues Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 095/132] pinctrl: zynq: Use define directive for PIN_CONFIG_IO_STANDARD Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 096/132] PCI: keystone: Use quirk to limit MRRS for K2G Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 097/132] spi: omap2-mcspi: Fix DMA and FIFO event trigger size mismatch Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 098/132] IB/hfi1: Ensure full Gen3 speed in a Gen4 system Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 099/132] Bluetooth: Fix invalid-free in bcsp_close() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 100/132] ath9k_hw: fix uninitialized variable data Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 101/132] dm: use blk_set_queue_dying() in __dm_destroy() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 102/132] arm64: fix for bad_mode() handler to always result in panic Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 103/132] cpufreq: Skip cpufreq resume if its not suspended Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 104/132] ocfs2: remove ocfs2_is_o2cb_active() Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 105/132] mmc: block: Fix tag condition with packed writes Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 106/132] ARC: perf: Accommodate big-endian CPU Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 107/132] x86/insn: Fix awk regexp warnings Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 108/132] x86/speculation: Fix incorrect MDS/TAA mitigation status Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 109/132] x86/speculation: Fix redundant MDS mitigation message Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 110/132] media: vivid: Set vid_cap_streaming and vid_out_streaming to true Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 111/132] media: vivid: Fix wrong locking that causes race conditions on streaming stop Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 112/132] cpufreq: Add NULL checks to show() and store() methods of cpufreq Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 113/132] media: b2c2-flexcop-usb: add sanity checking Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 114/132] media: cxusb: detect cxusb_ctrl_msg error in query Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 115/132] media: imon: invalid dereference in imon_touch_event Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 116/132] virtio_console: reset on out of memory Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 117/132] virtio_console: dont tie bufs to a vq Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 118/132] virtio_console: allocate inbufs in add_port() only if it is needed Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 119/132] virtio_console: fix uninitialized variable use Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 120/132] virtio_console: drop custom control queue cleanup Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 121/132] virtio_console: move removal code Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 122/132] usb-serial: cp201x: support Mark-10 digital force gauge Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 123/132] appledisplay: fix error handling in the scheduled work Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 124/132] USB: serial: mos7840: add USB ID to support Moxa UPort 2210 Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 125/132] USB: serial: mos7720: fix remote wakeup Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 126/132] USB: serial: mos7840: " Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 127/132] USB: serial: option: add support for DW5821e with eSIM support Greg Kroah-Hartman
2019-11-27 20:31 ` [PATCH 4.4 128/132] USB: serial: option: add support for Foxconn T77W968 LTE modules Greg Kroah-Hartman
2019-11-27 20:32 ` [PATCH 4.4 129/132] staging: comedi: usbduxfast: usbduxfast_ai_cmdtest rounding error Greg Kroah-Hartman
2019-11-27 20:32 ` [PATCH 4.4 130/132] powerpc/64s: support nospectre_v2 cmdline option Greg Kroah-Hartman
2019-11-27 20:32 ` [PATCH 4.4 131/132] powerpc/book3s64: Fix link stack flush on context switch Greg Kroah-Hartman
2019-11-27 20:32 ` [PATCH 4.4 132/132] KVM: PPC: Book3S HV: Flush link stack on guest exit to host kernel Greg Kroah-Hartman
2019-11-28 10:55 ` [PATCH 4.4 000/132] 4.4.204-stable review Jon Hunter
2019-11-28 13:29 ` Naresh Kamboju
2019-11-29  8:53   ` Greg Kroah-Hartman
2019-12-03  5:25     ` Guenter Roeck
2019-12-03  6:36       ` Greg Kroah-Hartman
2019-12-03 18:58         ` Guenter Roeck
2019-11-28 16:13 ` Guenter Roeck
2019-11-29  0:04 ` shuah

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=20191127202939.896994447@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=philipp97kl@gmail.com \
    --cc=sashal@kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=tiwai@suse.de \
    /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;
as well as URLs for NNTP newsgroup(s).