Lines Matching full:lookup
281 /* Check if this is the first lookup of IS0 */
292 /* Check if this is the first lookup of IS2 */
360 /* Convert IS0 chain id to vcap lookup id */
363 int lookup = 0; in sparx5_vcap_is0_cid_to_lookup() local
366 lookup = 1; in sparx5_vcap_is0_cid_to_lookup()
368 lookup = 2; in sparx5_vcap_is0_cid_to_lookup()
370 lookup = 3; in sparx5_vcap_is0_cid_to_lookup()
372 lookup = 4; in sparx5_vcap_is0_cid_to_lookup()
374 lookup = 5; in sparx5_vcap_is0_cid_to_lookup()
376 return lookup; in sparx5_vcap_is0_cid_to_lookup()
379 /* Convert IS2 chain id to vcap lookup id */
382 int lookup = 0; in sparx5_vcap_is2_cid_to_lookup() local
385 lookup = 1; in sparx5_vcap_is2_cid_to_lookup()
387 lookup = 2; in sparx5_vcap_is2_cid_to_lookup()
389 lookup = 3; in sparx5_vcap_is2_cid_to_lookup()
391 return lookup; in sparx5_vcap_is2_cid_to_lookup()
394 /* Convert ES2 chain id to vcap lookup id */
397 int lookup = 0; in sparx5_vcap_es2_cid_to_lookup() local
400 lookup = 1; in sparx5_vcap_es2_cid_to_lookup()
402 return lookup; in sparx5_vcap_es2_cid_to_lookup()
422 int lookup, in sparx5_vcap_is0_get_port_keysets() argument
431 value = spx5_rd(sparx5, ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_get_port_keysets()
476 int lookup, in sparx5_vcap_is2_get_port_keysets() argument
485 value = spx5_rd(sparx5, ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_get_port_keysets()
630 int lookup, in sparx5_vcap_es2_get_port_keysets() argument
639 value = spx5_rd(sparx5, EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_es2_get_port_keysets()
691 /* Get the port keyset for the vcap lookup */
698 int lookup, err = -EINVAL; in sparx5_vcap_get_port_keyset() local
703 lookup = sparx5_vcap_is0_cid_to_lookup(cid); in sparx5_vcap_get_port_keyset()
704 err = sparx5_vcap_is0_get_port_keysets(ndev, lookup, kslist, in sparx5_vcap_get_port_keyset()
708 lookup = sparx5_vcap_is2_cid_to_lookup(cid); in sparx5_vcap_get_port_keyset()
709 err = sparx5_vcap_is2_get_port_keysets(ndev, lookup, kslist, in sparx5_vcap_get_port_keyset()
716 lookup = sparx5_vcap_es2_cid_to_lookup(cid); in sparx5_vcap_get_port_keyset()
717 err = sparx5_vcap_es2_get_port_keysets(ndev, lookup, kslist, in sparx5_vcap_get_port_keyset()
769 int idx, jdx, lookup; in sparx5_vcap_validate_keyset() local
780 lookup = sparx5_vcap_is0_cid_to_lookup(rule->vcap_chain_id); in sparx5_vcap_validate_keyset()
781 sparx5_vcap_is0_get_port_keysets(ndev, lookup, &keysetlist, in sparx5_vcap_validate_keyset()
785 lookup = sparx5_vcap_is2_cid_to_lookup(rule->vcap_chain_id); in sparx5_vcap_validate_keyset()
786 sparx5_vcap_is2_get_port_keysets(ndev, lookup, &keysetlist, in sparx5_vcap_validate_keyset()
793 lookup = sparx5_vcap_es2_cid_to_lookup(rule->vcap_chain_id); in sparx5_vcap_validate_keyset()
794 sparx5_vcap_es2_get_port_keysets(ndev, lookup, &keysetlist, in sparx5_vcap_validate_keyset()
839 /* Add key that selects the first/second lookup */ in sparx5_vcap_ingress_add_default_fields()
872 /* Add key that selects the first/second lookup */ in sparx5_vcap_es2_add_default_fields()
890 /* add the lookup bit */ in sparx5_vcap_add_default_fields()
1534 static void sparx5_vcap_is0_set_port_keyset(struct net_device *ndev, int lookup, in sparx5_vcap_is0_set_port_keyset() argument
1549 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_set_port_keyset()
1556 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_set_port_keyset()
1563 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_set_port_keyset()
1623 static void sparx5_vcap_is2_set_port_keyset(struct net_device *ndev, int lookup, in sparx5_vcap_is2_set_port_keyset() argument
1638 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1645 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1649 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1656 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1661 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1668 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_set_port_keyset()
1716 static void sparx5_vcap_es2_set_port_keyset(struct net_device *ndev, int lookup, in sparx5_vcap_es2_set_port_keyset() argument
1731 EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_es2_set_port_keyset()
1738 EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_es2_set_port_keyset()
1745 EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_es2_set_port_keyset()
1750 /* Change the port keyset for the lookup and protocol */
1759 int lookup; in sparx5_vcap_set_port_keyset() local
1763 lookup = sparx5_vcap_is0_cid_to_lookup(cid); in sparx5_vcap_set_port_keyset()
1765 sparx5_vcap_is0_get_port_keysets(ndev, lookup, orig, in sparx5_vcap_set_port_keyset()
1767 sparx5_vcap_is0_set_port_keyset(ndev, lookup, keyset, l3_proto); in sparx5_vcap_set_port_keyset()
1770 lookup = sparx5_vcap_is2_cid_to_lookup(cid); in sparx5_vcap_set_port_keyset()
1772 sparx5_vcap_is2_get_port_keysets(ndev, lookup, orig, in sparx5_vcap_set_port_keyset()
1774 sparx5_vcap_is2_set_port_keyset(ndev, lookup, keyset, l3_proto); in sparx5_vcap_set_port_keyset()
1779 lookup = sparx5_vcap_es2_cid_to_lookup(cid); in sparx5_vcap_set_port_keyset()
1781 sparx5_vcap_es2_get_port_keysets(ndev, lookup, orig, in sparx5_vcap_set_port_keyset()
1783 sparx5_vcap_es2_set_port_keyset(ndev, lookup, keyset, l3_proto); in sparx5_vcap_set_port_keyset()
1796 int portno, lookup; in sparx5_vcap_is0_port_key_selection() local
1806 for (lookup = 0; lookup < admin->lookups; ++lookup) { in sparx5_vcap_is0_port_key_selection()
1809 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_port_key_selection()
1813 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_is0_port_key_selection()
1822 int portno, lookup; in sparx5_vcap_is2_port_key_selection() local
1831 for (lookup = 0; lookup < admin->lookups; ++lookup) { in sparx5_vcap_is2_port_key_selection()
1834 ANA_ACL_VCAP_S2_KEY_SEL(portno, lookup)); in sparx5_vcap_is2_port_key_selection()
1865 int portno, lookup; in sparx5_vcap_es2_port_key_selection() local
1871 for (lookup = 0; lookup < admin->lookups; ++lookup) in sparx5_vcap_es2_port_key_selection()
1874 EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_es2_port_key_selection()
1904 int portno, lookup; in sparx5_vcap_port_key_deselection() local
1908 for (lookup = 0; lookup < admin->lookups; ++lookup) in sparx5_vcap_port_key_deselection()
1913 ANA_CL_ADV_CL_CFG(portno, lookup)); in sparx5_vcap_port_key_deselection()
1927 for (lookup = 0; lookup < admin->lookups; ++lookup) in sparx5_vcap_port_key_deselection()
1932 EACL_VCAP_ES2_KEY_SEL(portno, lookup)); in sparx5_vcap_port_key_deselection()