/linux-6.12.1/drivers/power/supply/ |
D | power_supply_hwmon.c | 21 static int power_supply_hwmon_in_to_property(u32 attr) in power_supply_hwmon_in_to_property() argument 23 switch (attr) { in power_supply_hwmon_in_to_property() 37 static int power_supply_hwmon_curr_to_property(u32 attr) in power_supply_hwmon_curr_to_property() argument 39 switch (attr) { in power_supply_hwmon_curr_to_property() 51 static int power_supply_hwmon_power_to_property(u32 attr) in power_supply_hwmon_power_to_property() argument 53 switch (attr) { in power_supply_hwmon_power_to_property() 63 static int power_supply_hwmon_temp_to_property(u32 attr, int channel) in power_supply_hwmon_temp_to_property() argument 66 switch (attr) { in power_supply_hwmon_temp_to_property() 77 switch (attr) { in power_supply_hwmon_temp_to_property() 97 power_supply_hwmon_to_property(enum hwmon_sensor_types type, in power_supply_hwmon_to_property() argument [all …]
|
/linux-6.12.1/drivers/vfio/mdev/ |
D | mdev_sysfs.c | 18 struct attribute attr; member 20 struct mdev_type_attribute *attr, char *buf); 22 struct mdev_type_attribute *attr, const char *buf, 34 struct mdev_type_attribute *attr = to_mdev_type_attr(__attr); in mdev_type_attr_show() local 35 struct mdev_type *type = to_mdev_type(kobj); in mdev_type_attr_show() local 38 if (attr->show) in mdev_type_attr_show() 39 ret = attr->show(type, attr, buf); in mdev_type_attr_show() 47 struct mdev_type_attribute *attr = to_mdev_type_attr(__attr); in mdev_type_attr_store() local 48 struct mdev_type *type = to_mdev_type(kobj); in mdev_type_attr_store() local 51 if (attr->store) in mdev_type_attr_store() [all …]
|
/linux-6.12.1/drivers/infiniband/sw/rxe/ |
D | rxe_av.c | 10 void rxe_init_av(struct rdma_ah_attr *attr, struct rxe_av *av) in rxe_init_av() argument 12 rxe_av_from_attr(rdma_ah_get_port_num(attr), av, attr); in rxe_init_av() 13 rxe_av_fill_ip_info(av, attr); in rxe_init_av() 14 memcpy(av->dmac, attr->roce.dmac, ETH_ALEN); in rxe_init_av() 17 static int chk_attr(void *obj, struct rdma_ah_attr *attr, bool obj_is_ah) in chk_attr() argument 19 const struct ib_global_route *grh = rdma_ah_read_grh(attr); in chk_attr() 24 int type; in chk_attr() local 36 if (rdma_ah_get_ah_flags(attr) & IB_AH_GRH) { in chk_attr() 37 if (grh->sgid_index > port->attr.gid_tbl_len) { in chk_attr() 47 type = rdma_gid_attr_network_type(grh->sgid_attr); in chk_attr() [all …]
|
/linux-6.12.1/drivers/scsi/ |
D | iscsi_boot_sysfs.c | 24 struct attribute attr; member 25 int type; member 26 ssize_t (*show) (void *data, int type, char *buf); 33 struct attribute *attr, char *buf) in iscsi_boot_show_attribute() argument 38 container_of(attr, struct iscsi_boot_attr, attr); in iscsi_boot_show_attribute() 46 ret = boot_kobj->show(boot_kobj->data, boot_attr->type, str); in iscsi_boot_show_attribute() 71 .attr = { .name = __stringify(sysfs_name), .mode = 0444 }, \ 72 .type = attr_type, \ 81 iscsi_boot_rd_attr(tgt_chap, chap-type, ISCSI_BOOT_TGT_CHAP_TYPE); 92 &iscsi_boot_attr_tgt_index.attr, [all …]
|
/linux-6.12.1/drivers/accel/habanalabs/common/ |
D | hwmon.c | 17 static u32 fixup_flags_legacy_fw(struct hl_device *hdev, enum hwmon_sensor_types type, in fixup_flags_legacy_fw() argument 22 switch (type) { in fixup_flags_legacy_fw() 49 dev_err_ratelimited(hdev->dev, "unsupported h/w sensor type %d\n", type); in fixup_flags_legacy_fw() 57 static u32 fixup_attr_legacy_fw(u32 attr) in fixup_attr_legacy_fw() argument 59 return (attr - 1); in fixup_attr_legacy_fw() 64 static u32 fixup_flags_legacy_fw(struct hl_device *hdev, enum hwmon_sensor_types type, in fixup_flags_legacy_fw() argument 70 static u32 fixup_attr_legacy_fw(u32 attr) in fixup_attr_legacy_fw() argument 72 return attr; in fixup_attr_legacy_fw() 77 static u32 adjust_hwmon_flags(struct hl_device *hdev, enum hwmon_sensor_types type, u32 cpucp_flags) in adjust_hwmon_flags() argument 90 switch (type) { in adjust_hwmon_flags() [all …]
|
/linux-6.12.1/tools/lib/thermal/ |
D | commands.c | 14 [THERMAL_GENL_ATTR_TZ] = { .type = NLA_NESTED }, 15 [THERMAL_GENL_ATTR_TZ_ID] = { .type = NLA_U32 }, 16 [THERMAL_GENL_ATTR_TZ_TEMP] = { .type = NLA_U32 }, 17 [THERMAL_GENL_ATTR_TZ_TRIP] = { .type = NLA_NESTED }, 18 [THERMAL_GENL_ATTR_TZ_TRIP_ID] = { .type = NLA_U32 }, 19 [THERMAL_GENL_ATTR_TZ_TRIP_TEMP] = { .type = NLA_U32 }, 20 [THERMAL_GENL_ATTR_TZ_TRIP_TYPE] = { .type = NLA_U32 }, 21 [THERMAL_GENL_ATTR_TZ_TRIP_HYST] = { .type = NLA_U32 }, 22 [THERMAL_GENL_ATTR_TZ_MODE] = { .type = NLA_U32 }, 23 [THERMAL_GENL_ATTR_TZ_CDEV_WEIGHT] = { .type = NLA_U32 }, [all …]
|
/linux-6.12.1/tools/perf/arch/x86/tests/ |
D | hybrid.c | 12 return (evsel->core.attr.config & PERF_HW_EVENT_MASK) == expected_config; in test_config() 17 return (evsel->attr.config & PERF_HW_EVENT_MASK) == expected_config; in test_perf_config() 22 return (evsel->core.attr.config >> PERF_PMU_TYPE_SHIFT) == expected_config; in test_hybrid_type() 30 TEST_ASSERT_VAL("wrong type", PERF_TYPE_HARDWARE == evsel->core.attr.type); in test__hybrid_hw_event_with_pmu() 42 TEST_ASSERT_VAL("wrong type", PERF_TYPE_HARDWARE == evsel->core.attr.type); in test__hybrid_hw_group_event() 48 TEST_ASSERT_VAL("wrong type", PERF_TYPE_HARDWARE == evsel->core.attr.type); in test__hybrid_hw_group_event() 61 TEST_ASSERT_VAL("wrong type", PERF_TYPE_SOFTWARE == evsel->core.attr.type); in test__hybrid_sw_hw_group_event() 65 TEST_ASSERT_VAL("wrong type", PERF_TYPE_HARDWARE == evsel->core.attr.type); in test__hybrid_sw_hw_group_event() 78 TEST_ASSERT_VAL("wrong type", PERF_TYPE_HARDWARE == evsel->core.attr.type); in test__hybrid_hw_sw_group_event() 84 TEST_ASSERT_VAL("wrong type", PERF_TYPE_SOFTWARE == evsel->core.attr.type); in test__hybrid_hw_sw_group_event() [all …]
|
D | amd-ibs-via-core-pmu.c | 13 int type; member 24 static int event_open(int type, unsigned long config) in event_open() argument 26 struct perf_event_attr attr; in event_open() local 28 memset(&attr, 0, sizeof(struct perf_event_attr)); in event_open() 29 attr.type = type; in event_open() 30 attr.size = sizeof(struct perf_event_attr); in event_open() 31 attr.config = config; in event_open() 32 attr.disabled = 1; in event_open() 33 attr.precise_ip = 1; in event_open() 34 attr.sample_type = PERF_SAMPLE_IP | PERF_SAMPLE_TID; in event_open() [all …]
|
/linux-6.12.1/net/802/ |
D | garp.c | 138 static int garp_attr_cmp(const struct garp_attr *attr, in garp_attr_cmp() argument 139 const void *data, u8 len, u8 type) in garp_attr_cmp() argument 141 if (attr->type != type) in garp_attr_cmp() 142 return attr->type - type; in garp_attr_cmp() 143 if (attr->dlen != len) in garp_attr_cmp() 144 return attr->dlen - len; in garp_attr_cmp() 145 return memcmp(attr->data, data, len); in garp_attr_cmp() 149 const void *data, u8 len, u8 type) in garp_attr_lookup() argument 152 struct garp_attr *attr; in garp_attr_lookup() local 156 attr = rb_entry(parent, struct garp_attr, node); in garp_attr_lookup() [all …]
|
D | mrp.c | 227 static int mrp_attr_cmp(const struct mrp_attr *attr, in mrp_attr_cmp() argument 228 const void *value, u8 len, u8 type) in mrp_attr_cmp() argument 230 if (attr->type != type) in mrp_attr_cmp() 231 return attr->type - type; in mrp_attr_cmp() 232 if (attr->len != len) in mrp_attr_cmp() 233 return attr->len - len; in mrp_attr_cmp() 234 return memcmp(attr->value, value, len); in mrp_attr_cmp() 238 const void *value, u8 len, u8 type) in mrp_attr_lookup() argument 241 struct mrp_attr *attr; in mrp_attr_lookup() local 245 attr = rb_entry(parent, struct mrp_attr, node); in mrp_attr_lookup() [all …]
|
/linux-6.12.1/drivers/net/ethernet/meta/fbnic/ |
D | fbnic_tlv.c | 32 hdr.type = msg_id; in fbnic_tlv_msg_alloc() 57 struct fbnic_tlv_msg *attr; in fbnic_tlv_attr_put_flag() local 60 if (attr_max_len < sizeof(*attr)) in fbnic_tlv_attr_put_flag() 64 attr = &msg[le16_to_cpu(msg->hdr.len)]; in fbnic_tlv_attr_put_flag() 67 hdr.type = attr_id; in fbnic_tlv_attr_put_flag() 70 attr->hdr = hdr; in fbnic_tlv_attr_put_flag() 99 struct fbnic_tlv_msg *attr; in fbnic_tlv_attr_put_value() local 102 if (attr_max_len < sizeof(*attr) + len) in fbnic_tlv_attr_put_value() 106 attr = &msg[le16_to_cpu(msg->hdr.len)]; in fbnic_tlv_attr_put_value() 109 hdr.type = attr_id; in fbnic_tlv_attr_put_value() [all …]
|
/linux-6.12.1/kernel/events/ |
D | hw_breakpoint.c | 62 static struct bp_cpuinfo *get_bp_info(int cpu, enum bp_type_idx type) in get_bp_info() argument 64 return per_cpu_ptr(bp_cpuinfo + type, cpu); in get_bp_info() 172 static inline int hw_breakpoint_slots_cached(int type) { return hw_breakpoint_slots(type); } in hw_breakpoint_slots_cached() argument 180 static inline int hw_breakpoint_slots_cached(int type) in hw_breakpoint_slots_cached() argument 182 return __nr_bp_slots[type]; in hw_breakpoint_slots_cached() 186 bp_slots_histogram_alloc(struct bp_slots_histogram *hist, enum bp_type_idx type) in bp_slots_histogram_alloc() argument 188 hist->count = kcalloc(hw_breakpoint_slots_cached(type), sizeof(*hist->count), GFP_KERNEL); in bp_slots_histogram_alloc() 249 bp_slots_histogram_max(struct bp_slots_histogram *hist, enum bp_type_idx type) in bp_slots_histogram_max() argument 251 for (int i = hw_breakpoint_slots_cached(type) - 1; i >= 0; i--) { in bp_slots_histogram_max() 266 enum bp_type_idx type) in bp_slots_histogram_max_merge() argument [all …]
|
/linux-6.12.1/kernel/bpf/ |
D | net_namespace.c | 14 enum bpf_attach_type type; member 29 static void netns_bpf_attach_type_unneed(enum netns_bpf_attach_type type) in netns_bpf_attach_type_unneed() argument 31 switch (type) { in netns_bpf_attach_type_unneed() 42 static void netns_bpf_attach_type_need(enum netns_bpf_attach_type type) in netns_bpf_attach_type_need() argument 44 switch (type) { in netns_bpf_attach_type_need() 57 enum netns_bpf_attach_type type) in netns_bpf_run_array_detach() argument 61 run_array = rcu_replace_pointer(net->bpf.run_array[type], NULL, in netns_bpf_run_array_detach() 66 static int link_index(struct net *net, enum netns_bpf_attach_type type, in link_index() argument 72 list_for_each_entry(pos, &net->bpf.links[type], node) { in link_index() 80 static int link_count(struct net *net, enum netns_bpf_attach_type type) in link_count() argument [all …]
|
/linux-6.12.1/drivers/thermal/ |
D | thermal_hwmon.c | 25 char type[THERMAL_NAME_LENGTH]; member 33 struct device_attribute attr; member 50 temp_input_show(struct device *dev, struct device_attribute *attr, char *buf) in temp_input_show() argument 55 = container_of(attr, struct thermal_hwmon_attr, attr); in temp_input_show() 70 temp_crit_show(struct device *dev, struct device_attribute *attr, char *buf) in temp_crit_show() argument 73 = container_of(attr, struct thermal_hwmon_attr, attr); in temp_crit_show() 98 char type[THERMAL_NAME_LENGTH]; in thermal_hwmon_lookup_by_type() local 102 strcpy(type, tz->type); in thermal_hwmon_lookup_by_type() 103 strreplace(type, '-', '_'); in thermal_hwmon_lookup_by_type() 104 if (!strcmp(hwmon->type, type)) { in thermal_hwmon_lookup_by_type() [all …]
|
/linux-6.12.1/fs/ntfs3/ |
D | record.c | 14 static inline int compare_attr(const struct ATTRIB *left, enum ATTR_TYPE type, in compare_attr() argument 19 int diff = le32_to_cpu(left->type) - le32_to_cpu(type); in compare_attr() 38 struct ATTRIB *attr; in mi_new_attt_id() local 52 attr = NULL; in mi_new_attt_id() 55 attr = mi_enum_attr(mi, attr); in mi_new_attt_id() 56 if (!attr) { in mi_new_attt_id() 62 t16 = le16_to_cpu(attr->id); in mi_new_attt_id() 65 attr = NULL; in mi_new_attt_id() 198 struct ATTRIB *mi_enum_attr(struct mft_inode *mi, struct ATTRIB *attr) in mi_enum_attr() argument 206 if (!attr) { in mi_enum_attr() [all …]
|
D | frecord.c | 76 const struct ATTRIB *attr; in ni_std() local 78 attr = mi_find_attr(&ni->mi, NULL, ATTR_STD, NULL, 0, NULL); in ni_std() 79 return attr ? resident_data_ex(attr, sizeof(struct ATTR_STD_INFO)) : in ni_std() 90 const struct ATTRIB *attr; in ni_std5() local 92 attr = mi_find_attr(&ni->mi, NULL, ATTR_STD, NULL, 0, NULL); in ni_std5() 94 return attr ? resident_data_ex(attr, sizeof(struct ATTR_STD_INFO5)) : in ni_std5() 188 struct ATTRIB *ni_find_attr(struct ntfs_inode *ni, struct ATTRIB *attr, in ni_find_attr() argument 189 struct ATTR_LIST_ENTRY **le_o, enum ATTR_TYPE type, in ni_find_attr() argument 197 (!name_len && (type == ATTR_LIST || type == ATTR_STD))) { in ni_find_attr() 204 return mi_find_attr(&ni->mi, attr, type, name, name_len, NULL); in ni_find_attr() [all …]
|
/linux-6.12.1/drivers/perf/ |
D | arm-ccn.c | 132 u32 type; member 212 static void arm_ccn_pmu_config_set(u64 *config, u32 node_xp, u32 type, u32 port) in arm_ccn_pmu_config_set() argument 215 *config |= (node_xp << 0) | (type << 8) | (port << 24); in arm_ccn_pmu_config_set() 225 static CCN_FORMAT_ATTR(type, "config:8-15"); 236 &arm_ccn_pmu_format_attr_node.attr.attr, 237 &arm_ccn_pmu_format_attr_xp.attr.attr, 238 &arm_ccn_pmu_format_attr_type.attr.attr, 239 &arm_ccn_pmu_format_attr_event.attr.attr, 240 &arm_ccn_pmu_format_attr_port.attr.attr, 241 &arm_ccn_pmu_format_attr_bus.attr.attr, [all …]
|
/linux-6.12.1/drivers/net/ethernet/sfc/siena/ |
D | mcdi_mon.c | 105 unsigned int type, state, value; in efx_siena_mcdi_sensor_event() local 109 type = EFX_QWORD_FIELD(*ev, MCDI_EVENT_SENSOREVT_MONITOR); in efx_siena_mcdi_sensor_event() 115 if (type < ARRAY_SIZE(efx_mcdi_sensor_type)) { in efx_siena_mcdi_sensor_event() 116 name = efx_mcdi_sensor_type[type].label; in efx_siena_mcdi_sensor_event() 117 hwmon_type = efx_mcdi_sensor_type[type].hwmon_type; in efx_siena_mcdi_sensor_event() 130 type, name, state_txt, value, unit); in efx_siena_mcdi_sensor_event() 138 unsigned int type; member 187 struct device_attribute *attr, in efx_mcdi_mon_show_value() argument 191 container_of(attr, struct efx_mcdi_mon_attribute, dev_attr); in efx_mcdi_mon_show_value() 224 struct device_attribute *attr, in efx_mcdi_mon_show_limit() argument [all …]
|
/linux-6.12.1/drivers/net/ethernet/sfc/ |
D | mcdi_mon.c | 105 unsigned int type, state, value; in efx_mcdi_sensor_event() local 109 type = EFX_QWORD_FIELD(*ev, MCDI_EVENT_SENSOREVT_MONITOR); in efx_mcdi_sensor_event() 115 if (type < ARRAY_SIZE(efx_mcdi_sensor_type)) { in efx_mcdi_sensor_event() 116 name = efx_mcdi_sensor_type[type].label; in efx_mcdi_sensor_event() 117 hwmon_type = efx_mcdi_sensor_type[type].hwmon_type; in efx_mcdi_sensor_event() 130 type, name, state_txt, value, unit); in efx_mcdi_sensor_event() 138 unsigned int type; member 187 struct device_attribute *attr, in efx_mcdi_mon_show_value() argument 191 container_of(attr, struct efx_mcdi_mon_attribute, dev_attr); in efx_mcdi_mon_show_value() 224 struct device_attribute *attr, in efx_mcdi_mon_show_limit() argument [all …]
|
/linux-6.12.1/tools/net/ynl/lib/ |
D | ynl.py | 128 self.type = self._type & ~Netlink.NLA_TYPE_MASK 159 def as_c_array(self, type): argument 160 format = self.get_format(type) 172 attr = NlAttr(msg, offset) 173 offset += attr.full_len 174 self.attrs.append(attr) 215 if extack.type == Netlink.NLMSGERR_ATTR_MSG: 217 elif extack.type == Netlink.NLMSGERR_ATTR_MISS_TYPE: 219 elif extack.type == Netlink.NLMSGERR_ATTR_MISS_NEST: 221 elif extack.type == Netlink.NLMSGERR_ATTR_OFFS: [all …]
|
/linux-6.12.1/drivers/net/ethernet/netronome/nfp/ |
D | nfp_hwmon.c | 17 static int nfp_hwmon_sensor_id(enum hwmon_sensor_types type, int channel) in nfp_hwmon_sensor_id() argument 19 if (type == hwmon_temp) in nfp_hwmon_sensor_id() 21 if (type == hwmon_power) in nfp_hwmon_sensor_id() 27 nfp_hwmon_read(struct device *dev, enum hwmon_sensor_types type, u32 attr, in nfp_hwmon_read() argument 31 enum hwmon_sensor_types type; in nfp_hwmon_read() member 32 u32 attr; in nfp_hwmon_read() member 44 if (const_vals[i].type == type && const_vals[i].attr == attr) { in nfp_hwmon_read() 49 err = nfp_hwmon_sensor_id(type, channel); in nfp_hwmon_read() 57 if (type == hwmon_temp && attr == hwmon_temp_input) in nfp_hwmon_read() 59 if (type == hwmon_power && attr == hwmon_power_input) in nfp_hwmon_read() [all …]
|
/linux-6.12.1/net/batman-adv/ |
D | netlink.c | 93 [BATADV_ATTR_VERSION] = { .type = NLA_STRING }, 94 [BATADV_ATTR_ALGO_NAME] = { .type = NLA_STRING }, 95 [BATADV_ATTR_MESH_IFINDEX] = { .type = NLA_U32 }, 96 [BATADV_ATTR_MESH_IFNAME] = { .type = NLA_STRING }, 98 [BATADV_ATTR_HARD_IFINDEX] = { .type = NLA_U32 }, 99 [BATADV_ATTR_HARD_IFNAME] = { .type = NLA_STRING }, 102 [BATADV_ATTR_TPMETER_RESULT] = { .type = NLA_U8 }, 103 [BATADV_ATTR_TPMETER_TEST_TIME] = { .type = NLA_U32 }, 104 [BATADV_ATTR_TPMETER_BYTES] = { .type = NLA_U64 }, 105 [BATADV_ATTR_TPMETER_COOKIE] = { .type = NLA_U32 }, [all …]
|
/linux-6.12.1/arch/powerpc/platforms/powernv/ |
D | opal-dump.c | 24 uint32_t type; member 31 struct attribute attr; member 32 ssize_t (*show)(struct dump_obj *dump, struct dump_attribute *attr, 34 ssize_t (*store)(struct dump_obj *dump, struct dump_attribute *attr, 37 #define to_dump_attr(x) container_of(x, struct dump_attribute, attr) 40 struct dump_attribute *attr, in dump_id_show() argument 46 static const char* dump_type_to_string(uint32_t type) in dump_type_to_string() argument 48 switch (type) { in dump_type_to_string() 57 struct dump_attribute *attr, in dump_type_show() argument 61 return sprintf(buf, "0x%x %s\n", dump_obj->type, in dump_type_show() [all …]
|
/linux-6.12.1/drivers/usb/core/ |
D | endpoint.c | 29 struct attribute attr; member 34 container_of(_attr, struct ep_attribute, attr) 38 struct device_attribute *attr, \ 52 struct device_attribute *attr, char *buf) in wMaxPacketSize_show() argument 59 static ssize_t type_show(struct device *dev, struct device_attribute *attr, in type_show() argument 63 char *type = "unknown"; in type_show() local 67 type = "Control"; in type_show() 70 type = "Isoc"; in type_show() 73 type = "Bulk"; in type_show() 76 type = "Interrupt"; in type_show() [all …]
|
/linux-6.12.1/net/netfilter/ipset/ |
D | ip_set_core.c | 90 struct ip_set_type *type; in find_set_type() local 92 list_for_each_entry_rcu(type, &ip_set_type_list, list, in find_set_type() 94 if (STRNCMP(type->name, name) && in find_set_type() 95 (type->family == family || in find_set_type() 96 type->family == NFPROTO_UNSPEC) && in find_set_type() 97 revision >= type->revision_min && in find_set_type() 98 revision <= type->revision_max) in find_set_type() 99 return type; in find_set_type() 126 struct ip_set_type *type; in __find_set_type_get() local 141 list_for_each_entry_rcu(type, &ip_set_type_list, list) in __find_set_type_get() [all …]
|