Merge branch 'LA.UM.7.8.9.C2.08.00.00.618.110' via branch 'qcom-msm-4.9' into android-msm-pixel-4.9
Conflicts: Makefile drivers/char/adsprpc.c drivers/char/diag/diag_usb.c drivers/misc/qseecom.c drivers/mmc/core/sdio_cis.c drivers/mmc/host/sdhci-msm-ice.c drivers/net/usb/lan78xx.c drivers/platform/msm/ipa/ipa_v3/rmnet_ipa.c drivers/soc/qcom/msm_smp2p.c drivers/usb/gadget/function/f_gsi.c include/linux/sched/sysctl.h net/netfilter/xt_qtaguid.c Bug: 171355577 Change-Id: I0a4d226a334a5cc7e6013dba9e0857ae197e3ca7 Signed-off-by: Johnny Lee <johnnlee@google.com>
This commit is contained in:
@@ -6,6 +6,8 @@ ifeq ($(KERNEL_TARGET),)
|
||||
INSTALLED_KERNEL_TARGET := $(PRODUCT_OUT)/kernel
|
||||
endif
|
||||
|
||||
INSTALLED_KERNEL_VM_TARGET := $(PRODUCT_OUT)/kernel_vm
|
||||
|
||||
TARGET_KERNEL_MAKE_ENV := $(strip $(TARGET_KERNEL_MAKE_ENV))
|
||||
ifeq ($(TARGET_KERNEL_MAKE_ENV),)
|
||||
KERNEL_MAKE_ENV :=
|
||||
@@ -44,7 +46,21 @@ TARGET_KERNEL_CROSS_COMPILE_PREFIX := $(strip $(TARGET_KERNEL_CROSS_COMPILE_PREF
|
||||
ifeq ($(TARGET_KERNEL_CROSS_COMPILE_PREFIX),)
|
||||
KERNEL_CROSS_COMPILE := arm-eabi-
|
||||
else
|
||||
KERNEL_CROSS_COMPILE := $(shell pwd)/$(TARGET_TOOLS_PREFIX)
|
||||
KERNEL_CROSS_COMPILE := $(TARGET_KERNEL_CROSS_COMPILE_PREFIX)
|
||||
endif
|
||||
|
||||
ifeq ($(KERNEL_LLVM_SUPPORT), true)
|
||||
ifeq ($(KERNEL_SD_LLVM_SUPPORT), true) #Using sd-llvm compiler
|
||||
ifeq ($(shell echo $(SDCLANG_PATH) | head -c 1),/)
|
||||
KERNEL_LLVM_BIN := $(SDCLANG_PATH)/clang
|
||||
else
|
||||
KERNEL_LLVM_BIN := $(shell pwd)/$(SDCLANG_PATH)/clang
|
||||
endif
|
||||
$(warning "Using sdllvm" $(KERNEL_LLVM_BIN))
|
||||
else
|
||||
KERNEL_LLVM_BIN := $(shell pwd)/$(CLANG) #Using aosp-llvm compiler
|
||||
$(warning "Using aosp-llvm" $(KERNEL_LLVM_BIN))
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(TARGET_PREBUILT_KERNEL),)
|
||||
@@ -53,6 +69,7 @@ KERNEL_GCC_NOANDROID_CHK := $(shell (echo "int main() {return 0;}" | $(KERNEL_CR
|
||||
ifeq ($(strip $(KERNEL_GCC_NOANDROID_CHK)),0)
|
||||
KERNEL_CFLAGS := KCFLAGS=-mno-android
|
||||
endif
|
||||
endif
|
||||
|
||||
mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
|
||||
current_dir := $(notdir $(patsubst %/,%,$(dir $(mkfile_path))))
|
||||
@@ -64,12 +81,16 @@ ifeq ($(TARGET_KERNEL),$(current_dir))
|
||||
KERNEL_OUT := $(TARGET_OUT_INTERMEDIATES)/kernel/$(TARGET_KERNEL)
|
||||
KERNEL_SYMLINK := $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ
|
||||
KERNEL_USR := $(KERNEL_SYMLINK)/usr
|
||||
KERNEL_VM_OUT := $(TARGET_OUT_INTERMEDIATES)/kernel_vm/$(TARGET_KERNEL)
|
||||
KERNEL_VM_SYMLINK := $(TARGET_OUT_INTERMEDIATES)/KERNEL_VM_OBJ
|
||||
KERNEL_VM_USR := $(KERNEL_VM_SYMLINK)/usr
|
||||
else
|
||||
# Legacy style, kernel source directly under kernel
|
||||
KERNEL_LEGACY_DIR := true
|
||||
BUILD_ROOT_LOC := ../
|
||||
TARGET_KERNEL_SOURCE := kernel
|
||||
KERNEL_OUT := $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ
|
||||
KERNEL_VM_OUT := $(TARGET_OUT_INTERMEDIATES)/KERNEL_VM_OBJ
|
||||
endif
|
||||
|
||||
KERNEL_CONFIG := $(KERNEL_OUT)/.config
|
||||
@@ -80,26 +101,32 @@ else
|
||||
|
||||
ifeq ($(TARGET_USES_UNCOMPRESSED_KERNEL),true)
|
||||
$(info Using uncompressed kernel)
|
||||
TARGET_PREBUILT_INT_KERNEL := $(KERNEL_OUT)/arch/$(KERNEL_ARCH)/boot/Image
|
||||
TARGET_PREBUILT_INT_KERNEL_ := arch/$(KERNEL_ARCH)/boot/Image
|
||||
else
|
||||
ifeq ($(KERNEL_ARCH),arm64)
|
||||
TARGET_PREBUILT_INT_KERNEL := $(KERNEL_OUT)/arch/$(KERNEL_ARCH)/boot/Image.gz
|
||||
TARGET_PREBUILT_INT_KERNEL_ := arch/$(KERNEL_ARCH)/boot/Image.gz
|
||||
else
|
||||
TARGET_PREBUILT_INT_KERNEL := $(KERNEL_OUT)/arch/$(KERNEL_ARCH)/boot/zImage
|
||||
TARGET_PREBUILT_INT_KERNEL_ := arch/$(KERNEL_ARCH)/boot/zImage
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(TARGET_KERNEL_APPEND_DTB), true)
|
||||
$(info Using appended DTB)
|
||||
TARGET_PREBUILT_INT_KERNEL := $(TARGET_PREBUILT_INT_KERNEL)-dtb
|
||||
TARGET_PREBUILT_INT_KERNEL_ := $(TARGET_PREBUILT_INT_KERNEL_)-dtb
|
||||
endif
|
||||
|
||||
KERNEL_HEADERS_INSTALL := $(KERNEL_OUT)/usr
|
||||
KERNEL_MODULES_INSTALL ?= system
|
||||
KERNEL_MODULES_OUT ?= $(PRODUCT_OUT)/$(KERNEL_MODULES_INSTALL)/lib/modules
|
||||
|
||||
TARGET_PREBUILT_INT_KERNEL := $(KERNEL_OUT)/$(TARGET_PREBUILT_INT_KERNEL_)
|
||||
TARGET_PREBUILT_KERNEL := $(TARGET_PREBUILT_INT_KERNEL)
|
||||
|
||||
KERNEL_VM_CONFIG := $(KERNEL_VM_OUT)/.config
|
||||
KERNEL_VM_HEADERS_INSTALL := $(KERNEL_VM_OUT)/usr
|
||||
TARGET_PREBUILT_INT_KERNEL_VM := $(KERNEL_VM_OUT)/$(TARGET_PREBUILT_INT_KERNEL_)
|
||||
TARGET_PREBUILT_KERNEL_VM := $(TARGET_PREBUILT_INT_KERNEL_VM)
|
||||
|
||||
define mv-modules
|
||||
mdpath=`find $(KERNEL_MODULES_OUT) -type f -name modules.dep`;\
|
||||
if [ "$$mdpath" != "" ];then\
|
||||
@@ -116,38 +143,75 @@ mpath=`dirname $$mdpath`; rm -rf $$mpath;\
|
||||
fi
|
||||
endef
|
||||
|
||||
$(TARGET_PREBUILT_INT_KERNEL_VM): ;
|
||||
|
||||
ifneq ($(KERNEL_LEGACY_DIR),true)
|
||||
$(KERNEL_USR): $(KERNEL_HEADERS_INSTALL)
|
||||
rm -rf $(KERNEL_SYMLINK)
|
||||
ln -s kernel/$(TARGET_KERNEL) $(KERNEL_SYMLINK)
|
||||
|
||||
$(TARGET_PREBUILT_INT_KERNEL): $(KERNEL_USR)
|
||||
|
||||
ifneq ($(KERNEL_VM_DEFCONFIG),)
|
||||
$(KERNEL_VM_USR): $(KERNEL_VM_HEADERS_INSTALL)
|
||||
rm -rf $(KERNEL_VM_SYMLINK);
|
||||
ln -s kernel_vm/$(TARGET_KERNEL) $(KERNEL_VM_SYMLINK);
|
||||
|
||||
$(TARGET_PREBUILT_INT_KERNEL_VM): $(KERNEL_VM_USR)
|
||||
endif
|
||||
endif
|
||||
|
||||
ifneq ($(KERNEL_VM_DEFCONFIG),)
|
||||
$(KERNEL_VM_OUT):
|
||||
mkdir -p $(KERNEL_VM_OUT);
|
||||
|
||||
$(KERNEL_VM_CONFIG): $(KERNEL_VM_OUT)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_VM_DEFCONFIG);
|
||||
if [ ! -z "$(KERNEL_CONFIG_OVERRIDE)" ]; then \
|
||||
echo "Overriding kernel config with '$(KERNEL_CONFIG_OVERRIDE)'"; \
|
||||
echo $(KERNEL_CONFIG_OVERRIDE) >> $(KERNEL_VM_OUT)/.config; \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi;
|
||||
|
||||
$(TARGET_PREBUILT_INT_KERNEL_VM): $(KERNEL_VM_OUT) $(KERNEL_VM_HEADERS_INSTALL)
|
||||
echo "Building vm kernel...";
|
||||
rm -rf $(KERNEL_VM_OUT)/arch/$(KERNEL_ARCH)/boot/dts;
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_CFLAGS);
|
||||
|
||||
$(KERNEL_VM_HEADERS_INSTALL): $(KERNEL_VM_OUT)
|
||||
rm -f $(BUILD_ROOT_LOC)$(KERNEL_VM_CONFIG);
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_VM_DEFCONFIG);
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) headers_install;
|
||||
if [ -d "$(KERNEL_VM_HEADERS_INSTALL)/include/bringup_headers" ]; then \
|
||||
cp -Rf $(KERNEL_VM_HEADERS_INSTALL)/include/bringup_headers/* $(KERNEL_VM_HEADERS_INSTALL)/include/ ; fi ;
|
||||
if [ ! -z "$(KERNEL_CONFIG_OVERRIDE)" ]; then \
|
||||
echo $(KERNEL_CONFIG_OVERRIDE) >> $(KERNEL_VM_OUT)/.config; \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_VM_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi;
|
||||
endif
|
||||
|
||||
$(KERNEL_OUT):
|
||||
mkdir -p $(KERNEL_OUT)
|
||||
|
||||
$(KERNEL_CONFIG): $(KERNEL_OUT)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(KERNEL_DEFCONFIG)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_DEFCONFIG)
|
||||
$(hide) if [ ! -z "$(KERNEL_CONFIG_OVERRIDE)" ]; then \
|
||||
echo "Overriding kernel config with '$(KERNEL_CONFIG_OVERRIDE)'"; \
|
||||
echo $(KERNEL_CONFIG_OVERRIDE) >> $(KERNEL_OUT)/.config; \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) oldconfig; fi
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi
|
||||
|
||||
$(TARGET_PREBUILT_INT_KERNEL): $(KERNEL_OUT) $(KERNEL_HEADERS_INSTALL)
|
||||
$(hide) echo "Building kernel..."
|
||||
$(hide) rm -rf $(KERNEL_OUT)/arch/$(KERNEL_ARCH)/boot/dts
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(KERNEL_CFLAGS)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(KERNEL_CFLAGS) modules
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) INSTALL_MOD_PATH=$(BUILD_ROOT_LOC)../$(KERNEL_MODULES_INSTALL) INSTALL_MOD_STRIP=1 $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) modules_install
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_CFLAGS)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_CFLAGS) modules
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) INSTALL_MOD_PATH=$(BUILD_ROOT_LOC)../$(KERNEL_MODULES_INSTALL) INSTALL_MOD_STRIP=1 $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) modules_install
|
||||
$(mv-modules)
|
||||
$(clean-module-folder)
|
||||
|
||||
$(KERNEL_HEADERS_INSTALL): $(KERNEL_OUT)
|
||||
$(hide) if [ ! -z "$(KERNEL_HEADER_DEFCONFIG)" ]; then \
|
||||
rm -f $(BUILD_ROOT_LOC)$(KERNEL_CONFIG); \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(KERNEL_HEADER_DEFCONFIG); \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) headers_install;\
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_HEADER_DEFCONFIG); \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_HEADER_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) headers_install;\
|
||||
if [ -d "$(KERNEL_HEADERS_INSTALL)/include/bringup_headers" ]; then \
|
||||
cp -Rf $(KERNEL_HEADERS_INSTALL)/include/bringup_headers/* $(KERNEL_HEADERS_INSTALL)/include/ ;\
|
||||
fi ;\
|
||||
@@ -155,22 +219,22 @@ $(KERNEL_HEADERS_INSTALL): $(KERNEL_OUT)
|
||||
$(hide) if [ "$(KERNEL_HEADER_DEFCONFIG)" != "$(KERNEL_DEFCONFIG)" ]; then \
|
||||
echo "Used a different defconfig for header generation"; \
|
||||
rm -f $(BUILD_ROOT_LOC)$(KERNEL_CONFIG); \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(KERNEL_DEFCONFIG); fi
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) $(KERNEL_DEFCONFIG); fi
|
||||
$(hide) if [ ! -z "$(KERNEL_CONFIG_OVERRIDE)" ]; then \
|
||||
echo "Overriding kernel config with '$(KERNEL_CONFIG_OVERRIDE)'"; \
|
||||
echo $(KERNEL_CONFIG_OVERRIDE) >> $(KERNEL_OUT)/.config; \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) oldconfig; fi
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) oldconfig; fi
|
||||
|
||||
.PHONY: kerneltags
|
||||
kerneltags: $(KERNEL_OUT) $(KERNEL_CONFIG)
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) tags
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) tags
|
||||
|
||||
.PHONY: kernelconfig
|
||||
kernelconfig: $(KERNEL_OUT) $(KERNEL_CONFIG)
|
||||
env KCONFIG_NOTIMESTAMP=true \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) menuconfig
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) menuconfig
|
||||
env KCONFIG_NOTIMESTAMP=true \
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) savedefconfig
|
||||
$(MAKE) -C $(TARGET_KERNEL_SOURCE) O=$(BUILD_ROOT_LOC)$(KERNEL_OUT) $(KERNEL_MAKE_ENV) ARCH=$(KERNEL_ARCH) CROSS_COMPILE=$(KERNEL_CROSS_COMPILE) $(real_cc) savedefconfig
|
||||
cp $(KERNEL_OUT)/defconfig $(TARGET_KERNEL_SOURCE)/arch/$(KERNEL_ARCH)/configs/$(KERNEL_DEFCONFIG)
|
||||
|
||||
endif
|
||||
|
||||
1
arch/arm64/configs/vendor/sdm670-perf_defconfig
vendored
Symbolic link
1
arch/arm64/configs/vendor/sdm670-perf_defconfig
vendored
Symbolic link
@@ -0,0 +1 @@
|
||||
../sdm670-perf_defconfig
|
||||
1
arch/arm64/configs/vendor/sdm670_defconfig
vendored
Symbolic link
1
arch/arm64/configs/vendor/sdm670_defconfig
vendored
Symbolic link
@@ -0,0 +1 @@
|
||||
../sdm670_defconfig
|
||||
1
arch/arm64/configs/vendor/sdm845-perf_defconfig
vendored
Symbolic link
1
arch/arm64/configs/vendor/sdm845-perf_defconfig
vendored
Symbolic link
@@ -0,0 +1 @@
|
||||
../sdm845-perf_defconfig
|
||||
1
arch/arm64/configs/vendor/sdm845_defconfig
vendored
Symbolic link
1
arch/arm64/configs/vendor/sdm845_defconfig
vendored
Symbolic link
@@ -0,0 +1 @@
|
||||
../sdm845_defconfig
|
||||
@@ -116,6 +116,7 @@
|
||||
#define FASTRPC_STATIC_HANDLE_MAX (20)
|
||||
#define FASTRPC_LATENCY_CTRL_ENB (1)
|
||||
|
||||
#define MAX_SIZE_LIMIT (0x78000000)
|
||||
#define INIT_FILELEN_MAX (2*1024*1024)
|
||||
#define INIT_MEMLEN_MAX (8*1024*1024)
|
||||
|
||||
@@ -681,12 +682,20 @@ static int fastrpc_mmap_find(struct fastrpc_file *fl, int fd,
|
||||
static int dma_alloc_memory(dma_addr_t *region_phys, void **vaddr, size_t size,
|
||||
unsigned long dma_attrs)
|
||||
{
|
||||
int err = 0;
|
||||
struct fastrpc_apps *me = &gfa;
|
||||
|
||||
if (me->dev == NULL) {
|
||||
pr_err("device adsprpc-mem is not initialized\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
VERIFY(err, size > 0 && size < MAX_SIZE_LIMIT);
|
||||
if (err) {
|
||||
err = -EFAULT;
|
||||
pr_err("adsprpc: %s: invalid allocation size 0x%zx\n",
|
||||
__func__, size);
|
||||
return err;
|
||||
}
|
||||
*vaddr = dma_alloc_attrs(me->dev, size, region_phys, GFP_KERNEL,
|
||||
dma_attrs);
|
||||
if (IS_ERR_OR_NULL(*vaddr)) {
|
||||
@@ -3479,11 +3488,8 @@ bail:
|
||||
static int fastrpc_device_open(struct inode *inode, struct file *filp)
|
||||
{
|
||||
int err = 0;
|
||||
struct dentry *debugfs_file;
|
||||
struct fastrpc_file *fl = NULL;
|
||||
struct fastrpc_apps *me = &gfa;
|
||||
char strpid[PID_SIZE];
|
||||
int buf_size = 0;
|
||||
|
||||
/*
|
||||
* Indicates the device node opened
|
||||
@@ -3501,13 +3507,6 @@ static int fastrpc_device_open(struct inode *inode, struct file *filp)
|
||||
VERIFY(err, NULL != (fl = kzalloc(sizeof(*fl), GFP_KERNEL)));
|
||||
if (err)
|
||||
return err;
|
||||
snprintf(strpid, PID_SIZE, "%d", current->pid);
|
||||
buf_size = strlen(current->comm) + strlen("_") + strlen(strpid) + 1;
|
||||
fl->debug_buf = kzalloc(buf_size, GFP_KERNEL);
|
||||
snprintf(fl->debug_buf, UL_SIZE, "%.10s%s%d",
|
||||
current->comm, "_", current->pid);
|
||||
debugfs_file = debugfs_create_file(fl->debug_buf, 0644,
|
||||
debugfs_root, fl, &debugfs_fops);
|
||||
|
||||
context_list_ctor(&fl->clst);
|
||||
spin_lock_init(&fl->hlock);
|
||||
@@ -3517,14 +3516,11 @@ static int fastrpc_device_open(struct inode *inode, struct file *filp)
|
||||
INIT_HLIST_HEAD(&fl->remote_bufs);
|
||||
INIT_HLIST_NODE(&fl->hn);
|
||||
fl->sessionid = 0;
|
||||
fl->tgid = current->tgid;
|
||||
fl->apps = me;
|
||||
fl->mode = FASTRPC_MODE_SERIAL;
|
||||
fl->cid = -1;
|
||||
fl->dev_minor = dev_minor;
|
||||
fl->init_mem = NULL;
|
||||
if (debugfs_file != NULL)
|
||||
fl->debugfs_file = debugfs_file;
|
||||
fl->qos_request = 0;
|
||||
fl->refcount = 0;
|
||||
filp->private_data = fl;
|
||||
@@ -3537,12 +3533,38 @@ static int fastrpc_device_open(struct inode *inode, struct file *filp)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int fastrpc_set_process_info(struct fastrpc_file *fl)
|
||||
{
|
||||
int err = 0, buf_size = 0;
|
||||
char strpid[PID_SIZE];
|
||||
|
||||
fl->tgid = current->tgid;
|
||||
snprintf(strpid, PID_SIZE, "%d", current->pid);
|
||||
buf_size = strlen(current->comm) + strlen("_") + strlen(strpid) + 1;
|
||||
fl->debug_buf = kzalloc(buf_size, GFP_KERNEL);
|
||||
if (!fl->debug_buf) {
|
||||
err = -ENOMEM;
|
||||
return err;
|
||||
}
|
||||
snprintf(fl->debug_buf, UL_SIZE, "%.10s%s%d",
|
||||
current->comm, "_", current->pid);
|
||||
fl->debugfs_file = debugfs_create_file(fl->debug_buf, 0644,
|
||||
debugfs_root, fl, &debugfs_fops);
|
||||
if (!fl->debugfs_file)
|
||||
pr_warn("Error: %s: %s: failed to create debugfs file %s\n",
|
||||
current->comm, __func__, fl->debug_buf);
|
||||
return err;
|
||||
}
|
||||
|
||||
static int fastrpc_get_info(struct fastrpc_file *fl, uint32_t *info)
|
||||
{
|
||||
int err = 0;
|
||||
uint32_t cid;
|
||||
|
||||
VERIFY(err, fl != NULL);
|
||||
if (err)
|
||||
goto bail;
|
||||
err = fastrpc_set_process_info(fl);
|
||||
if (err)
|
||||
goto bail;
|
||||
if (fl->cid == -1) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2016, 2018-2019 The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-2016, 2018, 2020, 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
|
||||
@@ -636,8 +636,8 @@ int diag_usb_register(int id, int ctxt, struct diag_mux_ops *ops)
|
||||
INIT_WORK(&(ch->read_done_work), usb_read_done_work_fn);
|
||||
INIT_WORK(&(ch->connect_work), usb_connect_work_fn);
|
||||
INIT_WORK(&(ch->disconnect_work), usb_disconnect_work_fn);
|
||||
strlcpy(wq_name, "DIAG_USB_", DIAG_USB_STRING_SZ);
|
||||
strlcat(wq_name, ch->name, sizeof(ch->name));
|
||||
strlcpy(wq_name, "DIAG_USB_", sizeof(wq_name));
|
||||
strlcat(wq_name, ch->name, sizeof(wq_name));
|
||||
ch->usb_wq = create_singlethread_workqueue(wq_name);
|
||||
if (!ch->usb_wq)
|
||||
goto err;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2008-2019, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2008-2020, 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
|
||||
@@ -4211,7 +4211,7 @@ static int __init diagchar_init(void)
|
||||
pr_debug("diagchar initializing ..\n");
|
||||
driver->num = 1;
|
||||
driver->name = ((void *)driver) + sizeof(struct diagchar_dev);
|
||||
strlcpy(driver->name, "diag", 4);
|
||||
strlcpy(driver->name, "diag", 5);
|
||||
/* Get major number from kernel and initialize */
|
||||
ret = alloc_chrdev_region(&dev, driver->minor_start,
|
||||
driver->num, driver->name);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012-2017, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2018, 2020, 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
|
||||
@@ -176,8 +176,8 @@ int diagfwd_bridge_register(int id, int ctxt, struct diag_remote_dev_ops *ops)
|
||||
if (!ch->dci_read_buf)
|
||||
return -ENOMEM;
|
||||
ch->dci_read_len = 0;
|
||||
strlcpy(wq_name, "diag_dci_", 10);
|
||||
strlcat(wq_name, ch->name, sizeof(ch->name));
|
||||
strlcpy(wq_name, "diag_dci_", sizeof(wq_name));
|
||||
strlcat(wq_name, ch->name, sizeof(wq_name));
|
||||
INIT_WORK(&(ch->dci_read_work), bridge_dci_read_work_fn);
|
||||
ch->dci_wq = create_singlethread_workqueue(wq_name);
|
||||
if (!ch->dci_wq) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2011-2018, 2020, 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
|
||||
@@ -724,6 +724,7 @@ int diag_add_diag_id_to_list(uint8_t diag_id, char *process_name,
|
||||
uint8_t pd_val, uint8_t peripheral)
|
||||
{
|
||||
struct diag_id_tbl_t *new_item = NULL;
|
||||
int process_len = 0;
|
||||
|
||||
if (!process_name || diag_id == 0)
|
||||
return -EINVAL;
|
||||
@@ -732,7 +733,8 @@ int diag_add_diag_id_to_list(uint8_t diag_id, char *process_name,
|
||||
if (!new_item)
|
||||
return -ENOMEM;
|
||||
kmemleak_not_leak(new_item);
|
||||
new_item->process_name = kzalloc(strlen(process_name) + 1, GFP_KERNEL);
|
||||
process_len = strlen(process_name);
|
||||
new_item->process_name = kzalloc(process_len + 1, GFP_KERNEL);
|
||||
if (!new_item->process_name) {
|
||||
kfree(new_item);
|
||||
new_item = NULL;
|
||||
@@ -742,7 +744,7 @@ int diag_add_diag_id_to_list(uint8_t diag_id, char *process_name,
|
||||
new_item->diag_id = diag_id;
|
||||
new_item->pd_val = pd_val;
|
||||
new_item->peripheral = peripheral;
|
||||
strlcpy(new_item->process_name, process_name, strlen(process_name) + 1);
|
||||
strlcpy(new_item->process_name, process_name, process_len + 1);
|
||||
INIT_LIST_HEAD(&new_item->link);
|
||||
mutex_lock(&driver->diag_id_mutex);
|
||||
list_add_tail(&new_item->link, &driver->diag_id_list);
|
||||
@@ -838,7 +840,7 @@ static void process_diagid(uint8_t *buf, uint32_t len,
|
||||
ctrl_pkt.pkt_id = DIAG_CTRL_MSG_DIAGID;
|
||||
ctrl_pkt.version = 1;
|
||||
strlcpy((char *)&ctrl_pkt.process_name, process_name,
|
||||
strlen(process_name) + 1);
|
||||
sizeof(ctrl_pkt.process_name));
|
||||
ctrl_pkt.len = sizeof(ctrl_pkt.diag_id) + sizeof(ctrl_pkt.version) +
|
||||
strlen(process_name) + 1;
|
||||
err = diagfwd_write(peripheral, TYPE_CNTL, &ctrl_pkt, ctrl_pkt.len +
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012-2014, 2016 The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2014, 2016, 2020, 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
|
||||
@@ -407,8 +407,8 @@ int diag_hsic_init(void)
|
||||
INIT_WORK(&(ch->read_work), hsic_read_work_fn);
|
||||
INIT_WORK(&(ch->open_work), hsic_open_work_fn);
|
||||
INIT_WORK(&(ch->close_work), hsic_close_work_fn);
|
||||
strlcpy(wq_name, "DIAG_HSIC_", DIAG_HSIC_STRING_SZ);
|
||||
strlcat(wq_name, ch->name, sizeof(ch->name));
|
||||
strlcpy(wq_name, "DIAG_HSIC_", sizeof(wq_name));
|
||||
strlcat(wq_name, ch->name, sizeof(wq_name));
|
||||
ch->hsic_wq = create_singlethread_workqueue(wq_name);
|
||||
if (!ch->hsic_wq)
|
||||
goto fail;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-2018, 2020, 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
|
||||
@@ -695,8 +695,8 @@ int diag_mhi_init(void)
|
||||
INIT_WORK(&(mhi_info->read_done_work), mhi_read_done_work_fn);
|
||||
INIT_WORK(&(mhi_info->open_work), mhi_open_work_fn);
|
||||
INIT_WORK(&(mhi_info->close_work), mhi_close_work_fn);
|
||||
strlcpy(wq_name, "diag_mhi_", DIAG_MHI_STRING_SZ);
|
||||
strlcat(wq_name, mhi_info->name, sizeof(mhi_info->name));
|
||||
strlcpy(wq_name, "diag_mhi_", sizeof(wq_name));
|
||||
strlcat(wq_name, mhi_info->name, sizeof(wq_name));
|
||||
diagmem_init(driver, mhi_info->mempool);
|
||||
mhi_info->mempool_init = 1;
|
||||
mhi_info->mhi_wq = create_singlethread_workqueue(wq_name);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012, 2014, 2016 The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012, 2014, 2016, 2020, 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
|
||||
@@ -286,8 +286,8 @@ int diag_smux_init(void)
|
||||
|
||||
for (i = 0; i < NUM_SMUX_DEV; i++) {
|
||||
ch = &diag_smux[i];
|
||||
strlcpy(wq_name, "DIAG_SMUX_", 11);
|
||||
strlcat(wq_name, ch->name, sizeof(ch->name));
|
||||
strlcpy(wq_name, "DIAG_SMUX_", sizeof(wq_name));
|
||||
strlcat(wq_name, ch->name, sizeof(wq_name));
|
||||
ch->smux_wq = create_singlethread_workqueue(wq_name);
|
||||
if (!ch->smux_wq) {
|
||||
err = -ENOMEM;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2015-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2015-2018, 2020, 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
|
||||
@@ -767,8 +767,8 @@ static void __diag_socket_init(struct diag_socket_info *info)
|
||||
info->data_ready = 0;
|
||||
atomic_set(&info->flow_cnt, 0);
|
||||
spin_lock_init(&info->lock);
|
||||
strlcpy(wq_name, "DIAG_SOCKET_", 10);
|
||||
strlcat(wq_name, info->name, sizeof(info->name));
|
||||
strlcpy(wq_name, "DIAG_SOCKET_", sizeof(wq_name));
|
||||
strlcpy(wq_name, info->name, sizeof(wq_name));
|
||||
init_waitqueue_head(&info->read_wait_q);
|
||||
info->wq = create_singlethread_workqueue(wq_name);
|
||||
if (!info->wq) {
|
||||
|
||||
@@ -1668,12 +1668,16 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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);
|
||||
@@ -1684,27 +1688,27 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
@@ -1713,23 +1717,23 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
{
|
||||
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;
|
||||
}
|
||||
@@ -1742,19 +1746,19 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
{
|
||||
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;
|
||||
@@ -1765,7 +1769,7 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
@@ -1778,11 +1782,11 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
}
|
||||
@@ -1794,17 +1798,17 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
@@ -1815,12 +1819,12 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
@@ -1830,23 +1834,23 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
{
|
||||
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;
|
||||
@@ -1857,12 +1861,12 @@ static inline long qcedev_ioctl(struct file *file,
|
||||
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;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2017-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
|
||||
@@ -262,8 +262,7 @@ static void dp_display_deinitialize_hdcp(struct dp_display_private *dp)
|
||||
|
||||
sde_dp_hdcp2p2_deinit(dp->hdcp.data);
|
||||
dp_display_destroy_hdcp_workqueue(dp);
|
||||
if (&dp->hdcp_mutex)
|
||||
mutex_destroy(&dp->hdcp_mutex);
|
||||
mutex_destroy(&dp->hdcp_mutex);
|
||||
}
|
||||
|
||||
static int dp_display_initialize_hdcp(struct dp_display_private *dp)
|
||||
|
||||
@@ -4241,7 +4241,7 @@ static void _sde_plane_install_properties(struct drm_plane *plane,
|
||||
psde->catalog = catalog;
|
||||
|
||||
if (sde_is_custom_client()) {
|
||||
if (catalog->mixer_count && catalog->mixer &&
|
||||
if (catalog->mixer_count &&
|
||||
catalog->mixer[0].sblk->maxblendstages) {
|
||||
zpos_max = catalog->mixer[0].sblk->maxblendstages - 1;
|
||||
if (zpos_max > SDE_STAGE_MAX - SDE_STAGE_0 - 1)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2008-2019, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2008-2020, 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
|
||||
@@ -272,7 +272,7 @@ static void kgsl_destroy_ion(struct kgsl_dma_buf_meta *meta)
|
||||
{
|
||||
if (meta != NULL) {
|
||||
dma_buf_unmap_attachment(meta->attach, meta->table,
|
||||
DMA_FROM_DEVICE);
|
||||
DMA_BIDIRECTIONAL);
|
||||
dma_buf_detach(meta->dmabuf, meta->attach);
|
||||
dma_buf_put(meta->dmabuf);
|
||||
kfree(meta);
|
||||
@@ -2578,7 +2578,7 @@ static int kgsl_setup_dma_buf(struct kgsl_device *device,
|
||||
entry->memdesc.flags &= ~((uint64_t) KGSL_MEMFLAGS_USE_CPU_MAP);
|
||||
entry->memdesc.flags |= (uint64_t)KGSL_MEMFLAGS_USERMEM_ION;
|
||||
|
||||
sg_table = dma_buf_map_attachment(attach, DMA_TO_DEVICE);
|
||||
sg_table = dma_buf_map_attachment(attach, DMA_BIDIRECTIONAL);
|
||||
|
||||
if (IS_ERR_OR_NULL(sg_table)) {
|
||||
ret = PTR_ERR(sg_table);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2018, 2020, 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
|
||||
@@ -1747,7 +1747,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;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2018, 2020, 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
|
||||
@@ -1445,7 +1445,7 @@ int32_t qpnp_vadc_calib_vref(struct qpnp_vadc_chip *vadc,
|
||||
conv.mode_sel = ADC_OP_NORMAL_MODE << QPNP_VADC_OP_MODE_SHIFT;
|
||||
conv.hw_settle_time = ADC_CHANNEL_HW_SETTLE_DELAY_0US;
|
||||
conv.fast_avg_setup = ADC_FAST_AVG_SAMPLE_1;
|
||||
conv.cal_val = calib_type;
|
||||
conv.cal_val = (enum qpnp_adc_cal_val)calib_type;
|
||||
|
||||
if (vadc->vadc_hc) {
|
||||
rc = qpnp_vadc_hc_configure(vadc, &conv);
|
||||
@@ -1518,7 +1518,7 @@ int32_t qpnp_vadc_calib_gnd(struct qpnp_vadc_chip *vadc,
|
||||
conv.mode_sel = ADC_OP_NORMAL_MODE << QPNP_VADC_OP_MODE_SHIFT;
|
||||
conv.hw_settle_time = ADC_CHANNEL_HW_SETTLE_DELAY_0US;
|
||||
conv.fast_avg_setup = ADC_FAST_AVG_SAMPLE_1;
|
||||
conv.cal_val = calib_type;
|
||||
conv.cal_val = (enum qpnp_adc_cal_val)calib_type;
|
||||
|
||||
if (vadc->vadc_hc) {
|
||||
rc = qpnp_vadc_hc_configure(vadc, &conv);
|
||||
@@ -1636,10 +1636,10 @@ static int32_t qpnp_vadc_calib_device(struct qpnp_vadc_chip *vadc)
|
||||
(calib_read_1 - calib_read_2);
|
||||
vadc->adc->amux_prop->chan_prop->adc_graph[CALIB_RATIOMETRIC].dx =
|
||||
vadc->adc->adc_prop->adc_vdd_reference;
|
||||
vadc->adc->amux_prop->chan_prop->adc_graph[CALIB_RATIOMETRIC].adc_vref
|
||||
= calib_read_1;
|
||||
vadc->adc->amux_prop->chan_prop->adc_graph[CALIB_RATIOMETRIC].adc_gnd
|
||||
= calib_read_2;
|
||||
vadc->adc->amux_prop->chan_prop->adc_graph[CALIB_RATIOMETRIC].adc_vref =
|
||||
calib_read_1;
|
||||
vadc->adc->amux_prop->chan_prop->adc_graph[CALIB_RATIOMETRIC].adc_gnd =
|
||||
calib_read_2;
|
||||
|
||||
calib_fail:
|
||||
return rc;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2015-2017, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2015-2017, 2020, The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Description: CoreSight System Trace Macrocell driver
|
||||
*
|
||||
@@ -297,7 +297,7 @@ static void stm_generic_unlink(struct stm_data *stm_data,
|
||||
return;
|
||||
|
||||
/* If any OST entity is enabled do not disable the device */
|
||||
if (drvdata->entities)
|
||||
if (!bitmap_empty(drvdata->entities, OST_ENTITY_MAX))
|
||||
return;
|
||||
|
||||
coresight_disable(drvdata->csdev);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2017, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2017, 2020, 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
|
||||
@@ -166,8 +166,7 @@ int cam_cdm_acquire(struct cam_cdm_acquire_data *data)
|
||||
struct cam_hw_intf *hw;
|
||||
uint32_t hw_index = 0;
|
||||
|
||||
if ((!data) || (!data->identifier) || (!data->base_array) ||
|
||||
(!data->base_array_cnt))
|
||||
if (!data || !data->base_array_cnt)
|
||||
return -EINVAL;
|
||||
|
||||
if (get_cdm_mgr_refcount()) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2017-2019, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2017-2019, 2020, 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
|
||||
@@ -615,7 +615,8 @@ static int cam_ife_hw_mgr_acquire_res_ife_out_rdi(
|
||||
ife_out_res->hw_res[0] = vfe_acquire.vfe_out.rsrc_node;
|
||||
ife_out_res->is_dual_vfe = 0;
|
||||
ife_out_res->res_id = vfe_out_res_id;
|
||||
ife_out_res->res_type = CAM_ISP_RESOURCE_VFE_OUT;
|
||||
ife_out_res->res_type = (enum cam_ife_hw_mgr_res_type)
|
||||
CAM_ISP_RESOURCE_VFE_OUT;
|
||||
ife_src_res->child[ife_src_res->num_children++] = ife_out_res;
|
||||
|
||||
return 0;
|
||||
@@ -703,7 +704,8 @@ static int cam_ife_hw_mgr_acquire_res_ife_out_pixel(
|
||||
ife_out_res->hw_res[j]->res_id);
|
||||
|
||||
}
|
||||
ife_out_res->res_type = CAM_ISP_RESOURCE_VFE_OUT;
|
||||
ife_out_res->res_type = (enum cam_ife_hw_mgr_res_type)
|
||||
CAM_ISP_RESOURCE_VFE_OUT;
|
||||
ife_out_res->res_id = out_port->res_type;
|
||||
ife_out_res->parent = ife_src_res;
|
||||
ife_src_res->child[ife_src_res->num_children++] = ife_out_res;
|
||||
@@ -816,7 +818,8 @@ static int cam_ife_hw_mgr_acquire_res_ife_src(
|
||||
CAM_ERR(CAM_ISP, "Wrong IFE CSID Resource Node");
|
||||
goto err;
|
||||
}
|
||||
ife_src_res->res_type = vfe_acquire.rsrc_type;
|
||||
ife_src_res->res_type = (enum cam_ife_hw_mgr_res_type)
|
||||
vfe_acquire.rsrc_type;
|
||||
ife_src_res->res_id = vfe_acquire.vfe_in.res_id;
|
||||
ife_src_res->is_dual_vfe = csid_res->is_dual_vfe;
|
||||
|
||||
@@ -992,7 +995,8 @@ static int cam_ife_hw_mgr_acquire_res_ife_csid_ipp(
|
||||
csid_acquire.in_port = in_port;
|
||||
csid_acquire.out_port = in_port->data;
|
||||
|
||||
csid_res->res_type = CAM_ISP_RESOURCE_PIX_PATH;
|
||||
csid_res->res_type = (enum cam_ife_hw_mgr_res_type)
|
||||
CAM_ISP_RESOURCE_PIX_PATH;
|
||||
csid_res->res_id = CAM_IFE_PIX_PATH_RES_IPP;
|
||||
csid_res->is_dual_vfe = in_port->usage_type;
|
||||
|
||||
@@ -1185,7 +1189,8 @@ static int cam_ife_hw_mgr_acquire_res_ife_csid_rdi(
|
||||
goto err;
|
||||
}
|
||||
|
||||
csid_res->res_type = CAM_ISP_RESOURCE_PIX_PATH;
|
||||
csid_res->res_type = (enum cam_ife_hw_mgr_res_type)
|
||||
CAM_ISP_RESOURCE_PIX_PATH;
|
||||
csid_res->res_id = csid_acquire.res_id;
|
||||
csid_res->is_dual_vfe = 0;
|
||||
csid_res->hw_res[0] = csid_acquire.node_res;
|
||||
@@ -2200,7 +2205,7 @@ static int cam_ife_mgr_start_hw(void *hw_mgr_priv, void *start_hw_args)
|
||||
CAM_DBG(CAM_ISP, "Exit...(success)");
|
||||
return 0;
|
||||
err:
|
||||
stop_hw_method.hw_stop_cmd = CAM_CSID_HALT_IMMEDIATELY;
|
||||
stop_hw_method.hw_stop_cmd = CAM_ISP_HW_STOP_IMMEDIATELY;
|
||||
stop_args.ctxt_to_hw_map = start_args->ctxt_to_hw_map;
|
||||
stop_args.args = (void *)(&stop_hw_method);
|
||||
cam_ife_mgr_stop_hw(hw_mgr_priv, &stop_args);
|
||||
|
||||
@@ -186,7 +186,7 @@ static int cam_flash_ops(struct cam_flash_ctrl *flash_ctrl,
|
||||
if (flash_ctrl->switch_trigger)
|
||||
cam_res_mgr_led_trigger_event(
|
||||
flash_ctrl->switch_trigger,
|
||||
LED_SWITCH_ON);
|
||||
(enum led_brightness)LED_SWITCH_ON);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -214,7 +214,7 @@ int cam_flash_off(struct cam_flash_ctrl *flash_ctrl)
|
||||
|
||||
if (flash_ctrl->switch_trigger)
|
||||
cam_res_mgr_led_trigger_event(flash_ctrl->switch_trigger,
|
||||
LED_SWITCH_OFF);
|
||||
(enum led_brightness)LED_SWITCH_OFF);
|
||||
|
||||
flash_ctrl->flash_state = CAM_FLASH_STATE_START;
|
||||
return 0;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-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
|
||||
|
||||
@@ -1851,12 +1851,8 @@ static int hfi_process_session_rel_buf_done(u32 device_id,
|
||||
cmd_done.size = sizeof(struct msm_vidc_cb_cmd_done);
|
||||
cmd_done.session_id = (void *)(uintptr_t)pkt->session_id;
|
||||
cmd_done.status = hfi_map_err_status(pkt->error_type);
|
||||
if (pkt->rg_buffer_info) {
|
||||
cmd_done.data.buffer_info.buffer_addr = *pkt->rg_buffer_info;
|
||||
cmd_done.size = sizeof(struct hal_buffer_info);
|
||||
} else {
|
||||
dprintk(VIDC_ERR, "invalid payload in rel_buff_done\n");
|
||||
}
|
||||
cmd_done.data.buffer_info.buffer_addr = *pkt->rg_buffer_info;
|
||||
cmd_done.size = sizeof(struct hal_buffer_info);
|
||||
|
||||
info->response_type = HAL_SESSION_RELEASE_BUFFER_DONE;
|
||||
info->response.cmd = cmd_done;
|
||||
|
||||
@@ -1264,7 +1264,7 @@ static int qseecom_register_listener(struct qseecom_dev_handle *data,
|
||||
list_add_tail(&new_entry->list, &qseecom.registered_listener_list_head);
|
||||
|
||||
data->listener.id = rcvd_lstnr.listener_id;
|
||||
pr_warn("Service %d is registered\n", rcvd_lstnr.listener_id);
|
||||
pr_debug("Service %d is registered\n", rcvd_lstnr.listener_id);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -1323,7 +1323,7 @@ exit:
|
||||
kzfree(ptr_svc);
|
||||
|
||||
data->released = true;
|
||||
pr_warn("Service %d is unregistered\n", data->listener.id);
|
||||
pr_debug("Service %d is unregistered\n", data->listener.id);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -4002,7 +4002,7 @@ static int qseecom_receive_req(struct qseecom_dev_handle *data)
|
||||
if (wait_event_interruptible(this_lstnr->rcv_req_wq,
|
||||
__qseecom_listener_has_rcvd_req(data,
|
||||
this_lstnr))) {
|
||||
pr_warn("Interrupted: exiting Listener Service = %d\n",
|
||||
pr_debug("Interrupted: exiting Listener Service = %d\n",
|
||||
(uint32_t)data->listener.id);
|
||||
/* woken up for different reason */
|
||||
return -ERESTARTSYS;
|
||||
|
||||
@@ -29,6 +29,7 @@ static int cistpl_vers_1(struct mmc_card *card, struct sdio_func *func,
|
||||
{
|
||||
unsigned i, nr_strings;
|
||||
char **buffer, *string;
|
||||
size_t buf_len;
|
||||
|
||||
if (size < 2)
|
||||
return 0;
|
||||
@@ -58,7 +59,8 @@ static int cistpl_vers_1(struct mmc_card *card, struct sdio_func *func,
|
||||
|
||||
for (i = 0; i < nr_strings; i++) {
|
||||
buffer[i] = string;
|
||||
strcpy(string, buf);
|
||||
buf_len = strlen(buf) + 1;
|
||||
strlcpy(string, buf, buf_len);
|
||||
string += strlen(string) + 1;
|
||||
buf += strlen(buf) + 1;
|
||||
}
|
||||
|
||||
@@ -301,6 +301,7 @@ void sdhci_msm_ice_hci_update_noncq_cfg(struct sdhci_host *host,
|
||||
struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
|
||||
struct sdhci_msm_host *msm_host = pltfm_host->priv;
|
||||
unsigned int crypto_params = 0;
|
||||
unsigned int crypto_enable = !bypass;
|
||||
/*
|
||||
* The naming convention got changed between ICE2.0 and ICE3.0
|
||||
* registers fields. Below is the equivalent names for
|
||||
@@ -311,7 +312,7 @@ void sdhci_msm_ice_hci_update_noncq_cfg(struct sdhci_host *host,
|
||||
*/
|
||||
/* Configure ICE bypass mode */
|
||||
crypto_params |=
|
||||
((!bypass) & MASK_SDHCI_MSM_ICE_HCI_PARAM_CE)
|
||||
(crypto_enable & MASK_SDHCI_MSM_ICE_HCI_PARAM_CE)
|
||||
<< OFFSET_SDHCI_MSM_ICE_HCI_PARAM_CE;
|
||||
/* Configure Crypto Configure Index (CCI) */
|
||||
crypto_params |= (key_index &
|
||||
|
||||
@@ -865,12 +865,13 @@ static int lan78xx_read_otp(struct lan78xx_net *dev, u32 offset,
|
||||
ret = lan78xx_read_raw_otp(dev, 0, 1, &sig);
|
||||
|
||||
if (ret == 0) {
|
||||
if (sig == OTP_INDICATOR_1)
|
||||
offset = (u32)offset;
|
||||
else if (sig == OTP_INDICATOR_2)
|
||||
offset += 0x100;
|
||||
else
|
||||
ret = -EINVAL;
|
||||
if (sig != OTP_INDICATOR_1) {
|
||||
if (sig == OTP_INDICATOR_2)
|
||||
offset += 0x100;
|
||||
else
|
||||
ret = -EINVAL;
|
||||
}
|
||||
|
||||
if (!ret)
|
||||
ret = lan78xx_read_raw_otp(dev, offset, length, data);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-2018, 2020, 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
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2018, 2020, 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
|
||||
@@ -1242,7 +1242,7 @@ int ipa3_add_rt_rule_after(struct ipa_ioc_add_rt_rule_after *rules)
|
||||
tbl = __ipa3_find_rt_tbl(rules->ip, rules->rt_tbl_name);
|
||||
if (tbl == NULL || (tbl->cookie != IPA_RT_TBL_COOKIE)) {
|
||||
IPAERR_RL("failed finding rt tbl name = %s\n",
|
||||
rules->rt_tbl_name ? rules->rt_tbl_name : "");
|
||||
(rules->rt_tbl_name != NULL) ? rules->rt_tbl_name : "");
|
||||
ret = -EINVAL;
|
||||
goto bail;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2020, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-2018, 2020, 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
|
||||
@@ -728,7 +728,8 @@ static int ipa3_wwan_add_ul_flt_rule_to_ipa(void)
|
||||
retval = -EFAULT;
|
||||
}
|
||||
|
||||
req->install_status = QMI_RESULT_SUCCESS_V01;
|
||||
req->install_status = (enum ipa_qmi_result_type_v01)
|
||||
QMI_RESULT_SUCCESS_V01;
|
||||
req->rule_id_valid = 1;
|
||||
req->rule_id_len = rmnet_ipa3_ctx->num_q6_rules;
|
||||
for (i = 0; i < rmnet_ipa3_ctx->num_q6_rules; i++) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2011-2018, 2020, 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
|
||||
@@ -1478,7 +1478,7 @@ void usb_bam_finish_suspend_(struct work_struct *w)
|
||||
|
||||
info_ptr = container_of(w, struct usb_bam_ipa_handshake_info,
|
||||
finish_suspend_work);
|
||||
cur_bam = info_ptr->cur_bam_mode;
|
||||
cur_bam = info_ptr->bam_type;
|
||||
|
||||
log_event_dbg("%s: Finishing suspend sequence(BAM=%s)\n", __func__,
|
||||
bam_enable_strings[cur_bam]);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2016-2018, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2016-2018, 2020, 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
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2014-2016, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2014-2016, 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
|
||||
@@ -568,9 +568,9 @@ void glink_dfs_update_list(struct dentry *curr_dent, struct dentry *parent,
|
||||
dbgfs_dent_s->parent = parent;
|
||||
dbgfs_dent_s->self = curr_dent;
|
||||
strlcpy(dbgfs_dent_s->self_name,
|
||||
curr, strlen(curr) + 1);
|
||||
curr, sizeof(dbgfs_dent_s->self_name));
|
||||
strlcpy(dbgfs_dent_s->par_name, par_dir,
|
||||
strlen(par_dir) + 1);
|
||||
sizeof(dbgfs_dent_s->par_name));
|
||||
INIT_WORK(&dbgfs_dent_s->rm_work,
|
||||
glink_dfs_dent_rm_worker);
|
||||
mutex_lock(&dent_list_lock_lha0);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2010-2012, 2014-2017, The Linux Foundation. All rights
|
||||
/* Copyright (c) 2010-2012, 2014-2017, 2019 The Linux Foundation. All rights
|
||||
* reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -577,7 +577,6 @@ static ssize_t msm_bus_dbg_update_request_write(struct file *file,
|
||||
list_for_each_entry(cldata, &cl_list, list) {
|
||||
if (strnstr(chid, cldata->pdata->name, cnt)) {
|
||||
found = 1;
|
||||
cldata = cldata;
|
||||
strsep(&chid, " ");
|
||||
if (chid) {
|
||||
ret = kstrtoul(chid, 10, &index);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2017, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2017, 2020, 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
|
||||
@@ -294,7 +294,7 @@ static int msm_minidump_add_header(void)
|
||||
|
||||
/* 4th section is linux banner */
|
||||
banner = (char *)ehdr + strtbl_off + MAX_STRTBL_SIZE;
|
||||
strlcpy(banner, linux_banner, strlen(linux_banner) + 1);
|
||||
strlcpy(banner, linux_banner, strlen(banner) + 1);
|
||||
|
||||
shdr->sh_type = SHT_PROGBITS;
|
||||
shdr->sh_offset = (elf_addr_t)(strtbl_off + MAX_STRTBL_SIZE);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* drivers/soc/qcom/smp2p.c
|
||||
*
|
||||
* Copyright (c) 2013-2016, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2013-2016, 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
|
||||
@@ -989,17 +989,29 @@ void smp2p_init_header(struct smp2p_smem __iomem *header_ptr,
|
||||
int local_pid, int remote_pid,
|
||||
uint32_t features, uint32_t version)
|
||||
{
|
||||
header_ptr->magic = SMP2P_MAGIC;
|
||||
SMP2P_SET_LOCAL_PID(header_ptr, rem_loc_proc_id, local_pid);
|
||||
SMP2P_SET_REMOTE_PID(header_ptr, rem_loc_proc_id, remote_pid);
|
||||
SMP2P_SET_FEATURES(header_ptr, feature_version, features);
|
||||
SMP2P_SET_ENT_TOTAL(header_ptr, valid_total_ent, SMP2P_MAX_ENTRY);
|
||||
SMP2P_SET_ENT_VALID(header_ptr, valid_total_ent, 0);
|
||||
header_ptr->flags = 0;
|
||||
uint32_t rem_loc_proc_id = 0;
|
||||
uint32_t valid_total_ent = 0;
|
||||
uint32_t feature_version = 0;
|
||||
|
||||
writel_relaxed(SMP2P_MAGIC, &header_ptr->magic);
|
||||
|
||||
SMP2P_SET_LOCAL_PID(rem_loc_proc_id, local_pid);
|
||||
SMP2P_SET_REMOTE_PID(rem_loc_proc_id, remote_pid);
|
||||
writel_relaxed(rem_loc_proc_id, &header_ptr->rem_loc_proc_id);
|
||||
|
||||
SMP2P_SET_FEATURES(feature_version, features);
|
||||
writel_relaxed(feature_version, &header_ptr->feature_version);
|
||||
|
||||
SMP2P_SET_ENT_TOTAL(valid_total_ent, SMP2P_MAX_ENTRY);
|
||||
SMP2P_SET_ENT_VALID(valid_total_ent, 0);
|
||||
writel_relaxed(valid_total_ent, &header_ptr->valid_total_ent);
|
||||
|
||||
writel_relaxed(0, &header_ptr->flags);
|
||||
|
||||
/* ensure that all fields are valid before version is written */
|
||||
wmb();
|
||||
SMP2P_SET_VERSION(header_ptr, feature_version, version);
|
||||
SMP2P_SET_VERSION(feature_version, version);
|
||||
writel_relaxed(feature_version, &header_ptr->feature_version);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2014-2017, 2020, 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
|
||||
@@ -474,7 +474,7 @@ int sysmon_send_shutdown(struct subsys_desc *dest_desc)
|
||||
shutdown_ack_ret = wait_for_shutdown_ack(dest_desc);
|
||||
if (shutdown_ack_ret < 0) {
|
||||
pr_err("shutdown_ack SMP2P bit for %s not set\n", data->name);
|
||||
if (!&data->ind_recv.done) {
|
||||
if (!completion_done(&data->ind_recv)) {
|
||||
pr_err("QMI shutdown indication not received\n");
|
||||
ret = shutdown_ack_ret;
|
||||
}
|
||||
|
||||
@@ -420,7 +420,7 @@ struct ion_heap *ion_secure_carveout_heap_create(
|
||||
}
|
||||
|
||||
manager->heap.ops = &ion_sc_heap_ops;
|
||||
manager->heap.type = ION_HEAP_TYPE_SECURE_CARVEOUT;
|
||||
manager->heap.type = (enum ion_heap_type)ION_HEAP_TYPE_SECURE_CARVEOUT;
|
||||
return &manager->heap;
|
||||
|
||||
err:
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
* Copyright (C) Linaro 2012
|
||||
* Author: <benjamin.gaignard@linaro.org> for ST-Ericsson.
|
||||
*
|
||||
* Copyright (c) 2016-2018, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2016-2018, 2020, The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* This software is licensed under the terms of the GNU General Public
|
||||
* License version 2, as published by the Free Software Foundation, and
|
||||
@@ -264,7 +264,7 @@ struct ion_heap *ion_cma_heap_create(struct ion_platform_heap *data)
|
||||
* used to make the link with reserved CMA memory
|
||||
*/
|
||||
heap->priv = data->priv;
|
||||
heap->type = ION_HEAP_TYPE_DMA;
|
||||
heap->type = (enum ion_heap_type)ION_HEAP_TYPE_DMA;
|
||||
cma_heap_has_outer_cache = data->has_outer_cache;
|
||||
return heap;
|
||||
}
|
||||
@@ -446,7 +446,7 @@ struct ion_heap *ion_cma_secure_heap_create(struct ion_platform_heap *data)
|
||||
* used to make the link with reserved CMA memory
|
||||
*/
|
||||
heap->priv = data->priv;
|
||||
heap->type = ION_HEAP_TYPE_HYP_CMA;
|
||||
heap->type = (enum ion_heap_type)ION_HEAP_TYPE_HYP_CMA;
|
||||
cma_heap_has_outer_cache = data->has_outer_cache;
|
||||
return heap;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* Copyright (C) Linaro 2012
|
||||
* Author: <benjamin.gaignard@linaro.org> for ST-Ericsson.
|
||||
* Copyright (c) 2013-2017, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2013-2017, 2020, The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* This software is licensed under the terms of the GNU General Public
|
||||
* License version 2, as published by the Free Software Foundation, and
|
||||
@@ -859,7 +859,7 @@ struct ion_heap *ion_secure_cma_heap_create(struct ion_platform_heap *data)
|
||||
mutex_init(&sheap->chunk_lock);
|
||||
mutex_init(&sheap->alloc_lock);
|
||||
sheap->heap.ops = &ion_secure_cma_ops;
|
||||
sheap->heap.type = ION_HEAP_TYPE_SECURE_DMA;
|
||||
sheap->heap.type = (enum ion_heap_type)ION_HEAP_TYPE_SECURE_DMA;
|
||||
sheap->npages = data->size >> PAGE_SHIFT;
|
||||
sheap->base = data->base;
|
||||
sheap->heap_size = data->size;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
*
|
||||
* Copyright (c) 2014-2016,2018 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2014-2016, 2018, 2020, 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
|
||||
@@ -118,7 +118,7 @@ static int ion_system_secure_heap_allocate(
|
||||
heap);
|
||||
|
||||
if (!ion_heap_is_system_secure_heap_type(secure_heap->heap.type) ||
|
||||
!is_cp_flag_present(flags)) {
|
||||
!(is_cp_flag_present(flags) || (flags & ION_FLAG_SECURE))) {
|
||||
pr_info("%s: Incorrect heap type or incorrect flags\n",
|
||||
__func__);
|
||||
return -EINVAL;
|
||||
@@ -393,7 +393,7 @@ struct ion_heap *ion_system_secure_heap_create(struct ion_platform_heap *unused)
|
||||
if (!heap)
|
||||
return ERR_PTR(-ENOMEM);
|
||||
heap->heap.ops = &system_secure_heap_ops;
|
||||
heap->heap.type = ION_HEAP_TYPE_SYSTEM_SECURE;
|
||||
heap->heap.type = (enum ion_heap_type)ION_HEAP_TYPE_SYSTEM_SECURE;
|
||||
heap->sys_heap = get_ion_heap(ION_SYSTEM_HEAP_ID);
|
||||
|
||||
heap->destroy_heap = false;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2011-2018, 2020, 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
|
||||
@@ -860,13 +860,15 @@ long msm_ion_custom_ioctl(struct ion_client *client,
|
||||
int ret;
|
||||
|
||||
ret = ion_walk_heaps(client, data.prefetch_data.heap_id,
|
||||
ION_HEAP_TYPE_SECURE_DMA,
|
||||
(void *)data.prefetch_data.len,
|
||||
ion_secure_cma_prefetch);
|
||||
(enum ion_heap_type)
|
||||
ION_HEAP_TYPE_SECURE_DMA,
|
||||
(void *)data.prefetch_data.len,
|
||||
ion_secure_cma_prefetch);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = ion_walk_heaps(client, data.prefetch_data.heap_id,
|
||||
(enum ion_heap_type)
|
||||
ION_HEAP_TYPE_SYSTEM_SECURE,
|
||||
(void *)&data.prefetch_data,
|
||||
ion_system_secure_heap_prefetch);
|
||||
@@ -878,6 +880,7 @@ long msm_ion_custom_ioctl(struct ion_client *client,
|
||||
{
|
||||
int ret;
|
||||
ret = ion_walk_heaps(client, data.prefetch_data.heap_id,
|
||||
(enum ion_heap_type)
|
||||
ION_HEAP_TYPE_SECURE_DMA,
|
||||
(void *)data.prefetch_data.len,
|
||||
ion_secure_cma_drain_pool);
|
||||
@@ -886,6 +889,7 @@ long msm_ion_custom_ioctl(struct ion_client *client,
|
||||
return ret;
|
||||
|
||||
ret = ion_walk_heaps(client, data.prefetch_data.heap_id,
|
||||
(enum ion_heap_type)
|
||||
ION_HEAP_TYPE_SYSTEM_SECURE,
|
||||
(void *)&data.prefetch_data,
|
||||
ion_system_secure_heap_drain);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2011-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
|
||||
@@ -403,12 +403,6 @@ static int qpnp_tm_probe(struct platform_device *pdev)
|
||||
int rc = 0;
|
||||
u8 raw_type[2], type, subtype;
|
||||
|
||||
if (!pdev || !(&pdev->dev) || !pdev->dev.of_node) {
|
||||
dev_err(&pdev->dev, "%s: device tree node not found\n",
|
||||
__func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
node = pdev->dev.of_node;
|
||||
|
||||
chip = kzalloc(sizeof(struct qpnp_tm_chip), GFP_KERNEL);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2017-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
|
||||
@@ -69,9 +69,9 @@ struct tsens_dbg_context {
|
||||
};
|
||||
|
||||
struct tsens_context {
|
||||
enum thermal_device_mode high_th_state;
|
||||
enum thermal_device_mode low_th_state;
|
||||
enum thermal_device_mode crit_th_state;
|
||||
enum thermal_trip_activation_mode high_th_state;
|
||||
enum thermal_trip_activation_mode low_th_state;
|
||||
enum thermal_trip_activation_mode crit_th_state;
|
||||
int high_temp;
|
||||
int low_temp;
|
||||
int crit_temp;
|
||||
|
||||
@@ -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
|
||||
@@ -314,7 +314,7 @@ static int tsens1xxx_get_temp(struct tsens_sensor *sensor, int *temp)
|
||||
}
|
||||
|
||||
static int tsens_tz_activate_trip_type(struct tsens_sensor *tm_sensor,
|
||||
int trip, enum thermal_device_mode mode)
|
||||
int trip, enum thermal_trip_activation_mode mode)
|
||||
{
|
||||
struct tsens_device *tmdev = NULL;
|
||||
unsigned int reg_cntl, code, hi_code, lo_code, mask;
|
||||
@@ -360,7 +360,7 @@ static int tsens_tz_activate_trip_type(struct tsens_sensor *tm_sensor,
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (mode == THERMAL_DEVICE_DISABLED)
|
||||
if (mode == THERMAL_TRIP_ACTIVATION_DISABLED)
|
||||
writel_relaxed(reg_cntl | mask,
|
||||
(TSENS_S0_UPPER_LOWER_STATUS_CTRL_ADDR(tmdev->tsens_tm_addr) +
|
||||
(tm_sensor->hw_id * TSENS_SN_ADDR_OFFSET)));
|
||||
@@ -439,7 +439,7 @@ static int tsens1xxx_set_trip_temp(struct tsens_sensor *tm_sensor,
|
||||
if (high_temp != INT_MAX) {
|
||||
rc = tsens_tz_activate_trip_type(tm_sensor,
|
||||
THERMAL_TRIP_CONFIGURABLE_HI,
|
||||
THERMAL_DEVICE_ENABLED);
|
||||
THERMAL_TRIP_ACTIVATION_ENABLED);
|
||||
if (rc) {
|
||||
pr_err("trip high enable error :%d\n", rc);
|
||||
goto fail;
|
||||
@@ -447,7 +447,7 @@ static int tsens1xxx_set_trip_temp(struct tsens_sensor *tm_sensor,
|
||||
} else {
|
||||
rc = tsens_tz_activate_trip_type(tm_sensor,
|
||||
THERMAL_TRIP_CONFIGURABLE_HI,
|
||||
THERMAL_DEVICE_DISABLED);
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED);
|
||||
if (rc) {
|
||||
pr_err("trip high disable error :%d\n", rc);
|
||||
goto fail;
|
||||
@@ -457,7 +457,7 @@ static int tsens1xxx_set_trip_temp(struct tsens_sensor *tm_sensor,
|
||||
if (low_temp != INT_MIN) {
|
||||
rc = tsens_tz_activate_trip_type(tm_sensor,
|
||||
THERMAL_TRIP_CONFIGURABLE_LOW,
|
||||
THERMAL_DEVICE_ENABLED);
|
||||
THERMAL_TRIP_ACTIVATION_ENABLED);
|
||||
if (rc) {
|
||||
pr_err("trip low enable activation error :%d\n", rc);
|
||||
goto fail;
|
||||
@@ -465,7 +465,7 @@ static int tsens1xxx_set_trip_temp(struct tsens_sensor *tm_sensor,
|
||||
} else {
|
||||
rc = tsens_tz_activate_trip_type(tm_sensor,
|
||||
THERMAL_TRIP_CONFIGURABLE_LOW,
|
||||
THERMAL_DEVICE_DISABLED);
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED);
|
||||
if (rc) {
|
||||
pr_err("trip low disable error :%d\n", rc);
|
||||
goto fail;
|
||||
@@ -521,15 +521,15 @@ static irqreturn_t tsens_irq_thread(int irq, void *data)
|
||||
if (th_temp > (temp/TSENS_SCALE_MILLIDEG)) {
|
||||
pr_debug("Re-arm high threshold\n");
|
||||
rc = tsens_tz_activate_trip_type(
|
||||
&tm->sensor[i],
|
||||
THERMAL_TRIP_CONFIGURABLE_HI,
|
||||
THERMAL_DEVICE_ENABLED);
|
||||
&tm->sensor[i],
|
||||
THERMAL_TRIP_CONFIGURABLE_HI,
|
||||
THERMAL_TRIP_ACTIVATION_ENABLED);
|
||||
if (rc)
|
||||
pr_err("high rearm failed");
|
||||
} else {
|
||||
upper_thr = true;
|
||||
tm->sensor[i].thr_state.high_th_state =
|
||||
THERMAL_DEVICE_DISABLED;
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -543,15 +543,15 @@ static irqreturn_t tsens_irq_thread(int irq, void *data)
|
||||
if (th_temp < (temp/TSENS_SCALE_MILLIDEG)) {
|
||||
pr_debug("Re-arm Low threshold\n");
|
||||
rc = tsens_tz_activate_trip_type(
|
||||
&tm->sensor[i],
|
||||
THERMAL_TRIP_CONFIGURABLE_LOW,
|
||||
THERMAL_DEVICE_ENABLED);
|
||||
&tm->sensor[i],
|
||||
THERMAL_TRIP_CONFIGURABLE_LOW,
|
||||
THERMAL_TRIP_ACTIVATION_ENABLED);
|
||||
if (rc)
|
||||
pr_err("low rearm failed");
|
||||
} else {
|
||||
lower_thr = true;
|
||||
tm->sensor[i].thr_state.low_th_state =
|
||||
THERMAL_DEVICE_DISABLED;
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED;
|
||||
}
|
||||
}
|
||||
spin_unlock_irqrestore(&tm->tsens_upp_low_lock, flags);
|
||||
|
||||
@@ -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
|
||||
@@ -381,7 +381,8 @@ static irqreturn_t tsens_tm_critical_irq_thread(int irq, void *data)
|
||||
TSENS_TM_CRITICAL_INT_CLEAR(
|
||||
tm->tsens_tm_addr));
|
||||
tm->sensor[i].thr_state.
|
||||
crit_th_state = THERMAL_DEVICE_DISABLED;
|
||||
crit_th_state =
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED;
|
||||
}
|
||||
spin_unlock_irqrestore(&tm->tsens_crit_lock, flags);
|
||||
}
|
||||
@@ -458,7 +459,8 @@ static irqreturn_t tsens_tm_irq_thread(int irq, void *data)
|
||||
} else {
|
||||
upper_thr = true;
|
||||
tm->sensor[i].thr_state.
|
||||
high_th_state = THERMAL_DEVICE_DISABLED;
|
||||
high_th_state =
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -490,7 +492,8 @@ static irqreturn_t tsens_tm_irq_thread(int irq, void *data)
|
||||
} else {
|
||||
lower_thr = true;
|
||||
tm->sensor[i].thr_state.
|
||||
low_th_state = THERMAL_DEVICE_DISABLED;
|
||||
low_th_state =
|
||||
THERMAL_TRIP_ACTIVATION_DISABLED;
|
||||
}
|
||||
}
|
||||
spin_unlock_irqrestore(&tm->tsens_upp_low_lock, flags);
|
||||
|
||||
@@ -111,14 +111,8 @@ struct bio {
|
||||
#define bio_op(bio) ((bio)->bi_opf >> BIO_OP_SHIFT)
|
||||
|
||||
#define bio_set_op_attrs(bio, op, op_flags) do { \
|
||||
if (__builtin_constant_p(op)) \
|
||||
BUILD_BUG_ON((op) + 0U >= (1U << REQ_OP_BITS)); \
|
||||
else \
|
||||
WARN_ON_ONCE((op) + 0U >= (1U << REQ_OP_BITS)); \
|
||||
if (__builtin_constant_p(op_flags)) \
|
||||
BUILD_BUG_ON((op_flags) + 0U >= (1U << BIO_OP_SHIFT)); \
|
||||
else \
|
||||
WARN_ON_ONCE((op_flags) + 0U >= (1U << BIO_OP_SHIFT)); \
|
||||
WARN_ON_ONCE((op) + 0U >= (1U << REQ_OP_BITS)); \
|
||||
WARN_ON_ONCE((op_flags) + 0U >= (1U << BIO_OP_SHIFT)); \
|
||||
(bio)->bi_opf = bio_flags(bio); \
|
||||
(bio)->bi_opf |= (((op) + 0U) << BIO_OP_SHIFT); \
|
||||
(bio)->bi_opf |= (op_flags); \
|
||||
|
||||
@@ -64,6 +64,7 @@ extern unsigned int sysctl_numa_balancing_scan_size;
|
||||
extern __read_mostly unsigned int sysctl_sched_migration_cost;
|
||||
extern __read_mostly unsigned int sysctl_sched_nr_migrate;
|
||||
extern __read_mostly unsigned int sysctl_sched_time_avg;
|
||||
|
||||
extern unsigned int sysctl_sched_shares_window;
|
||||
|
||||
int sched_proc_update_handler(struct ctl_table *table, int write,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2013-2017, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2013-2017, 2020 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
|
||||
@@ -104,82 +104,82 @@ enum qseecom_qsee_reentrancy_phase {
|
||||
QSEE_REENTRANCY_PHASE_MAX = 0xFF
|
||||
};
|
||||
|
||||
__packed struct qsee_apps_region_info_ireq {
|
||||
struct qsee_apps_region_info_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t addr;
|
||||
uint32_t size;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qsee_apps_region_info_64bit_ireq {
|
||||
struct qsee_apps_region_info_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint64_t addr;
|
||||
uint32_t size;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_check_app_ireq {
|
||||
struct qseecom_check_app_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
char app_name[MAX_APP_NAME_SIZE];
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_load_app_ireq {
|
||||
struct qseecom_load_app_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t mdt_len; /* Length of the mdt file */
|
||||
uint32_t img_len; /* Length of .bxx and .mdt files */
|
||||
uint32_t phy_addr; /* phy addr of the start of image */
|
||||
char app_name[MAX_APP_NAME_SIZE]; /* application name*/
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_load_app_64bit_ireq {
|
||||
struct qseecom_load_app_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t mdt_len;
|
||||
uint32_t img_len;
|
||||
uint64_t phy_addr;
|
||||
char app_name[MAX_APP_NAME_SIZE];
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_unload_app_ireq {
|
||||
struct qseecom_unload_app_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_id;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_load_lib_image_ireq {
|
||||
struct qseecom_load_lib_image_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t mdt_len;
|
||||
uint32_t img_len;
|
||||
uint32_t phy_addr;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_load_lib_image_64bit_ireq {
|
||||
struct qseecom_load_lib_image_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t mdt_len;
|
||||
uint32_t img_len;
|
||||
uint64_t phy_addr;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_unload_lib_image_ireq {
|
||||
struct qseecom_unload_lib_image_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_register_listener_ireq {
|
||||
struct qseecom_register_listener_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t listener_id;
|
||||
uint32_t sb_ptr;
|
||||
uint32_t sb_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_register_listener_64bit_ireq {
|
||||
struct qseecom_register_listener_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t listener_id;
|
||||
uint64_t sb_ptr;
|
||||
uint32_t sb_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_unregister_listener_ireq {
|
||||
struct qseecom_unregister_listener_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t listener_id;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_client_send_data_ireq {
|
||||
struct qseecom_client_send_data_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_id;
|
||||
uint32_t req_ptr;
|
||||
@@ -188,9 +188,9 @@ __packed struct qseecom_client_send_data_ireq {
|
||||
uint32_t rsp_len;
|
||||
uint32_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_client_send_data_64bit_ireq {
|
||||
struct qseecom_client_send_data_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_id;
|
||||
uint64_t req_ptr;
|
||||
@@ -199,36 +199,36 @@ __packed struct qseecom_client_send_data_64bit_ireq {
|
||||
uint32_t rsp_len;
|
||||
uint64_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_reg_log_buf_ireq {
|
||||
struct qseecom_reg_log_buf_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t phy_addr;
|
||||
uint32_t len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_reg_log_buf_64bit_ireq {
|
||||
struct qseecom_reg_log_buf_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint64_t phy_addr;
|
||||
uint32_t len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
/* send_data resp */
|
||||
__packed struct qseecom_client_listener_data_irsp {
|
||||
struct qseecom_client_listener_data_irsp {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t listener_id;
|
||||
uint32_t status;
|
||||
uint32_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_client_listener_data_64bit_irsp {
|
||||
struct qseecom_client_listener_data_64bit_irsp {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t listener_id;
|
||||
uint32_t status;
|
||||
uint64_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
/*
|
||||
* struct qseecom_command_scm_resp - qseecom response buffer
|
||||
@@ -237,40 +237,40 @@ __packed struct qseecom_client_listener_data_64bit_irsp {
|
||||
* buffer
|
||||
* @sb_in_rsp_len: length of command response
|
||||
*/
|
||||
__packed struct qseecom_command_scm_resp {
|
||||
struct qseecom_command_scm_resp {
|
||||
uint32_t result;
|
||||
enum qseecom_command_scm_resp_type resp_type;
|
||||
unsigned int data;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
struct qseecom_rpmb_provision_key {
|
||||
uint32_t key_type;
|
||||
};
|
||||
|
||||
__packed struct qseecom_client_send_service_ireq {
|
||||
struct qseecom_client_send_service_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t key_type; /* in */
|
||||
unsigned int req_len; /* in */
|
||||
uint32_t rsp_ptr; /* in/out */
|
||||
unsigned int rsp_len; /* in/out */
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_client_send_service_64bit_ireq {
|
||||
struct qseecom_client_send_service_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t key_type;
|
||||
unsigned int req_len;
|
||||
uint64_t rsp_ptr;
|
||||
unsigned int rsp_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_generate_ireq {
|
||||
struct qseecom_key_generate_ireq {
|
||||
uint32_t qsee_command_id;
|
||||
uint32_t flags;
|
||||
uint8_t key_id[QSEECOM_KEY_ID_SIZE];
|
||||
uint8_t hash32[QSEECOM_HASH_SIZE];
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_select_ireq {
|
||||
struct qseecom_key_select_ireq {
|
||||
uint32_t qsee_command_id;
|
||||
uint32_t ce;
|
||||
uint32_t pipe;
|
||||
@@ -278,33 +278,33 @@ __packed struct qseecom_key_select_ireq {
|
||||
uint32_t flags;
|
||||
uint8_t key_id[QSEECOM_KEY_ID_SIZE];
|
||||
uint8_t hash32[QSEECOM_HASH_SIZE];
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_delete_ireq {
|
||||
struct qseecom_key_delete_ireq {
|
||||
uint32_t qsee_command_id;
|
||||
uint32_t flags;
|
||||
uint8_t key_id[QSEECOM_KEY_ID_SIZE];
|
||||
uint8_t hash32[QSEECOM_HASH_SIZE];
|
||||
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_userinfo_update_ireq {
|
||||
struct qseecom_key_userinfo_update_ireq {
|
||||
uint32_t qsee_command_id;
|
||||
uint32_t flags;
|
||||
uint8_t key_id[QSEECOM_KEY_ID_SIZE];
|
||||
uint8_t current_hash32[QSEECOM_HASH_SIZE];
|
||||
uint8_t new_hash32[QSEECOM_HASH_SIZE];
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_max_count_query_ireq {
|
||||
struct qseecom_key_max_count_query_ireq {
|
||||
uint32_t flags;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_key_max_count_query_irsp {
|
||||
struct qseecom_key_max_count_query_irsp {
|
||||
uint32_t max_key_count;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_qteec_ireq {
|
||||
struct qseecom_qteec_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_id;
|
||||
uint32_t req_ptr;
|
||||
@@ -313,9 +313,9 @@ __packed struct qseecom_qteec_ireq {
|
||||
uint32_t resp_len;
|
||||
uint32_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_qteec_64bit_ireq {
|
||||
struct qseecom_qteec_64bit_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_id;
|
||||
uint64_t req_ptr;
|
||||
@@ -324,21 +324,20 @@ __packed struct qseecom_qteec_64bit_ireq {
|
||||
uint32_t resp_len;
|
||||
uint64_t sglistinfo_ptr;
|
||||
uint32_t sglistinfo_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_client_send_fsm_key_req {
|
||||
struct qseecom_client_send_fsm_key_req {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t req_ptr;
|
||||
uint32_t req_len;
|
||||
uint32_t rsp_ptr;
|
||||
uint32_t rsp_len;
|
||||
};
|
||||
} __attribute__((__packed__));
|
||||
|
||||
__packed struct qseecom_continue_blocked_request_ireq {
|
||||
struct qseecom_continue_blocked_request_ireq {
|
||||
uint32_t qsee_cmd_id;
|
||||
uint32_t app_or_session_id; /*legacy: app_id; smcinvoke: session_id*/
|
||||
};
|
||||
|
||||
} __attribute__((__packed__));
|
||||
|
||||
/********** ARMV8 SMC INTERFACE TZ MACRO *******************/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#! /usr/bin/env python2
|
||||
|
||||
# Copyright (c) 2009-2015, The Linux Foundation. All rights reserved.
|
||||
# Copyright (c) 2009-2015, 2017, 2019, The Linux Foundation. All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are met:
|
||||
@@ -45,6 +45,7 @@ build_dir = '../all-kernels'
|
||||
make_command = ["vmlinux", "modules", "dtbs"]
|
||||
all_options = {}
|
||||
compile64 = os.environ.get('CROSS_COMPILE64')
|
||||
clang_bin = os.environ.get('CLANG_BIN')
|
||||
|
||||
def error(msg):
|
||||
sys.stderr.write("error: %s\n" % msg)
|
||||
@@ -229,7 +230,7 @@ class Builder():
|
||||
self.name = name
|
||||
self.defconfig = defconfig
|
||||
|
||||
self.confname = self.defconfig.split('/')[-1]
|
||||
self.confname = re.sub('arch/arm[64]*/configs/', '', self.defconfig)
|
||||
|
||||
# Determine if this is a 64-bit target based on the location
|
||||
# of the defconfig.
|
||||
@@ -265,35 +266,31 @@ class Builder():
|
||||
steps.append(ExecStep(['make', 'O=%s' % dest_dir,
|
||||
self.confname], env=self.make_env))
|
||||
|
||||
if not all_options.updateconfigs:
|
||||
# Build targets can be dependent upon the completion of
|
||||
# previous build targets, so build them one at a time.
|
||||
# Build targets can be dependent upon the completion of
|
||||
# previous build targets, so build them one at a time.
|
||||
if os.environ.get('ARCH') == "arm64":
|
||||
cmd_line = ['make',
|
||||
'INSTALL_HDR_PATH=%s' % hdri_dir,
|
||||
'INSTALL_MOD_PATH=%s' % modi_dir,
|
||||
'O=%s' % dest_dir,
|
||||
'REAL_CC=%s' % clang_bin]
|
||||
else:
|
||||
cmd_line = ['make',
|
||||
'INSTALL_HDR_PATH=%s' % hdri_dir,
|
||||
'INSTALL_MOD_PATH=%s' % modi_dir,
|
||||
'O=%s' % dest_dir]
|
||||
build_targets = []
|
||||
for c in make_command:
|
||||
if re.match(r'^-{1,2}\w', c):
|
||||
cmd_line.append(c)
|
||||
else:
|
||||
build_targets.append(c)
|
||||
for t in build_targets:
|
||||
steps.append(ExecStep(cmd_line + [t], env=self.make_env))
|
||||
|
||||
# Copy the defconfig back.
|
||||
if all_options.configs or all_options.updateconfigs:
|
||||
steps.append(ExecStep(['make', 'O=%s' % dest_dir,
|
||||
'savedefconfig'], env=self.make_env))
|
||||
steps.append(CopyfileStep(savedefconfig, defconfig))
|
||||
build_targets = []
|
||||
for c in make_command:
|
||||
if re.match(r'^-{1,2}\w', c):
|
||||
cmd_line.append(c)
|
||||
else:
|
||||
build_targets.append(c)
|
||||
for t in build_targets:
|
||||
steps.append(ExecStep(cmd_line + [t], env=self.make_env))
|
||||
|
||||
return steps
|
||||
|
||||
def update_config(file, str):
|
||||
print 'Updating %s with \'%s\'\n' % (file, str)
|
||||
with open(file, 'a') as defconfig:
|
||||
defconfig.write(str + '\n')
|
||||
|
||||
def scan_configs():
|
||||
"""Get the full list of defconfigs appropriate for this tree."""
|
||||
names = []
|
||||
@@ -302,23 +299,20 @@ def scan_configs():
|
||||
r'apq*_defconfig',
|
||||
r'qsd*_defconfig',
|
||||
r'mpq*_defconfig',
|
||||
r'sdm[0-9]*_defconfig',
|
||||
r'sdx*_defconfig',
|
||||
)
|
||||
arch64_pats = (
|
||||
r'msm*_defconfig',
|
||||
r'sdm[0-9]*_defconfig',
|
||||
r'sdm*_defconfig',
|
||||
r'sdx*_defconfig',
|
||||
)
|
||||
for p in arch_pats:
|
||||
for n in glob.glob('arch/arm/configs/' + p):
|
||||
name = os.path.basename(n)[:-10]
|
||||
names.append(Builder(name, n))
|
||||
if 'CROSS_COMPILE64' in os.environ:
|
||||
for p in arch64_pats:
|
||||
for n in glob.glob('arch/arm64/configs/' + p):
|
||||
name = os.path.basename(n)[:-10] + "-64"
|
||||
names.append(Builder(name, n))
|
||||
for defconfig in glob.glob('arch/arm*/configs/vendor/*_defconfig'):
|
||||
target = os.path.basename(defconfig)[:-10]
|
||||
name = target + "-llvm"
|
||||
if 'arch/arm64' in defconfig:
|
||||
name = name + "-64"
|
||||
names.append(Builder(name, defconfig))
|
||||
|
||||
return names
|
||||
|
||||
def build_many(targets):
|
||||
@@ -334,8 +328,6 @@ def build_many(targets):
|
||||
|
||||
tracker = BuildTracker(parallel)
|
||||
for target in targets:
|
||||
if all_options.updateconfigs:
|
||||
update_config(target.defconfig, all_options.updateconfigs)
|
||||
steps = target.build()
|
||||
tracker.add_sequence(target.log_name, target.name, steps)
|
||||
tracker.run()
|
||||
@@ -351,25 +343,14 @@ def main():
|
||||
usage = ("""
|
||||
%prog [options] all -- Build all targets
|
||||
%prog [options] target target ... -- List specific targets
|
||||
%prog [options] perf -- Build all perf targets
|
||||
%prog [options] noperf -- Build all non-perf targets""")
|
||||
""")
|
||||
parser = OptionParser(usage=usage, version=version)
|
||||
parser.add_option('--configs', action='store_true',
|
||||
dest='configs',
|
||||
help="Copy configs back into tree")
|
||||
parser.add_option('--list', action='store_true',
|
||||
dest='list',
|
||||
help='List available targets')
|
||||
parser.add_option('-v', '--verbose', action='store_true',
|
||||
dest='verbose',
|
||||
help='Output to stdout in addition to log file')
|
||||
parser.add_option('--oldconfig', action='store_true',
|
||||
dest='oldconfig',
|
||||
help='Only process "make oldconfig"')
|
||||
parser.add_option('--updateconfigs',
|
||||
dest='updateconfigs',
|
||||
help="Update defconfigs with provided option setting, "
|
||||
"e.g. --updateconfigs=\'CONFIG_USE_THING=y\'")
|
||||
parser.add_option('-j', '--jobs', type='int', dest="jobs",
|
||||
help="Number of simultaneous jobs")
|
||||
parser.add_option('-l', '--load-average', type='int',
|
||||
@@ -392,25 +373,11 @@ def main():
|
||||
print " %s" % target.name
|
||||
sys.exit(0)
|
||||
|
||||
if options.oldconfig:
|
||||
make_command = ["oldconfig"]
|
||||
elif options.make_target:
|
||||
if options.make_target:
|
||||
make_command = options.make_target
|
||||
|
||||
if args == ['all']:
|
||||
build_many(configs)
|
||||
elif args == ['perf']:
|
||||
targets = []
|
||||
for t in configs:
|
||||
if "perf" in t.name:
|
||||
targets.append(t)
|
||||
build_many(targets)
|
||||
elif args == ['noperf']:
|
||||
targets = []
|
||||
for t in configs:
|
||||
if "perf" not in t.name:
|
||||
targets.append(t)
|
||||
build_many(targets)
|
||||
elif len(args) > 0:
|
||||
all_configs = {}
|
||||
for t in configs:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#! /usr/bin/env python2
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (c) 2011-2016, The Linux Foundation. All rights reserved.
|
||||
# Copyright (c) 2011-2017, The Linux Foundation. All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are met:
|
||||
@@ -40,10 +40,6 @@ import subprocess
|
||||
# force LANG to be set to en_US.UTF-8 to get consistent warnings.
|
||||
|
||||
allowed_warnings = set([
|
||||
"core.c:144",
|
||||
"inet_connection_sock.c:430",
|
||||
"inet_connection_sock.c:467",
|
||||
"inet6_connection_sock.c:89",
|
||||
])
|
||||
|
||||
# Capture the name of the object file, can find it.
|
||||
|
||||
Reference in New Issue
Block a user