Merge f967995ad3
on remote branch
Change-Id: I8d0fe23fb7e9c63137769a2f4deb735255695841
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Android makefile for spu kernel modules (spcom.ko and spss_utils.ko)
|
||||
ifeq ($(call is-vendor-board-platform,QCOM),true)
|
||||
ifeq ($(call is-board-platform-in-list,kalama pineapple),true)
|
||||
ifeq ($(call is-board-platform-in-list,kalama pineapple niobe),true)
|
||||
|
||||
# This makefile is only for DLKM
|
||||
ifneq ($(findstring vendor,$(LOCAL_PATH)),)
|
||||
|
@@ -18,6 +18,7 @@ ddk_headers(
|
||||
hdrs = glob(["include/uapi/linux/*.h"]),
|
||||
includes = [
|
||||
"include/uapi/linux",
|
||||
"include/uapi",
|
||||
],
|
||||
)
|
||||
|
||||
@@ -49,7 +50,8 @@ ddk_headers(
|
||||
],
|
||||
)
|
||||
|
||||
load(":target.bzl", "define_pineapple")
|
||||
load(":target.bzl", "define_modules")
|
||||
|
||||
define_pineapple()
|
||||
targets = ["pineapple", "niobe"]
|
||||
define_modules(targets)
|
||||
|
||||
|
4
Kbuild
4
Kbuild
@@ -2,8 +2,8 @@
|
||||
|
||||
|
||||
ifeq ($(CONFIG_QCOM_SPSS), m)
|
||||
include $(SPU_ROOT)/config/gki_pineapplespu.conf
|
||||
LINUXINCLUDE += -include $(SPU_ROOT)/config/gki_pineapplespuconf.h
|
||||
include $(SPU_ROOT)/config/gki_spu.conf
|
||||
LINUXINCLUDE += -include $(SPU_ROOT)/config/gki_spuconf.h
|
||||
endif
|
||||
|
||||
LINUXINCLUDE += -I$(srctree)/../../vendor/qcom/opensource/spu-kernel/include/uapi
|
||||
|
@@ -1,6 +1,6 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
/*
|
||||
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2021-2024 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2021, The Linux Foundation. All rights reserved.
|
||||
*/
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Copyright (c) 2015-2019, 2021 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2022-2023,2024 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*/
|
||||
|
||||
/*
|
||||
@@ -2722,7 +2722,7 @@ static int spcom_ioctl_handle_lock_dmabuf_command(struct spcom_ioctl_dmabuf_lock
|
||||
int fd = 0;
|
||||
int i = 0;
|
||||
|
||||
spcom_pr_dbg("Lock dmabuf cmd arg: ch_name[%s], fd[%d], padding[%u], PID[%ld]\n",
|
||||
spcom_pr_dbg("Lock dmabuf cmd arg: ch_name[%s], fd[%d], padding[%u], PID[%d]\n",
|
||||
arg->ch_name, arg->fd, arg->padding, current_pid());
|
||||
|
||||
ch_name = arg->ch_name;
|
||||
@@ -2825,7 +2825,7 @@ static int spcom_ioctl_handle_unlock_dmabuf_command(struct spcom_ioctl_dmabuf_lo
|
||||
int ret = 0;
|
||||
bool unlock_all = false;
|
||||
|
||||
spcom_pr_dbg("Unlock dmabuf cmd arg: ch_name[%s], fd[%d], padding[%u], PID[%ld]\n",
|
||||
spcom_pr_dbg("Unlock dmabuf cmd arg: ch_name[%s], fd[%d], padding[%u], PID[%d]\n",
|
||||
arg->ch_name, arg->fd, arg->padding, current_pid());
|
||||
|
||||
ch_name = arg->ch_name;
|
||||
@@ -3218,12 +3218,12 @@ bool is_arg_size_expected(unsigned int cmd, uint32_t arg_size)
|
||||
expected_size = sizeof(struct spcom_ioctl_dmabuf_lock);
|
||||
break;
|
||||
default:
|
||||
spcom_pr_err("No userspace data for ioctl cmd[%ld]\n", cmd);
|
||||
spcom_pr_err("No userspace data for ioctl cmd[%d]\n", cmd);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (arg_size != expected_size) {
|
||||
spcom_pr_err("Invalid cmd size: cmd[%ld], arg size[%u], expected[%u]\n",
|
||||
spcom_pr_err("Invalid cmd size: cmd[%d], arg size[%u], expected[%u]\n",
|
||||
cmd, arg_size, expected_size);
|
||||
return false;
|
||||
}
|
||||
@@ -3924,7 +3924,6 @@ static int spcom_probe(struct platform_device *pdev)
|
||||
pr_err("Unable to create IPC log context\n");
|
||||
|
||||
spcom_pr_info("Driver Initialization completed ok\n");
|
||||
|
||||
return 0;
|
||||
|
||||
fail_reg_chardev:
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-only
|
||||
/*
|
||||
* Copyright (c) 2016-2021, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2022,2024 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*/
|
||||
|
||||
/*
|
||||
@@ -535,13 +535,13 @@ static long spss_utils_ioctl(struct file *file,
|
||||
if (size && (cmd & IOC_IN)) {
|
||||
if (size > sizeof(data)) {
|
||||
pr_err("cmd [0x%x] size [0x%x] too large\n",
|
||||
cmd, size);
|
||||
cmd, (unsigned int)size);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (copy_from_user(data, (void __user *)arg, size)) {
|
||||
pr_err("copy_from_user() failed, cmd [0x%x] size [0x%x]\n",
|
||||
cmd, size);
|
||||
cmd, (unsigned int)size);
|
||||
return -EFAULT;
|
||||
}
|
||||
}
|
||||
@@ -569,7 +569,7 @@ static long spss_utils_ioctl(struct file *file,
|
||||
case SPSS_IOC_WAIT_FOR_EVENT:
|
||||
/* check input params */
|
||||
if (size != sizeof(struct spss_ioc_wait_for_event)) {
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, size);
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, (unsigned int)size);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = spss_wait_for_event(req);
|
||||
@@ -587,7 +587,7 @@ static long spss_utils_ioctl(struct file *file,
|
||||
case SPSS_IOC_SIGNAL_EVENT:
|
||||
/* check input params */
|
||||
if (size != sizeof(struct spss_ioc_signal_event)) {
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, size);
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, (unsigned int)size);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = spss_signal_event(req);
|
||||
@@ -604,7 +604,7 @@ static long spss_utils_ioctl(struct file *file,
|
||||
case SPSS_IOC_IS_EVENT_SIGNALED:
|
||||
/* check input params */
|
||||
if (size != sizeof(struct spss_ioc_is_signaled)) {
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, size);
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, (unsigned int)size);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = spss_is_event_signaled(req);
|
||||
@@ -622,7 +622,7 @@ static long spss_utils_ioctl(struct file *file,
|
||||
case SPSS_IOC_SET_SSR_STATE:
|
||||
/* check input params */
|
||||
if (size != sizeof(uint32_t)) {
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, size);
|
||||
pr_err("cmd [0x%x] invalid size [0x%x]\n", cmd, (unsigned int)size);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
@@ -931,7 +931,7 @@ static int spss_parse_dt(struct device_node *node)
|
||||
|
||||
/* cmac buffer after spss firmware end */
|
||||
cmac_mem_addr = pil_addr + pil_size;
|
||||
pr_info("iar_buf_addr [0x%08x].\n", cmac_mem_addr);
|
||||
pr_info("iar_buf_addr [0x%08x].\n", (unsigned int)cmac_mem_addr);
|
||||
|
||||
memset(saved_fw_cmac, 0xA5, sizeof(saved_fw_cmac));
|
||||
memset(saved_apps_cmac, 0xA5, sizeof(saved_apps_cmac));
|
||||
|
@@ -7,7 +7,7 @@ endif
|
||||
|
||||
ifeq ($(SPU_DLKM_ENABLE), true)
|
||||
ifneq ($(TARGET_BOARD_AUTO),true)
|
||||
ifeq ($(call is-board-platform-in-list, kalama pineapple),true)
|
||||
ifeq ($(call is-board-platform-in-list, kalama pineapple niobe),true)
|
||||
BOARD_VENDOR_KERNEL_MODULES += $(KERNEL_MODULES_OUT)/spcom.ko \
|
||||
$(KERNEL_MODULES_OUT)/spss_utils.ko
|
||||
endif
|
||||
|
@@ -1,9 +1,11 @@
|
||||
load(":spu_modules.bzl", "spu_driver_modules")
|
||||
load(":spu_module_build.bzl", "define_consolidate_gki_modules")
|
||||
|
||||
def define_pineapple():
|
||||
define_consolidate_gki_modules(
|
||||
target = "pineapple",
|
||||
def define_modules(targets):
|
||||
# go over all targets
|
||||
for t in targets:
|
||||
define_consolidate_gki_modules(
|
||||
target = t,
|
||||
registry = spu_driver_modules,
|
||||
modules = [
|
||||
"spcom",
|
||||
|
Reference in New Issue
Block a user