Skip to content

Commit

Permalink
Merge branch 'msm-4.4-android-10' of https://github.com/nathanchance/…
Browse files Browse the repository at this point in the history
…android-kernel-clang into regression

Reject changes that were already fixed by me or CAF.

Signed-off-by: idkwhoiam322 <[email protected]>
  • Loading branch information
idkwhoiam322 committed Oct 25, 2019
2 parents 089d321 + 75bb1fc commit d630809
Show file tree
Hide file tree
Showing 298 changed files with 1,680 additions and 1,820 deletions.
1 change: 0 additions & 1 deletion Documentation/DocBook/80211.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@
<chapter>
<title>Device registration</title>
!Pinclude/net/cfg80211.h Device registration
!Finclude/net/cfg80211.h ieee80211_band
!Finclude/net/cfg80211.h ieee80211_channel_flags
!Finclude/net/cfg80211.h ieee80211_channel
!Finclude/net/cfg80211.h ieee80211_rate_flags
Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ include scripts/Kbuild.include
# Make variables (CC, etc...)
AS = $(CROSS_COMPILE)as
LD = $(CROSS_COMPILE)ld
REAL_CC = $(CROSS_COMPILE)gcc
CC = $(CROSS_COMPILE)gcc
CPP = $(CC) -E
AR = $(CROSS_COMPILE)ar
NM = $(CROSS_COMPILE)nm
Expand All @@ -358,10 +358,6 @@ PERL = perl
PYTHON = python
CHECK = sparse

# Use the wrapper for the compiler. This wrapper scans for new
# warnings and causes the build to stop upon encountering them.
CC = $(PYTHON) $(srctree)/scripts/gcc-wrapper.py $(REAL_CC)

CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ \
-Wbitwise -Wno-return-void $(CF)
CFLAGS_MODULE =
Expand Down Expand Up @@ -670,6 +666,10 @@ endif
endif
endif

ifdef CONFIG_CC_WERROR
KBUILD_CFLAGS += -Werror
endif

# Tell gcc to never replace conditional load with a non-conditional one
KBUILD_CFLAGS += $(call cc-option,--param=allow-store-data-races=0)

Expand Down
4 changes: 2 additions & 2 deletions drivers/char/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -633,8 +633,8 @@ config MSM_RDBG
for a debugger running on a host PC to communicate with a remote
stub running on peripheral subsystems such as the ADSP, MODEM etc.

config QCOM_SDIO_CLIENT
bool "QCOM_SDIO_CLIENT support"
config QTI_SDIO_CLIENT
bool "QTI_SDIO_CLIENT support"
depends on SDIO_QCN
default y
help
Expand Down
2 changes: 1 addition & 1 deletion drivers/char/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,4 @@ ifdef CONFIG_COMPAT
obj-$(CONFIG_MSM_ADSPRPC) += adsprpc_compat.o
endif
obj-$(CONFIG_MSM_RDBG) += rdbg.o
obj-$(CONFIG_QCOM_SDIO_CLIENT) += qti_sdio_client.o
obj-$(CONFIG_QTI_SDIO_CLIENT) += qti_sdio_client.o
2 changes: 1 addition & 1 deletion drivers/char/diag/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ endmenu
menu "HSIC/SMUX support for DIAG"

config DIAGFWD_BRIDGE_CODE
depends on USB_QCOM_DIAG_BRIDGE || MSM_MHI || QCOM_SDIO_CLIENT
depends on USB_QCOM_DIAG_BRIDGE || MSM_MHI || QTI_SDIO_CLIENT
default y
bool "Enable QSC/9K DIAG traffic over SMUX/HSIC"
help
Expand Down
2 changes: 1 addition & 1 deletion drivers/char/diag/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ obj-$(CONFIG_DIAGFWD_BRIDGE_CODE) += diagfwd_bridge.o

obj-$(CONFIG_USB_QCOM_DIAG_BRIDGE) += diagfwd_hsic.o
obj-$(CONFIG_MSM_MHI) += diagfwd_mhi.o
obj-$(CONFIG_QCOM_SDIO_CLIENT) += diagfwd_sdio.o
obj-$(CONFIG_QTI_SDIO_CLIENT) += diagfwd_sdio.o

diagchar-objs := diagchar_core.o diagchar_hdlc.o diagfwd.o diagfwd_glink.o diagfwd_peripheral.o diagfwd_smd.o diagfwd_socket.o diag_mux.o diag_memorydevice.o diag_usb.o diagmem.o diagfwd_cntl.o diag_dci.o diag_masks.o diag_debugfs.o
2 changes: 1 addition & 1 deletion drivers/char/diag/diagfwd_bridge.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ static int diag_mhi_init(void)
}
#endif

#ifndef CONFIG_QCOM_SDIO_CLIENT
#ifndef CONFIG_QTI_SDIO_CLIENT
static int diag_sdio_init(void)
{
return -EINVAL;
Expand Down
3 changes: 1 addition & 2 deletions drivers/char/diag/diagfwd_bridge.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* Copyright (c) 2012-2014, 2018-2019, The Linux Foundation.
* All rights reserved.
/* Copyright (c) 2012-2014, 2018-2019, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
Expand Down
4 changes: 2 additions & 2 deletions drivers/char/diag/diagfwd_sdio.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#ifndef DIAGFWD_SDIO_H
#define DIAGFWD_SDIO_H

#ifdef CONFIG_QCOM_SDIO_CLIENT
#ifdef CONFIG_QTI_SDIO_CLIENT

#ifdef CONFIG_DIAG_OVER_USB
#include <linux/usb/usbdiag.h>
Expand Down Expand Up @@ -52,4 +52,4 @@ int diag_sdio_init(void);
void diag_sdio_exit(void);

#endif
#endif /*CONFIG_QCOM_SDIO_CLIENT*/
#endif /*CONFIG_QTI_SDIO_CLIENT*/
2 changes: 1 addition & 1 deletion drivers/clk/msm/clock-gcc-8996.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ static void __iomem *virt_dbgbase;
#define gpll0_out_main_source_val 1
#define gpll4_out_main_source_val 5

#define FIXDIV(div) (div ? (2 * (div) - 1) : (0))
#define FIXDIV(div) (div != 0 ? (2 * (div) - 1) : (0))

#define F(f, s, div, m, n) \
{ \
Expand Down
2 changes: 1 addition & 1 deletion drivers/clk/msm/clock-gcc-8998.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ static void __iomem *virt_dbgbase;
#define gpll4_out_main_source_val 5
#define gpll0_early_div_source_val 6

#define FIXDIV(div) (div ? (2 * (div) - 1) : (0))
#define FIXDIV(div) (div != 0 ? (2 * (div) - 1) : (0))

#define F(f, s, div, m, n) \
{ \
Expand Down
2 changes: 1 addition & 1 deletion drivers/clk/msm/clock-mmss-8996.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ static void __iomem *virt_base_gpu;
#define dsi1phypll_mm_source_val 2
#define ext_extpclk_clk_src_mm_source_val 1

#define FIXDIV(div) (div ? (2 * (div) - 1) : (0))
#define FIXDIV(div) (div != 0 ? (2 * (div) - 1) : (0))

#define F_MM(f, s, div, m, n) \
{ \
Expand Down
2 changes: 1 addition & 1 deletion drivers/clk/msm/clock-mmss-8998.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ static void __iomem *virt_base;
#define ext_dp_phy_pll_link_mm_source_val 1
#define ext_dp_phy_pll_vco_mm_source_val 2

#define FIXDIV(div) (div ? (2 * (div) - 1) : (0))
#define FIXDIV(div) (div != 0 ? (2 * (div) - 1) : (0))

#define F_MM(f, s, div, m, n) \
{ \
Expand Down
2 changes: 1 addition & 1 deletion drivers/clk/msm/clock-osm.c
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ static void __iomem *debug_base;
#define ACD_REG_RELATIVE_ADDR_BITMASK(addr) \
(1 << (ACD_REG_RELATIVE_ADDR(addr)))

#define FIXDIV(div) (div ? (2 * (div) - 1) : (0))
#define FIXDIV(div) (div != 0 ? (2 * (div) - 1) : (0))

#define F(f, s, div, m, n) \
{ \
Expand Down
9 changes: 3 additions & 6 deletions drivers/clk/qcom/clk-debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,13 +177,10 @@ static int clk_debug_mux_set_parent(struct clk_hw *hw, u8 index)

regval |= (meas->parent[index].next_sel & meas->mask);

if (meas->parent[index].en_mask == 0xFF)
/* Skip en_mask */
regval = regval;
else if (meas->parent[index].en_mask)
regval |= meas->parent[index].en_mask;
else
if (!meas->parent[index].en_mask)
regval |= meas->en_mask;
else if (meas->parent[index].en_mask != 0xFF)
regval |= meas->parent[index].en_mask;

regmap_write(meas->regmap[dbg_cc], 0x0, regval);
}
Expand Down
78 changes: 41 additions & 37 deletions drivers/crypto/msm/qcedev.c
Original file line number Diff line number Diff line change
Expand Up @@ -1607,12 +1607,16 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
int err = 0;
struct qcedev_handle *handle;
struct qcedev_control *podev;
struct qcedev_async_req qcedev_areq;
struct qcedev_async_req *qcedev_areq;
struct qcedev_stat *pstat;

qcedev_areq = kzalloc(sizeof(struct qcedev_async_req), GFP_KERNEL);
if (!qcedev_areq)
return -ENOMEM;

handle = file->private_data;
podev = handle->cntl;
qcedev_areq.handle = handle;
qcedev_areq->handle = handle;
if (podev == NULL || podev->magic != QCEDEV_MAGIC) {
pr_err("%s: invalid handle %pK\n",
__func__, podev);
Expand All @@ -1623,27 +1627,27 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
if (_IOC_TYPE(cmd) != QCEDEV_IOC_MAGIC)
return -ENOTTY;

init_completion(&qcedev_areq.complete);
init_completion(&qcedev_areq->complete);
pstat = &_qcedev_stat;

switch (cmd) {
case QCEDEV_IOCTL_ENC_REQ:
case QCEDEV_IOCTL_DEC_REQ:
if (copy_from_user(&qcedev_areq.cipher_op_req,
if (copy_from_user(&qcedev_areq->cipher_op_req,
(void __user *)arg,
sizeof(struct qcedev_cipher_op_req)))
return -EFAULT;
qcedev_areq.op_type = QCEDEV_CRYPTO_OPER_CIPHER;
qcedev_areq->op_type = QCEDEV_CRYPTO_OPER_CIPHER;

if (qcedev_check_cipher_params(&qcedev_areq.cipher_op_req,
if (qcedev_check_cipher_params(&qcedev_areq->cipher_op_req,
podev))
return -EINVAL;

err = qcedev_vbuf_ablk_cipher(&qcedev_areq, handle);
err = qcedev_vbuf_ablk_cipher(qcedev_areq, handle);
if (err)
return err;
if (copy_to_user((void __user *)arg,
&qcedev_areq.cipher_op_req,
&qcedev_areq->cipher_op_req,
sizeof(struct qcedev_cipher_op_req)))
return -EFAULT;
break;
Expand All @@ -1652,23 +1656,23 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
{
struct scatterlist sg_src;

if (copy_from_user(&qcedev_areq.sha_op_req,
if (copy_from_user(&qcedev_areq->sha_op_req,
(void __user *)arg,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
mutex_lock(&hash_access_lock);
if (qcedev_check_sha_params(&qcedev_areq.sha_op_req, podev)) {
if (qcedev_check_sha_params(&qcedev_areq->sha_op_req, podev)) {
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.op_type = QCEDEV_CRYPTO_OPER_SHA;
err = qcedev_hash_init(&qcedev_areq, handle, &sg_src);
qcedev_areq->op_type = QCEDEV_CRYPTO_OPER_SHA;
err = qcedev_hash_init(qcedev_areq, handle, &sg_src);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
}
mutex_unlock(&hash_access_lock);
if (copy_to_user((void __user *)arg, &qcedev_areq.sha_op_req,
if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
}
Expand All @@ -1681,19 +1685,19 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
{
struct scatterlist sg_src;

if (copy_from_user(&qcedev_areq.sha_op_req,
if (copy_from_user(&qcedev_areq->sha_op_req,
(void __user *)arg,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
mutex_lock(&hash_access_lock);
if (qcedev_check_sha_params(&qcedev_areq.sha_op_req, podev)) {
if (qcedev_check_sha_params(&qcedev_areq->sha_op_req, podev)) {
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.op_type = QCEDEV_CRYPTO_OPER_SHA;
qcedev_areq->op_type = QCEDEV_CRYPTO_OPER_SHA;

if (qcedev_areq.sha_op_req.alg == QCEDEV_ALG_AES_CMAC) {
err = qcedev_hash_cmac(&qcedev_areq, handle, &sg_src);
if (qcedev_areq->sha_op_req.alg == QCEDEV_ALG_AES_CMAC) {
err = qcedev_hash_cmac(qcedev_areq, handle, &sg_src);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
Expand All @@ -1704,7 +1708,7 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
err = qcedev_hash_update(&qcedev_areq, handle, &sg_src);
err = qcedev_hash_update(qcedev_areq, handle, &sg_src);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
Expand All @@ -1717,11 +1721,11 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
memcpy(&qcedev_areq.sha_op_req.digest[0],
memcpy(&qcedev_areq->sha_op_req.digest[0],
&handle->sha_ctxt.digest[0],
handle->sha_ctxt.diglen);
mutex_unlock(&hash_access_lock);
if (copy_to_user((void __user *)arg, &qcedev_areq.sha_op_req,
if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
}
Expand All @@ -1733,17 +1737,17 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
pr_err("%s Init was not called\n", __func__);
return -EINVAL;
}
if (copy_from_user(&qcedev_areq.sha_op_req,
if (copy_from_user(&qcedev_areq->sha_op_req,
(void __user *)arg,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
mutex_lock(&hash_access_lock);
if (qcedev_check_sha_params(&qcedev_areq.sha_op_req, podev)) {
if (qcedev_check_sha_params(&qcedev_areq->sha_op_req, podev)) {
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.op_type = QCEDEV_CRYPTO_OPER_SHA;
err = qcedev_hash_final(&qcedev_areq, handle);
qcedev_areq->op_type = QCEDEV_CRYPTO_OPER_SHA;
err = qcedev_hash_final(qcedev_areq, handle);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
Expand All @@ -1754,12 +1758,12 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.sha_op_req.diglen = handle->sha_ctxt.diglen;
memcpy(&qcedev_areq.sha_op_req.digest[0],
qcedev_areq->sha_op_req.diglen = handle->sha_ctxt.diglen;
memcpy(&qcedev_areq->sha_op_req.digest[0],
&handle->sha_ctxt.digest[0],
handle->sha_ctxt.diglen);
mutex_unlock(&hash_access_lock);
if (copy_to_user((void __user *)arg, &qcedev_areq.sha_op_req,
if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
handle->sha_ctxt.init_done = false;
Expand All @@ -1769,23 +1773,23 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
{
struct scatterlist sg_src;

if (copy_from_user(&qcedev_areq.sha_op_req,
if (copy_from_user(&qcedev_areq->sha_op_req,
(void __user *)arg,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
mutex_lock(&hash_access_lock);
if (qcedev_check_sha_params(&qcedev_areq.sha_op_req, podev)) {
if (qcedev_check_sha_params(&qcedev_areq->sha_op_req, podev)) {
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.op_type = QCEDEV_CRYPTO_OPER_SHA;
qcedev_hash_init(&qcedev_areq, handle, &sg_src);
err = qcedev_hash_update(&qcedev_areq, handle, &sg_src);
qcedev_areq->op_type = QCEDEV_CRYPTO_OPER_SHA;
qcedev_hash_init(qcedev_areq, handle, &sg_src);
err = qcedev_hash_update(qcedev_areq, handle, &sg_src);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
}
err = qcedev_hash_final(&qcedev_areq, handle);
err = qcedev_hash_final(qcedev_areq, handle);
if (err) {
mutex_unlock(&hash_access_lock);
return err;
Expand All @@ -1796,12 +1800,12 @@ long qcedev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
mutex_unlock(&hash_access_lock);
return -EINVAL;
}
qcedev_areq.sha_op_req.diglen = handle->sha_ctxt.diglen;
memcpy(&qcedev_areq.sha_op_req.digest[0],
qcedev_areq->sha_op_req.diglen = handle->sha_ctxt.diglen;
memcpy(&qcedev_areq->sha_op_req.digest[0],
&handle->sha_ctxt.digest[0],
handle->sha_ctxt.diglen);
mutex_unlock(&hash_access_lock);
if (copy_to_user((void __user *)arg, &qcedev_areq.sha_op_req,
if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
sizeof(struct qcedev_sha_op_req)))
return -EFAULT;
}
Expand Down
4 changes: 2 additions & 2 deletions drivers/hwmon/qpnp-adc-common.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2019, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
Expand Down Expand Up @@ -1247,7 +1247,7 @@ int32_t qpnp_adc_scale_default(struct qpnp_vadc_chip *vadc,
} else {
qpnp_adc_scale_with_calib_param(adc_code, adc_properties,
chan_properties, &scale_voltage);
if (!chan_properties->calib_type == CALIB_ABSOLUTE)
if (!(chan_properties->calib_type == CALIB_ABSOLUTE))
scale_voltage *= 1000;
}

Expand Down
Loading

0 comments on commit d630809

Please sign in to comment.