/linux/drivers/net/dsa/mv88e6xxx/ |
H A D | leds.c | 99 unsigned long rules; member 105 /* The following is a lookup table to check what rules we can support on a 106 * certain LED given restrictions such as that some rules only work with fiber 123 .rules = BIT(TRIGGER_NETDEV_LINK), 130 .rules = BIT(TRIGGER_NETDEV_LINK_1000), 137 .rules = BIT(TRIGGER_NETDEV_LINK_100) | BIT(TRIGGER_NETDEV_LINK_1000), 144 .rules = BIT(TRIGGER_NETDEV_LINK_10) | BIT(TRIGGER_NETDEV_LINK_100), 151 .rules = BIT(TRIGGER_NETDEV_LINK_100), 159 .rules = BIT(TRIGGER_NETDEV_LINK_1000), 167 .rules = BIT(TRIGGER_NETDEV_LINK_1000), [all …]
|
/linux/drivers/net/phy/aquantia/ |
H A D | aquantia_leds.c | 35 unsigned long rules) in aqr_phy_led_hw_is_supported() argument 41 if (rules & ~supported_triggers) in aqr_phy_led_hw_is_supported() 48 unsigned long *rules) in aqr_phy_led_hw_control_get() argument 59 *rules = 0; in aqr_phy_led_hw_control_get() 61 *rules |= BIT(TRIGGER_NETDEV_LINK_100); in aqr_phy_led_hw_control_get() 64 *rules |= BIT(TRIGGER_NETDEV_LINK_1000); in aqr_phy_led_hw_control_get() 67 *rules |= BIT(TRIGGER_NETDEV_LINK_2500); in aqr_phy_led_hw_control_get() 70 *rules |= BIT(TRIGGER_NETDEV_LINK_5000); in aqr_phy_led_hw_control_get() 73 *rules |= BIT(TRIGGER_NETDEV_LINK_10000); in aqr_phy_led_hw_control_get() 76 *rules |= BIT(TRIGGER_NETDEV_RX); in aqr_phy_led_hw_control_get() [all …]
|
/linux/tools/perf/util/ |
H A D | strfilter.h | 23 * @rules: Filter rule, which is a combination of glob expressions. 24 * @err: Pointer which points an error detected on @rules 26 * Parse @rules and return new strfilter. Return NULL if an error detected. 30 struct strfilter *strfilter__new(const char *rules, const char **err); 35 * @rules: Filter rule to be appended at left of the root of 37 * @err: Pointer which points an error detected on @rules 39 * Parse @rules and join it to the @filter by using logical-or. 43 const char *rules, const char **err); 48 * @rules: Filter rule to be appended at left of the root of 50 * @err: Pointer which points an error detected on @rules [all …]
|
H A D | strfilter.c | 160 struct strfilter *strfilter__new(const char *rules, const char **err) in strfilter__new() argument 166 filter->root = strfilter_node__new(rules, &ep); in strfilter__new() 179 const char *rules, const char **err) in strfilter__append() argument 184 if (!filter || !rules) in strfilter__append() 187 right = strfilter_node__new(rules, &ep); in strfilter__append() 207 int strfilter__or(struct strfilter *filter, const char *rules, const char **err) in strfilter__or() argument 209 return strfilter__append(filter, true, rules, err); in strfilter__or() 212 int strfilter__and(struct strfilter *filter, const char *rules, in strfilter__and() argument 215 return strfilter__append(filter, false, rules, err); in strfilter__and() 238 /* Return true if STR matches the filter rules */
|
/linux/drivers/net/phy/mediatek/ |
H A D | mtk-phy-lib.c | 99 unsigned long rules, in mtk_phy_led_hw_is_supported() argument 106 if (rules & ~supported_triggers) in mtk_phy_led_hw_is_supported() 114 unsigned long *rules, u16 on_set, in mtk_phy_led_hw_ctrl_get() argument 156 if (!rules) in mtk_phy_led_hw_ctrl_get() 160 *rules |= BIT(TRIGGER_NETDEV_LINK); in mtk_phy_led_hw_ctrl_get() 163 *rules |= BIT(TRIGGER_NETDEV_LINK_10); in mtk_phy_led_hw_ctrl_get() 166 *rules |= BIT(TRIGGER_NETDEV_LINK_100); in mtk_phy_led_hw_ctrl_get() 169 *rules |= BIT(TRIGGER_NETDEV_LINK_1000); in mtk_phy_led_hw_ctrl_get() 172 *rules |= BIT(TRIGGER_NETDEV_LINK_2500); in mtk_phy_led_hw_ctrl_get() 175 *rules |= BIT(TRIGGER_NETDEV_FULL_DUPLEX); in mtk_phy_led_hw_ctrl_get() [all …]
|
/linux/security/apparmor/ |
H A D | capability.c | 72 struct aa_ruleset *rules = profile->label.rules[0]; in audit_caps() local 81 !cap_raised(rules->caps.audit, cap))) in audit_caps() 85 cap_raised(rules->caps.kill, cap)) { in audit_caps() 87 } else if (cap_raised(rules->caps.quiet, cap) && in audit_caps() 124 struct aa_ruleset *rules = profile->label.rules[0]; in profile_capable() local 128 state = RULE_MEDIATES(rules, ad->class); in profile_capable() 134 state = aa_dfa_next(rules->policy->dfa, state, cap >> 5); in profile_capable() 136 perms = *aa_lookup_perms(rules->policy, state); in profile_capable() 150 if (cap_raised(rules->caps.allow, cap) && in profile_capable() 151 !cap_raised(rules->caps.denied, cap)) in profile_capable() [all …]
|
H A D | af_unix.c | 205 struct aa_ruleset *rules = profile->label.rules[0]; in profile_create_perm() local 211 state = RULE_MEDIATES_v9NET(rules); in profile_create_perm() 213 state = aa_match_to_prot(rules->policy, state, AA_MAY_CREATE, in profile_create_perm() 217 return aa_do_perms(profile, rules->policy, state, AA_MAY_CREATE, in profile_create_perm() 229 struct aa_ruleset *rules = profile->label.rules[0]; in profile_sk_perm() local 237 state = RULE_MEDIATES_v9NET(rules); in profile_sk_perm() 244 state = match_to_sk(rules->policy, state, request, unix_sk(sk), in profile_sk_perm() 247 return aa_do_perms(profile, rules->policy, state, request, p, in profile_sk_perm() 257 struct aa_ruleset *rules = profile->label.rules[0]; in profile_bind_perm() local 266 state = RULE_MEDIATES_v9NET(rules); in profile_bind_perm() [all …]
|
H A D | resource.c | 92 struct aa_ruleset *rules = profile->label.rules[0]; in profile_setrlimit() local 95 if (rules->rlimits.mask & (1 << resource) && new_rlim->rlim_max > in profile_setrlimit() 96 rules->rlimits.limits[resource].rlim_max) in profile_setrlimit() 127 * profiles. AppArmor rules currently have the implicit assumption in aa_task_setrlimit() 167 struct aa_ruleset *rules = old->label.rules[0]; in __aa_transition_rlimits() local 168 if (rules->rlimits.mask) { in __aa_transition_rlimits() 173 if (rules->rlimits.mask & mask) { in __aa_transition_rlimits() 185 struct aa_ruleset *rules = new->label.rules[0]; in __aa_transition_rlimits() local 188 if (!rules->rlimits.mask) in __aa_transition_rlimits() 191 if (!(rules->rlimits.mask & mask)) in __aa_transition_rlimits() [all …]
|
H A D | policy_unpack.c | 566 static bool unpack_secmark(struct aa_ext *e, struct aa_ruleset *rules) in unpack_secmark() argument 576 rules->secmark = kcalloc(size, sizeof(struct aa_secmark), in unpack_secmark() 578 if (!rules->secmark) in unpack_secmark() 581 rules->secmark_count = size; in unpack_secmark() 584 if (!unpack_u8(e, &rules->secmark[i].audit, NULL)) in unpack_secmark() 586 if (!unpack_u8(e, &rules->secmark[i].deny, NULL)) in unpack_secmark() 588 if (!aa_unpack_strdup(e, &rules->secmark[i].label, NULL)) in unpack_secmark() 600 if (rules->secmark) { in unpack_secmark() 602 kfree_sensitive(rules->secmark[i].label); in unpack_secmark() 603 kfree_sensitive(rules->secmark); in unpack_secmark() [all …]
|
H A D | net.c | 254 struct aa_ruleset *rules = profile->label.rules[0]; in aa_profile_af_perm() local 264 state = RULE_MEDIATES_NET(rules); in aa_profile_af_perm() 267 state = aa_match_to_prot(rules->policy, state, request, family, type, in aa_profile_af_perm() 269 return aa_do_perms(profile, rules->policy, state, request, p, ad); in aa_profile_af_perm() 364 struct aa_ruleset *rules = profile->label.rules[0]; in aa_secmark_perm() local 366 if (rules->secmark_count == 0) in aa_secmark_perm() 369 for (i = 0; i < rules->secmark_count; i++) { in aa_secmark_perm() 370 if (!rules->secmark[i].secid) { in aa_secmark_perm() 371 ret = apparmor_secmark_init(&rules->secmark[i]); in aa_secmark_perm() 376 if (rules->secmark[i].secid == secid || in aa_secmark_perm() [all …]
|
H A D | mount.c | 314 struct aa_ruleset *rules = profile->label.rules[0]; in match_mnt_path_str() local 321 if (!RULE_MEDIATES(rules, AA_CLASS_MOUNT)) in match_mnt_path_str() 336 pos = do_match_mnt(rules->policy, in match_mnt_path_str() 337 rules->policy->start[AA_CLASS_MOUNT], in match_mnt_path_str() 373 struct aa_ruleset *rules = profile->label.rules[0]; in match_mnt() local 379 if (!RULE_MEDIATES(rules, AA_CLASS_MOUNT)) in match_mnt() 605 struct aa_ruleset *rules = profile->label.rules[0]; in profile_umount() local 614 if (!RULE_MEDIATES(rules, AA_CLASS_MOUNT)) in profile_umount() 622 state = aa_dfa_match(rules->policy->dfa, in profile_umount() 623 rules->policy->start[AA_CLASS_MOUNT], in profile_umount() [all …]
|
H A D | file.c | 174 * @rules: the aa_policydb to lookup perms for (NOT NULL) 182 struct aa_perms *aa_lookup_condperms(kuid_t subj_uid, struct aa_policydb *rules, in aa_lookup_condperms() argument 185 unsigned int index = ACCEPT_TABLE(rules->dfa)[state]; in aa_lookup_condperms() 187 if (!(rules->perms)) in aa_lookup_condperms() 190 if ((ACCEPT_TABLE2(rules->dfa)[state] & ACCEPT_FLAG_OWNER)) { in aa_lookup_condperms() 192 return &(rules->perms[index]); in aa_lookup_condperms() 193 return &(rules->perms[index + 1]); in aa_lookup_condperms() 196 return &(rules->perms[index]); in aa_lookup_condperms() 226 struct aa_ruleset *rules = profile->label.rules[0]; in __aa_path_perm() local 230 ((flags & PATH_SOCK_COND) && !RULE_MEDIATES_v9NET(rules))) in __aa_path_perm() [all …]
|
/linux/net/netfilter/ |
H A D | nft_set_pipapo.c | 56 * represented as one or more rules, depending on the number of composing 61 * Rules are mapped between fields through an array of x, n pairs, with each 62 * item mapping a matched rule to one or more rules. The position of the pair in 65 * next-field rules the current rule maps to. 108 * or multiple rules for ranges. Ranges are expanded to composing netmasks 116 * - insert references to the rules in the lookup table, selecting buckets 144 * rules from the lookup table to rules belonging to the same entry in 147 * Note that as rules map to contiguous ranges of rules, give 362 pipapo_refill(unsigned long * map,unsigned int len,unsigned int rules,unsigned long * dst,const union nft_pipapo_map_bucket * mt,bool match_only) pipapo_refill() argument 584 pipapo_realloc_mt(struct nft_pipapo_field * f,unsigned int old_rules,unsigned int rules) pipapo_realloc_mt() argument 674 pipapo_resize(struct nft_pipapo_field * f,unsigned int old_rules,unsigned int rules) pipapo_resize() argument 1570 pipapo_unmap(union nft_pipapo_map_bucket * mt,unsigned int rules,unsigned int start,unsigned int n,unsigned int to_offset,bool is_last) global() argument [all...] |
H A D | nft_set_pipapo.h | 52 /* Each n-bit range maps to up to n * 2 rules */ 86 * @n: Number of rules (in next field) this rule maps to 107 * @rules: Number of inserted rules 109 * @rules_alloc: Number of allocated rules, always >= rules 116 unsigned int rules; member 179 int pipapo_refill(unsigned long *map, unsigned int len, unsigned int rules, 236 * of rules (composing netmasks) the entries expand to. We compute the worst 253 unsigned long rules; in pipapo_estimate_size() local [all...] |
/linux/security/apparmor/include/ |
H A D | policy.h | 74 APPARMOR_ENFORCE, /* enforce access rules */ 157 /* struct aa_ruleset - data covering mediation rules 160 * @policy: general match rules governing policy 161 * @file: The set of rules governing basic file access and domain transitions 182 /* struct aa_attachment - data and rules for a profiles attachment 209 * @attach: attachment rules for the profile 210 * @rules: rules to be enforced 220 * @rules - label with the rule vec on its end 225 * attachments are determined by profile X transition rules. 304 static inline aa_state_t RULE_MEDIATES(struct aa_ruleset *rules, in RULE_MEDIATES() argument [all …]
|
/linux/drivers/net/phy/qcom/ |
H A D | qca808x.c | 424 static int qca808x_led_parse_netdev(struct phy_device *phydev, unsigned long rules, in qca808x_led_parse_netdev() argument 428 if (test_bit(TRIGGER_NETDEV_TX, &rules)) in qca808x_led_parse_netdev() 430 if (test_bit(TRIGGER_NETDEV_RX, &rules)) in qca808x_led_parse_netdev() 432 if (test_bit(TRIGGER_NETDEV_LINK_10, &rules)) in qca808x_led_parse_netdev() 434 if (test_bit(TRIGGER_NETDEV_LINK_100, &rules)) in qca808x_led_parse_netdev() 436 if (test_bit(TRIGGER_NETDEV_LINK_1000, &rules)) in qca808x_led_parse_netdev() 438 if (test_bit(TRIGGER_NETDEV_LINK_2500, &rules)) in qca808x_led_parse_netdev() 440 if (test_bit(TRIGGER_NETDEV_HALF_DUPLEX, &rules)) in qca808x_led_parse_netdev() 442 if (test_bit(TRIGGER_NETDEV_FULL_DUPLEX, &rules)) in qca808x_led_parse_netdev() 445 if (rules && !*offload_trigger) in qca808x_led_parse_netdev() [all …]
|
/linux/Documentation/admin-guide/aoe/ |
H A D | udev-install.sh | 1 # install the aoe-specific udev rules from udev.txt into 22 # find the directory where udev rules are stored, often 23 # /etc/udev/rules.d 27 rules_d=/etc/udev/rules.d 30 echo "$me Error: cannot find udev rules directory" 1>&2 33 sh -xc "cp `dirname $0`/udev.txt $rules_d/60-aoe.rules"
|
/linux/kernel/kcsan/ |
H A D | permissive.h | 3 * Special rules for ignoring entire classes of data-racy memory accesses. None 4 * of the rules here imply that such data races are generally safe! 6 * All rules in this file can be configured via CONFIG_KCSAN_PERMISSIVE. Keep 20 * Access ignore rules based on address. 35 * Data race ignore rules based on access type and value change patterns. 44 * Rules here are only for plain read accesses, so that we still report in kcsan_ignore_data_race() 70 * The rules here will ignore the data races if we observe no more than in kcsan_ignore_data_race()
|
/linux/drivers/net/phy/ |
H A D | intel-xway.c | 402 unsigned long rules) in xway_gphy_led_hw_is_supported() argument 410 if (rules & (BIT(TRIGGER_NETDEV_RX) | BIT(TRIGGER_NETDEV_TX)) && in xway_gphy_led_hw_is_supported() 411 !(rules & (BIT(TRIGGER_NETDEV_LINK) | in xway_gphy_led_hw_is_supported() 418 if (rules & ~supported_triggers) in xway_gphy_led_hw_is_supported() 425 unsigned long *rules) in xway_gphy_led_hw_control_get() argument 441 *rules |= BIT(TRIGGER_NETDEV_LINK_10); in xway_gphy_led_hw_control_get() 444 *rules |= BIT(TRIGGER_NETDEV_LINK_100); in xway_gphy_led_hw_control_get() 447 *rules |= BIT(TRIGGER_NETDEV_LINK_1000); in xway_gphy_led_hw_control_get() 452 *rules |= BIT(TRIGGER_NETDEV_LINK); in xway_gphy_led_hw_control_get() 455 *rules |= BIT(TRIGGER_NETDEV_TX); in xway_gphy_led_hw_control_get() [all …]
|
H A D | air_en8811h.c | 148 unsigned long rules; member 558 changed |= (priv->led[index].rules != 0); in air_hw_led_on_set() 560 /* clear netdev trigger rules in case LED_OFF has been set */ in air_hw_led_on_set() 562 priv->led[index].rules = 0; in air_hw_led_on_set() 589 changed |= (priv->led[index].rules != 0); in air_hw_led_blink_set() 628 priv->led[index].rules = 0; in air_led_blink_set() 653 priv->led[index].rules = 0; in air_led_brightness_set() 659 unsigned long *rules) in air_led_hw_control_get() argument 666 *rules = priv->led[index].rules; in air_led_hw_control_get() 672 unsigned long rules) in air_led_hw_control_set() argument [all …]
|
/linux/drivers/net/ethernet/microchip/vcap/ |
H A D | Kconfig | 13 A VCAP is essentially a TCAM with rules consisting of 24 The VCAP implementation provides switchcore independent handling of rules 27 - Creating and deleting rules 28 - Updating and getting rules 32 access rules via the API in a platform independent way, with the
|
/linux/security/smack/ |
H A D | Kconfig | 17 bool "Reporting on access granted by Smack rules" 21 Enable the bring-up ("b") access mode in Smack rules. 26 rules. The developer can use the information to 27 identify which rules are necessary and what accesses 54 delivering a signal in the Smack rules.
|
/linux/tools/testing/selftests/net/netfilter/ |
H A D | xt_string.sh | 70 echo "FAIL: rules match data before --from" 79 echo "FAIL: only two rules should match at low offset" 87 echo "FAIL: all rules should match at end of packet" 103 echo "FAIL: two rules should match pattern at start of second fragment" 111 echo "FAIL: two rules should match pattern at end of largest --to" 119 echo "FAIL: no rules should match pattern extending largest --to"
|
/linux/tools/perf/tests/shell/lib/ |
H A D | perf_metric_validation.py | 42 self.rules = None 404 # Create metric set for relationship rules 405 for rule in self.rules: 460 def remove_unsupported_rules(self, rules): argument 462 for rule in rules: 474 Create full rules which includes: 475 1) All the rules from the "relationshi_rules" file 478 Reindex all the rules to avoid repeated RuleIndex 481 rules = data['RelationshipRules'] 483 self.rules = self.remove_unsupported_rules(rules) [all …]
|
/linux/Documentation/admin-guide/LSM/ |
H A D | Smack.rst | 50 load the Smack access rules 154 This interface allows modification of existing access control rules. 217 This interface allows access control rules in addition to 218 the system defined rules to be specified. The format accepted 232 This interface allows access control rules in addition to 233 the system defined rules to be specified. The format accepted 248 This interface allows process specific access rules to be 249 defined. These rules are only consulted if access would 255 This interface allows process specific access rules to be 256 defined. These rules are only consulted if access would [all …]
|