Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ MODSRC := $(shell pwd)
export EXTERNAL_BUILD = 1
export CONFIG_VIDEO_INTEL_IPU7 = m
export CONFIG_IPU_BRIDGE = y
export CONFIG_INTEL_IPU7_ACPI = m
export CONFIG_INTEL_IPU_ACPI = m

obj-y += drivers/media/pci/intel/ipu7/
obj-y += drivers/media/pci/intel/ipu7/psys/
obj-y += drivers/media/platform/intel/
subdir-ccflags-y += -I$(src)/include

subdir-ccflags-$(CONFIG_IPU_BRIDGE) += \
-DCONFIG_IPU_BRIDGE
subdir-ccflags-$(CONFIG_INTEL_IPU7_ACPI) += \
-DCONFIG_INTEL_IPU7_ACPI
subdir-ccflags-$(CONFIG_INTEL_IPU_ACPI) += \
-DCONFIG_INTEL_IPU_ACPI
subdir-ccflags-y += $(subdir-ccflags-m)

all:
Expand Down
14 changes: 5 additions & 9 deletions dkms.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,10 @@ CLEAN="make KERNELRELEASE=$kernelver KERNEL_SRC=$kernel_source_dir clean"
AUTOINSTALL="yes"
BUILD_EXCLUSIVE_CONFIG="CONFIG_VIDEO_V4L2_I2C"

BUILT_MODULE_NAME[0]="intel-ipu7"
BUILT_MODULE_LOCATION[0]="drivers/media/pci/intel/ipu7"
BUILT_MODULE_NAME[0]="intel-ipu7-psys"
BUILT_MODULE_LOCATION[0]="drivers/media/pci/intel/ipu7/psys"
DEST_MODULE_LOCATION[0]="/updates"

BUILT_MODULE_NAME[1]="intel-ipu7-isys"
BUILT_MODULE_LOCATION[1]="drivers/media/pci/intel/ipu7"
DEST_MODULE_LOCATION[1]="/updates"

BUILT_MODULE_NAME[2]="intel-ipu7-psys"
BUILT_MODULE_LOCATION[2]="drivers/media/pci/intel/ipu7/psys"
DEST_MODULE_LOCATION[2]="/updates"
BUILT_MODULE_NAME[1]="intel-ipu-acpi"
BUILT_MODULE_LOCATION[1]="drivers/media/platform/intel"
DEST_MODULE_LOCATION[1]="/updates"
8 changes: 4 additions & 4 deletions drivers/media/pci/intel/ipu7/ipu7-isys.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ static int isys_register_ext_subdev(struct ipu7_isys *isys,
client = isys_find_i2c_subdev(adapter, sd_info);
if (client) {
dev_warn(dev, "Device exists\n");
#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
/* TODO: remove i2c_unregister_device() */
i2c_unregister_device(client);
#else
Expand Down Expand Up @@ -263,7 +263,7 @@ static int isys_fw_log_init(struct ipu7_isys *isys)
return 0;
}

#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
/* The .bound() notifier callback when a match is found */
static int isys_notifier_bound(struct v4l2_async_notifier *notifier,
struct v4l2_subdev *sd,
Expand Down Expand Up @@ -497,7 +497,7 @@ static int isys_csi2_create_media_links(struct ipu7_isys *isys)
return 0;
}

#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
static int isys_register_devices(struct ipu7_isys *isys)
{
struct device *dev = &isys->adev->auxdev.dev;
Expand Down Expand Up @@ -771,7 +771,7 @@ static const struct dev_pm_ops isys_pm_ops = {
.resume = isys_resume,
};

#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
static void isys_remove(struct auxiliary_device *auxdev)
{
struct ipu7_isys *isys = dev_get_drvdata(&auxdev->dev);
Expand Down
4 changes: 2 additions & 2 deletions drivers/media/pci/intel/ipu7/ipu7.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
#include "ipu7-mmu.h"
#include "ipu7-platform-regs.h"

#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
#include <media/ipu-acpi.h>

#endif
Expand Down Expand Up @@ -2613,7 +2613,7 @@ static int ipu7_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
goto out_ipu_bus_del_devices;
}

#if IS_ENABLED(CONFIG_INTEL_IPU7_ACPI)
#if IS_ENABLED(CONFIG_INTEL_IPU_ACPI)
ipu_get_acpi_devices(&dev->platform_data);
#endif
isp->isys = ipu7_isys_init(pdev, dev, isys_ctrl, isys_base,
Expand Down
3 changes: 1 addition & 2 deletions drivers/media/platform/intel/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ config INTEL_IPU7_FPGA_PDATA
development and mainly used for pixter or sensor enablement
without ACPI support.

config INTEL_IPU7_ACPI
config INTEL_IPU_ACPI
tristate "Enable IPU ACPI driver"
default VIDEO_INTEL_IPU7
depends on I2C
depends on ACPI
help
Expand Down
13 changes: 7 additions & 6 deletions drivers/media/platform/intel/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (c) 2010 - 2022 Intel Corporation.
# Copyright (c) 2010 - 2025 Intel Corporation.

is_kernel_lt_6_10 = $(shell if [ $$(printf "6.10\n$(KERNELVERSION)" | sort -V | head -n1) != "6.10" ]; then echo 1; fi)
ifeq ($(is_kernel_lt_6_10), 1)
Expand All @@ -8,12 +8,13 @@ src := $(srctree)/$(src)
endif
endif

ccflags-y += -I$(src)/../../pci/intel/ipu7/
ccflags-y += -I$(src)/../../../staging/media/ipu7/

ifneq ($(filter y m, $(CONFIG_INTEL_IPU7_ACPI)),)
obj-$(CONFIG_INTEL_IPU7_ACPI) += ipu-acpi.o \
ipu-acpi-pdata.o \
ipu-acpi-common.o
ifneq ($(filter y m, $(CONFIG_INTEL_IPU_ACPI)),)
obj-$(CONFIG_INTEL_IPU_ACPI) += intel-ipu-acpi.o
intel-ipu-acpi-y += ipu-acpi.o \
ipu-acpi-pdata.o \
ipu-acpi-common.o
else
obj-y += ipu7-fpga-pdata.o
endif
10 changes: 8 additions & 2 deletions drivers/media/platform/intel/ipu-acpi-common.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Copyright (c) 2016-2024 Intel Corporation.
* Copyright (c) 2016-2025 Intel Corporation.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License version
Expand All @@ -13,7 +13,9 @@
*
*/
#include <linux/platform_device.h>
#include <linux/version.h>
#include <linux/pci.h>
#include <linux/gpio/consumer.h>

#include <media/ipu-acpi-pdata.h>
#include <media/ipu-acpi.h>

Expand Down Expand Up @@ -365,8 +367,12 @@ int ipu_acpi_get_dep_data(struct device *dev,
continue;

/* Process device IN3472 created by acpi */
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 17, 0)
if (acpi_bus_get_device(dep_devices.handles[i], &device)) {
#else
device = acpi_fetch_acpi_dev(dep_devices.handles[i]);
if (!device) {
#endif
pr_err("IPU ACPI: Failed to get ACPI device");
return -ENODEV;
}
Expand Down
Loading