Skip to content

Commit

Permalink
Merge branch 'net-ipa-support-compile_test'
Browse files Browse the repository at this point in the history
Alex Elder says:

====================
net: ipa: support COMPILE_TEST

This series adds the IPA driver as a possible target when
the COMPILE_TEST configuration is enabled.  Two small changes to
dependent subsystems needed to be made for this to work.

Version 2 of this series adds one more patch, which adds the
declation of struct page to "gsi_trans.h".  The Intel kernel test
robot reported that this was a problem for the alpha build.
====================

Link: https://lore.kernel.org/r/20210107233404.17030-1-elder@linaro.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Jakub Kicinski committed Jan 9, 2021
2 parents 3f5ec37 + 38a4066 commit 7e34984
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 6 deletions.
10 changes: 6 additions & 4 deletions drivers/net/ipa/Kconfig
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
config QCOM_IPA
tristate "Qualcomm IPA support"
depends on ARCH_QCOM && 64BIT && NET
depends on QCOM_Q6V5_MSS
depends on 64BIT && NET
depends on ARCH_QCOM || COMPILE_TEST
depends on QCOM_RPROC_COMMON || (QCOM_RPROC_COMMON=n && COMPILE_TEST)
select QCOM_MDT_LOADER if ARCH_QCOM
select QCOM_QMI_HELPERS
select QCOM_MDT_LOADER
help
Choose Y or M here to include support for the Qualcomm
IP Accelerator (IPA), a hardware block present in some
Qualcomm SoCs. The IPA is a programmable protocol processor
that is capable of generic hardware handling of IP packets,
including routing, filtering, and NAT. Currently the IPA
driver supports only basic transport of network traffic
between the AP and modem, on the Qualcomm SDM845 SoC.
between the AP and modem, on the Qualcomm SDM845 and SC7180
SoCs.

Note that if selected, the selection type must match that
of QCOM_Q6V5_COMMON (Y or M).
Expand Down
1 change: 1 addition & 0 deletions drivers/net/ipa/gsi_trans.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

#include "ipa_cmd.h"

struct page;
struct scatterlist;
struct device;
struct sk_buff;
Expand Down
4 changes: 2 additions & 2 deletions include/linux/remoteproc/qcom_rproc.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@

struct notifier_block;

#if IS_ENABLED(CONFIG_QCOM_RPROC_COMMON)

/**
* enum qcom_ssr_notify_type - Startup/Shutdown events related to a remoteproc
* processor.
Expand All @@ -26,6 +24,8 @@ struct qcom_ssr_notify_data {
bool crashed;
};

#if IS_ENABLED(CONFIG_QCOM_RPROC_COMMON)

void *qcom_register_ssr_notifier(const char *name, struct notifier_block *nb);
int qcom_unregister_ssr_notifier(void *notify, struct notifier_block *nb);

Expand Down
35 changes: 35 additions & 0 deletions include/linux/soc/qcom/mdt_loader.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
struct device;
struct firmware;

#if IS_ENABLED(CONFIG_QCOM_MDT_LOADER)

ssize_t qcom_mdt_get_size(const struct firmware *fw);
int qcom_mdt_load(struct device *dev, const struct firmware *fw,
const char *fw_name, int pas_id, void *mem_region,
Expand All @@ -23,4 +25,37 @@ int qcom_mdt_load_no_init(struct device *dev, const struct firmware *fw,
phys_addr_t *reloc_base);
void *qcom_mdt_read_metadata(const struct firmware *fw, size_t *data_len);

#else /* !IS_ENABLED(CONFIG_QCOM_MDT_LOADER) */

static inline ssize_t qcom_mdt_get_size(const struct firmware *fw)
{
return -ENODEV;
}

static inline int qcom_mdt_load(struct device *dev, const struct firmware *fw,
const char *fw_name, int pas_id,
void *mem_region, phys_addr_t mem_phys,
size_t mem_size, phys_addr_t *reloc_base)
{
return -ENODEV;
}

static inline int qcom_mdt_load_no_init(struct device *dev,
const struct firmware *fw,
const char *fw_name, int pas_id,
void *mem_region, phys_addr_t mem_phys,
size_t mem_size,
phys_addr_t *reloc_base)
{
return -ENODEV;
}

static inline void *qcom_mdt_read_metadata(const struct firmware *fw,
size_t *data_len)
{
return ERR_PTR(-ENODEV);
}

#endif /* !IS_ENABLED(CONFIG_QCOM_MDT_LOADER) */

#endif

0 comments on commit 7e34984

Please sign in to comment.