File tree Expand file tree Collapse file tree 1 file changed +1
-14
lines changed Expand file tree Collapse file tree 1 file changed +1
-14
lines changed Original file line number Diff line number Diff line change @@ -1875,18 +1875,6 @@ static struct attribute *switch_attrs[] = {
1875
1875
NULL ,
1876
1876
};
1877
1877
1878
- static bool has_port (const struct tb_switch * sw , enum tb_port_type type )
1879
- {
1880
- const struct tb_port * port ;
1881
-
1882
- tb_switch_for_each_port (sw , port ) {
1883
- if (!port -> disabled && port -> config .type == type )
1884
- return true;
1885
- }
1886
-
1887
- return false;
1888
- }
1889
-
1890
1878
static umode_t switch_attr_is_visible (struct kobject * kobj ,
1891
1879
struct attribute * attr , int n )
1892
1880
{
@@ -1895,8 +1883,7 @@ static umode_t switch_attr_is_visible(struct kobject *kobj,
1895
1883
1896
1884
if (attr == & dev_attr_authorized .attr ) {
1897
1885
if (sw -> tb -> security_level == TB_SECURITY_NOPCIE ||
1898
- sw -> tb -> security_level == TB_SECURITY_DPONLY ||
1899
- !has_port (sw , TB_TYPE_PCIE_UP ))
1886
+ sw -> tb -> security_level == TB_SECURITY_DPONLY )
1900
1887
return 0 ;
1901
1888
} else if (attr == & dev_attr_device .attr ) {
1902
1889
if (!sw -> device )
You can’t perform that action at this time.
0 commit comments