summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Gortmaker <paul.gortmaker@windriver.com>2019-08-15 12:35:57 -0400
committerPaul Gortmaker <paul.gortmaker@windriver.com>2019-08-15 12:35:57 -0400
commit93faf4b1c8d8dd37cd85bd1e4365637d0be15eb2 (patch)
tree630a935592778e8b8fc54c55ba5d9b2462a5b68c
parent80958c28d85f0ee5981d4a4a15cc7f4927ef5da8 (diff)
downloadlongterm-queue-4.18-93faf4b1c8d8dd37cd85bd1e4365637d0be15eb2.tar.gz
thunderbolt: header ctxt refresh
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-rw-r--r--queue/thunderbolt-Take-domain-lock-in-switch-sysfs-attribu.patch38
1 files changed, 19 insertions, 19 deletions
diff --git a/queue/thunderbolt-Take-domain-lock-in-switch-sysfs-attribu.patch b/queue/thunderbolt-Take-domain-lock-in-switch-sysfs-attribu.patch
index 798e384..78ef069 100644
--- a/queue/thunderbolt-Take-domain-lock-in-switch-sysfs-attribu.patch
+++ b/queue/thunderbolt-Take-domain-lock-in-switch-sysfs-attribu.patch
@@ -1,4 +1,4 @@
-From 09f11b6c99feaf86a26444bca85dc693b3f58f8b Mon Sep 17 00:00:00 2001
+From 523dbbd1f8441c1aea34817bfa6fd343fe09f295 Mon Sep 17 00:00:00 2001
From: Mika Westerberg <mika.westerberg@linux.intel.com>
Date: Tue, 19 Mar 2019 16:48:41 +0200
Subject: [PATCH] thunderbolt: Take domain lock in switch sysfs attribute
@@ -60,13 +60,13 @@ attribute is removed.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
diff --git a/drivers/thunderbolt/switch.c b/drivers/thunderbolt/switch.c
-index 5c2c0201ae7f..7fa4ab076404 100644
+index 25758671ddf4..a63da422638d 100644
--- a/drivers/thunderbolt/switch.c
+++ b/drivers/thunderbolt/switch.c
-@@ -10,15 +10,13 @@
+@@ -8,15 +8,13 @@
+ #include <linux/delay.h>
#include <linux/idr.h>
#include <linux/nvmem-provider.h>
- #include <linux/pm_runtime.h>
+#include <linux/sched/signal.h>
#include <linux/sizes.h>
#include <linux/slab.h>
@@ -80,7 +80,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
/* Switch NVM support */
#define NVM_DEVID 0x05
-@@ -254,8 +252,8 @@ static int tb_switch_nvm_write(void *priv, unsigned int offset, void *val,
+@@ -246,8 +244,8 @@ static int tb_switch_nvm_write(void *priv, unsigned int offset, void *val,
struct tb_switch *sw = priv;
int ret = 0;
@@ -91,7 +91,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
/*
* Since writing the NVM image might require some special steps,
-@@ -275,7 +273,7 @@ static int tb_switch_nvm_write(void *priv, unsigned int offset, void *val,
+@@ -267,7 +265,7 @@ static int tb_switch_nvm_write(void *priv, unsigned int offset, void *val,
memcpy(sw->nvm->buf + offset, val, bytes);
unlock:
@@ -100,7 +100,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return ret;
}
-@@ -364,10 +362,7 @@ static int tb_switch_nvm_add(struct tb_switch *sw)
+@@ -356,10 +354,7 @@ static int tb_switch_nvm_add(struct tb_switch *sw)
}
nvm->non_active = nvm_dev;
@@ -111,7 +111,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return 0;
err_nvm_active:
-@@ -384,10 +379,8 @@ static void tb_switch_nvm_remove(struct tb_switch *sw)
+@@ -376,10 +371,8 @@ static void tb_switch_nvm_remove(struct tb_switch *sw)
{
struct tb_switch_nvm *nvm;
@@ -122,7 +122,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
if (!nvm)
return;
-@@ -698,8 +691,8 @@ static int tb_switch_set_authorized(struct tb_switch *sw, unsigned int val)
+@@ -710,8 +703,8 @@ static int tb_switch_set_authorized(struct tb_switch *sw, unsigned int val)
{
int ret = -EINVAL;
@@ -133,7 +133,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
if (sw->authorized)
goto unlock;
-@@ -742,7 +735,7 @@ static int tb_switch_set_authorized(struct tb_switch *sw, unsigned int val)
+@@ -751,7 +744,7 @@ static int tb_switch_set_authorized(struct tb_switch *sw, unsigned int val)
}
unlock:
@@ -142,7 +142,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return ret;
}
-@@ -799,15 +792,15 @@ static ssize_t key_show(struct device *dev, struct device_attribute *attr,
+@@ -808,15 +801,15 @@ static ssize_t key_show(struct device *dev, struct device_attribute *attr,
struct tb_switch *sw = tb_to_switch(dev);
ssize_t ret;
@@ -161,7 +161,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return ret;
}
-@@ -824,8 +817,8 @@ static ssize_t key_store(struct device *dev, struct device_attribute *attr,
+@@ -833,8 +826,8 @@ static ssize_t key_store(struct device *dev, struct device_attribute *attr,
else if (hex2bin(key, buf, sizeof(key)))
return -EINVAL;
@@ -172,7 +172,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
if (sw->authorized) {
ret = -EBUSY;
-@@ -840,7 +833,7 @@ static ssize_t key_store(struct device *dev, struct device_attribute *attr,
+@@ -849,7 +842,7 @@ static ssize_t key_store(struct device *dev, struct device_attribute *attr,
}
}
@@ -181,7 +181,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return ret;
}
static DEVICE_ATTR(key, 0600, key_show, key_store);
-@@ -886,8 +879,8 @@ static ssize_t nvm_authenticate_store(struct device *dev,
+@@ -871,8 +864,8 @@ static ssize_t nvm_authenticate_store(struct device *dev,
bool val;
int ret;
@@ -192,7 +192,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
/* If NVMem devices are not yet added */
if (!sw->nvm) {
-@@ -935,7 +928,7 @@ static ssize_t nvm_authenticate_store(struct device *dev,
+@@ -901,7 +894,7 @@ static ssize_t nvm_authenticate_store(struct device *dev,
}
exit_unlock:
@@ -201,7 +201,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
if (ret)
return ret;
-@@ -949,8 +942,8 @@ static ssize_t nvm_version_show(struct device *dev,
+@@ -915,8 +908,8 @@ static ssize_t nvm_version_show(struct device *dev,
struct tb_switch *sw = tb_to_switch(dev);
int ret;
@@ -212,7 +212,7 @@ index 5c2c0201ae7f..7fa4ab076404 100644
if (sw->safe_mode)
ret = -ENODATA;
-@@ -959,7 +952,7 @@ static ssize_t nvm_version_show(struct device *dev,
+@@ -925,7 +918,7 @@ static ssize_t nvm_version_show(struct device *dev,
else
ret = sprintf(buf, "%x.%x\n", sw->nvm->major, sw->nvm->minor);
@@ -222,10 +222,10 @@ index 5c2c0201ae7f..7fa4ab076404 100644
return ret;
}
diff --git a/drivers/thunderbolt/tb.h b/drivers/thunderbolt/tb.h
-index 496dcd03ede1..f7b0c43c29a7 100644
+index 9d9f0ca16bfb..1c8fa237996d 100644
--- a/drivers/thunderbolt/tb.h
+++ b/drivers/thunderbolt/tb.h
-@@ -79,8 +79,7 @@ struct tb_switch_nvm {
+@@ -78,8 +78,7 @@ struct tb_switch_nvm {
* @depth: Depth in the chain this switch is connected (ICM only)
*
* When the switch is being added or removed to the domain (other