Commit 4581de2b authored by Steven L. Roberts's avatar Steven L. Roberts Committed by Greg Kroah-Hartman

RDMA/hfi1: fix array termination by appending NULL to attr array


[ Upstream commit c4dd4b69 ]

This fixes a kernel panic when loading the hfi driver as a dynamic module.
Signed-off-by: default avatarSteven L Roberts <robers97@gmail.com>
Reviewed-by: default avatarLeon Romanovsky <leon@kernel.org>
Acked-by: default avatarDennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
Signed-off-by: default avatarSasha Levin <alexander.levin@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9d4aa135
...@@ -196,7 +196,8 @@ static const struct sysfs_ops port_cc_sysfs_ops = { ...@@ -196,7 +196,8 @@ static const struct sysfs_ops port_cc_sysfs_ops = {
}; };
static struct attribute *port_cc_default_attributes[] = { static struct attribute *port_cc_default_attributes[] = {
&cc_prescan_attr.attr &cc_prescan_attr.attr,
NULL
}; };
static struct kobj_type port_cc_ktype = { static struct kobj_type port_cc_ktype = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment