提交 d9fb5c09 编写于 作者: J Jeff Layton 提交者: Steve French

cifs: no need to use rcu_assign_pointer on immutable keys

cifs: no need to use rcu_assign_pointer on immutable keys

Neither keytype in use by CIFS has an "update" method. This means that
the keys are immutable once instantiated. We don't need to use RCU
to set the payload data pointers.
Signed-off-by: NJeff Layton <jlayton@redhat.com>
Signed-off-by: NSteve French <sfrench@us.ibm.com>
上级 5144ebf4
......@@ -41,7 +41,7 @@ cifs_spnego_key_instantiate(struct key *key, const void *data, size_t datalen)
/* attach the data */
memcpy(payload, data, datalen);
rcu_assign_pointer(key->payload.data, payload);
key->payload.data = payload;
ret = 0;
error:
......
......@@ -78,7 +78,7 @@ dns_resolver_instantiate(struct key *key, const void *data,
}
key->type_data.x[0] = datalen;
rcu_assign_pointer(key->payload.data, ip);
key->payload.data = ip;
return rc;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册