From: David Brown Date: Tue, 12 Mar 2013 18:41:49 +0000 (-0700) Subject: ssbi: Allow compilation as a module X-Git-Tag: accepted/tizen/common/20141203.182822~2439^2~85 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4a6692e2ac4c6b09235a9568468dd83a380c271d;p=platform%2Fkernel%2Flinux-arm64.git ssbi: Allow compilation as a module The ssbi driver's read/write entry points are protected with wrappers in the case when the driver isn't enabled. These wrappers don't make any sense, since a client of the SSBI bus won't work without it. Make these just regular functions, so that the SSBI driver can be built as a module. Signed-off-by: David Brown Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/ssbi/Kconfig b/drivers/ssbi/Kconfig index b57c41b..c7bc534 100644 --- a/drivers/ssbi/Kconfig +++ b/drivers/ssbi/Kconfig @@ -5,7 +5,7 @@ menu "Qualcomm MSM SSBI bus support" config MSM_SSBI - bool "Qualcomm Single-wire Serial Bus Interface (SSBI)" + tristate "Qualcomm Single-wire Serial Bus Interface (SSBI)" help If you say yes to this option, support will be included for the built-in SSBI interface on Qualcomm MSM family processors. diff --git a/include/linux/msm_ssbi.h b/include/linux/msm_ssbi.h index cfa47df..0fe245b 100644 --- a/include/linux/msm_ssbi.h +++ b/include/linux/msm_ssbi.h @@ -33,17 +33,6 @@ struct msm_ssbi_platform_data { enum msm_ssbi_controller_type controller_type; }; -#ifdef CONFIG_MSM_SSBI int msm_ssbi_write(struct device *dev, u16 addr, u8 *buf, int len); int msm_ssbi_read(struct device *dev, u16 addr, u8 *buf, int len); -#else -static inline int msm_ssbi_write(struct device *dev, u16 addr, u8 *buf, int len) -{ - return -ENXIO; -} -static inline int msm_ssbi_read(struct device *dev, u16 addr, u8 *buf, int len) -{ - return -ENXIO; -} -#endif #endif