summaryrefslogtreecommitdiff
path: root/compat
diff options
context:
space:
mode:
authorDominik Sliwa <dominik.sliwa@toradex.com>2017-07-04 11:53:51 +0200
committerDominik Sliwa <dominik.sliwa@toradex.com>2017-08-21 17:21:16 +0200
commit84d6642e4d1609562abb421341c9a90c023247a1 (patch)
treeffcc2b23e887c7d5615303067978e185e67072cc /compat
parent52409fae3e4b8d16b68b61902fc09075cd97b75d (diff)
backports:fix compilation with toradex kernels
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com>
Diffstat (limited to 'compat')
-rw-r--r--compat/backport-3.18.c2
-rw-r--r--compat/compat-3.5.c3
-rw-r--r--compat/compat-3.6.c2
-rw-r--r--compat/compat-3.8.c3
-rw-r--r--compat/drivers-base-devcoredump.c2
5 files changed, 12 insertions, 0 deletions
diff --git a/compat/backport-3.18.c b/compat/backport-3.18.c
index dbef343..00c097e 100644
--- a/compat/backport-3.18.c
+++ b/compat/backport-3.18.c
@@ -179,9 +179,11 @@ void skb_complete_wifi_ack(struct sk_buff *skb, bool acked)
int err;
#if LINUX_VERSION_IS_GEQ(3,3,0)
+#if LINUX_VERSION_IS_GEQ(3,3,0)
skb->wifi_acked_valid = 1;
skb->wifi_acked = acked;
#endif
+#endif
serr = SKB_EXT_ERR(skb);
memset(serr, 0, sizeof(*serr));
diff --git a/compat/compat-3.5.c b/compat/compat-3.5.c
index de31228..8146803 100644
--- a/compat/compat-3.5.c
+++ b/compat/compat-3.5.c
@@ -67,6 +67,8 @@ EXPORT_SYMBOL_GPL(overflowuid);
EXPORT_SYMBOL_GPL(overflowgid);
#endif
+#if 0
+/* backported to all of our kernels */
#if IS_ENABLED(CONFIG_PTP_1588_CLOCK)
int ptp_clock_index(struct ptp_clock *ptp)
{
@@ -74,6 +76,7 @@ int ptp_clock_index(struct ptp_clock *ptp)
}
EXPORT_SYMBOL(ptp_clock_index);
#endif /* CONFIG_PTP_1588_CLOCK */
+#endif
#ifdef CONFIG_GPIOLIB
static void devm_gpio_release(struct device *dev, void *res)
diff --git a/compat/compat-3.6.c b/compat/compat-3.6.c
index ef36485..9e593f5 100644
--- a/compat/compat-3.6.c
+++ b/compat/compat-3.6.c
@@ -14,6 +14,7 @@
/* whoopsie ! */
#ifndef CONFIG_COMMON_CLK
+#ifndef CONFIG_ARCH_TEGRA
int clk_enable(struct clk *clk)
{
return 0;
@@ -25,3 +26,4 @@ void clk_disable(struct clk *clk)
}
EXPORT_SYMBOL_GPL(clk_disable);
#endif
+#endif
diff --git a/compat/compat-3.8.c b/compat/compat-3.8.c
index ff9cd49..a457fdf 100644
--- a/compat/compat-3.8.c
+++ b/compat/compat-3.8.c
@@ -356,6 +356,8 @@ bool hid_ignore(struct hid_device *hdev)
}
EXPORT_SYMBOL_GPL(hid_ignore);
+#if 0
+/* backported to our kernel */
/**
* prandom_bytes - get the requested number of pseudo-random bytes
* @buf: where to copy the pseudo-random bytes to
@@ -386,6 +388,7 @@ void prandom_bytes(void *buf, int bytes)
}
}
EXPORT_SYMBOL_GPL(prandom_bytes);
+#endif
#ifdef CONFIG_OF
/**
diff --git a/compat/drivers-base-devcoredump.c b/compat/drivers-base-devcoredump.c
index 0c7b7d3..27be55a 100644
--- a/compat/drivers-base-devcoredump.c
+++ b/compat/drivers-base-devcoredump.c
@@ -184,7 +184,9 @@ static struct class devcd_class = {
#if LINUX_VERSION_IS_GEQ(3,11,0)
.dev_groups = devcd_dev_groups,
#endif
+#if LINUX_VERSION_IS_GEQ(4,10,0)
.class_groups = devcd_class_groups,
+#endif
};
static ssize_t devcd_readv(char *buffer, loff_t offset, size_t count,