git.codelabs.ch
/
muen
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge tag 'uuid-for-4.13-2' of git://git.infradead.org/users/hch/uuid
[muen/linux.git]
/
drivers
/
thunderbolt
/
switch.c
diff --git
a/drivers/thunderbolt/switch.c
b/drivers/thunderbolt/switch.c
index c6f41b7d38b0d6e8332acf4245835f58ff8bf3cf..e9391bbd4036023c63d8b7ec90185f56f9523ade 100644
(file)
--- a/
drivers/thunderbolt/switch.c
+++ b/
drivers/thunderbolt/switch.c
@@
-281,9
+281,11
@@
static struct nvmem_device *register_nvmem(struct tb_switch *sw, int id,
if (active) {
config.name = "nvm_active";
config.reg_read = tb_switch_nvm_read;
if (active) {
config.name = "nvm_active";
config.reg_read = tb_switch_nvm_read;
+ config.read_only = true;
} else {
config.name = "nvm_non_active";
config.reg_write = tb_switch_nvm_write;
} else {
config.name = "nvm_non_active";
config.reg_write = tb_switch_nvm_write;
+ config.root_only = true;
}
config.id = id;
}
config.id = id;
@@
-292,7
+294,6
@@
static struct nvmem_device *register_nvmem(struct tb_switch *sw, int id,
config.size = size;
config.dev = &sw->dev;
config.owner = THIS_MODULE;
config.size = size;
config.dev = &sw->dev;
config.owner = THIS_MODULE;
- config.root_only = true;
config.priv = sw;
return nvmem_register(&config);
config.priv = sw;
return nvmem_register(&config);