Home
last modified time | relevance | path

Searched refs:resource (Results 1 – 25 of 1055) sorted by relevance

12345678910>>...43

/drivers/hwmon/
Dacpi_power_meter.c130 static int update_avg_interval(struct acpi_power_meter_resource *resource) in update_avg_interval() argument
135 status = acpi_evaluate_integer(resource->acpi_dev->handle, "_GAI", in update_avg_interval()
142 resource->avg_interval = data; in update_avg_interval()
151 struct acpi_power_meter_resource *resource = acpi_dev->driver_data; in show_avg_interval() local
153 mutex_lock(&resource->lock); in show_avg_interval()
154 update_avg_interval(resource); in show_avg_interval()
155 mutex_unlock(&resource->lock); in show_avg_interval()
157 return sprintf(buf, "%llu\n", resource->avg_interval); in show_avg_interval()
165 struct acpi_power_meter_resource *resource = acpi_dev->driver_data; in set_avg_interval() local
177 if (temp > resource->caps.max_avg_interval || in set_avg_interval()
[all …]
/drivers/acpi/
Dpower.c117 struct acpi_power_resource **resource) in acpi_power_get_context() argument
123 if (!resource) in acpi_power_get_context()
132 *resource = acpi_driver_data(device); in acpi_power_get_context()
133 if (!*resource) in acpi_power_get_context()
177 struct acpi_power_resource *resource; in acpi_power_get_list_state() local
181 result = acpi_power_get_context(handle, &resource); in acpi_power_get_list_state()
185 mutex_lock(&resource->resource_lock); in acpi_power_get_list_state()
189 mutex_unlock(&resource->resource_lock); in acpi_power_get_list_state()
223 static int __acpi_power_on(struct acpi_power_resource *resource) in __acpi_power_on() argument
227 status = acpi_evaluate_object(resource->device->handle, "_ON", NULL, NULL); in __acpi_power_on()
[all …]
Dpci_link.c107 static acpi_status acpi_pci_link_check_possible(struct acpi_resource *resource, in acpi_pci_link_check_possible() argument
113 switch (resource->type) { in acpi_pci_link_check_possible()
119 struct acpi_resource_irq *p = &resource->data.irq; in acpi_pci_link_check_possible()
145 &resource->data.extended_irq; in acpi_pci_link_check_possible()
170 resource->type); in acpi_pci_link_check_possible()
195 static acpi_status acpi_pci_link_check_current(struct acpi_resource *resource, in acpi_pci_link_check_current() argument
200 switch (resource->type) { in acpi_pci_link_check_current()
206 struct acpi_resource_irq *p = &resource->data.irq; in acpi_pci_link_check_current()
222 &resource->data.extended_irq; in acpi_pci_link_check_current()
238 resource->type); in acpi_pci_link_check_current()
[all …]
/drivers/tty/ipwireless/
Dmain.c83 p_dev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in ipwireless_probe()
84 p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; in ipwireless_probe()
94 if (!request_region(p_dev->resource[0]->start, in ipwireless_probe()
95 resource_size(p_dev->resource[0]), in ipwireless_probe()
101 p_dev->resource[2]->flags |= in ipwireless_probe()
104 ret = pcmcia_request_window(p_dev, p_dev->resource[2], 0); in ipwireless_probe()
108 ret = pcmcia_map_mem_page(p_dev, p_dev->resource[2], p_dev->card_addr); in ipwireless_probe()
112 ipw->is_v2_card = resource_size(p_dev->resource[2]) == 0x100; in ipwireless_probe()
114 ipw->common_memory = ioremap(p_dev->resource[2]->start, in ipwireless_probe()
115 resource_size(p_dev->resource[2])); in ipwireless_probe()
[all …]
/drivers/acpi/acpica/
Drsmisc.c71 acpi_rs_convert_aml_to_resource(struct acpi_resource *resource, in acpi_rs_convert_aml_to_resource() argument
90 if (((acpi_size) resource) & 0x3) { in acpi_rs_convert_aml_to_resource()
96 resource, resource->type, resource->length)); in acpi_rs_convert_aml_to_resource()
115 ACPI_ADD_PTR(void, resource, info->resource_offset); in acpi_rs_convert_aml_to_resource()
122 ACPI_MEMSET(resource, 0, INIT_RESOURCE_LENGTH(info)); in acpi_rs_convert_aml_to_resource()
123 resource->type = INIT_RESOURCE_TYPE(info); in acpi_rs_convert_aml_to_resource()
124 resource->length = INIT_RESOURCE_LENGTH(info); in acpi_rs_convert_aml_to_resource()
164 resource->length = resource->length + in acpi_rs_convert_aml_to_resource()
173 resource->length = resource->length + in acpi_rs_convert_aml_to_resource()
182 resource->length = resource->length + item_count; in acpi_rs_convert_aml_to_resource()
[all …]
Drslist.c72 struct acpi_resource *resource; in acpi_rs_convert_aml_to_resources() local
83 resource = *resource_ptr; in acpi_rs_convert_aml_to_resources()
84 if (ACPI_IS_MISALIGNED(resource)) { in acpi_rs_convert_aml_to_resources()
86 "Misaligned resource pointer %p", resource)); in acpi_rs_convert_aml_to_resources()
118 acpi_rs_convert_aml_to_resource(resource, aml_resource, in acpi_rs_convert_aml_to_resources()
130 resource->length)); in acpi_rs_convert_aml_to_resources()
134 *resource_ptr = ACPI_NEXT_RESOURCE(resource); in acpi_rs_convert_aml_to_resources()
158 acpi_rs_convert_resources_to_aml(struct acpi_resource *resource, in acpi_rs_convert_resources_to_aml() argument
174 if (resource->type > ACPI_RESOURCE_TYPE_MAX) { in acpi_rs_convert_resources_to_aml()
177 resource->type)); in acpi_rs_convert_resources_to_aml()
[all …]
Drscalc.c188 acpi_rs_get_aml_length(struct acpi_resource * resource, acpi_size * size_needed) in acpi_rs_get_aml_length() argument
197 while (resource) { in acpi_rs_get_aml_length()
201 if (resource->type > ACPI_RESOURCE_TYPE_MAX) { in acpi_rs_get_aml_length()
207 total_size = acpi_gbl_aml_resource_sizes[resource->type]; in acpi_rs_get_aml_length()
213 switch (resource->type) { in acpi_rs_get_aml_length()
218 if (resource->data.irq.descriptor_length == 2) { in acpi_rs_get_aml_length()
227 if (resource->data.irq.descriptor_length == 0) { in acpi_rs_get_aml_length()
239 if (resource->data.vendor.byte_length > 7) { in acpi_rs_get_aml_length()
250 (total_size + resource->data.vendor.byte_length); in acpi_rs_get_aml_length()
271 acpi_rs_struct_option_length(&resource->data. in acpi_rs_get_aml_length()
[all …]
Drsxface.c70 acpi_rs_match_vendor_resource(struct acpi_resource *resource, void *context);
367 acpi_resource_to_address64(struct acpi_resource *resource, in ACPI_EXPORT_SYMBOL()
373 if (!resource || !out) { in ACPI_EXPORT_SYMBOL()
379 switch (resource->type) { in ACPI_EXPORT_SYMBOL()
384 &resource->data); in ACPI_EXPORT_SYMBOL()
392 &resource->data); in ACPI_EXPORT_SYMBOL()
400 ACPI_MEMCPY(out, &resource->data, in ACPI_EXPORT_SYMBOL()
476 acpi_rs_match_vendor_resource(struct acpi_resource *resource, void *context) in ACPI_EXPORT_SYMBOL()
485 if (resource->type != ACPI_RESOURCE_TYPE_VENDOR) { in ACPI_EXPORT_SYMBOL()
489 vendor = &resource->data.vendor_typed; in ACPI_EXPORT_SYMBOL()
[all …]
Drsaddr.c307 acpi_rs_get_address_common(struct acpi_resource *resource, in acpi_rs_get_address_common() argument
321 (void)acpi_rs_convert_aml_to_resource(resource, aml, in acpi_rs_get_address_common()
326 if (resource->data.address.resource_type == ACPI_MEMORY_RANGE) { in acpi_rs_get_address_common()
327 (void)acpi_rs_convert_aml_to_resource(resource, aml, in acpi_rs_get_address_common()
329 } else if (resource->data.address.resource_type == ACPI_IO_RANGE) { in acpi_rs_get_address_common()
330 (void)acpi_rs_convert_aml_to_resource(resource, aml, in acpi_rs_get_address_common()
335 resource->data.address.info.type_specific = in acpi_rs_get_address_common()
358 struct acpi_resource *resource) in acpi_rs_set_address_common() argument
364 (void)acpi_rs_convert_resource_to_aml(resource, aml, in acpi_rs_set_address_common()
369 if (resource->data.address.resource_type == ACPI_MEMORY_RANGE) { in acpi_rs_set_address_common()
[all …]
/drivers/staging/vme/
Dvme.c53 static struct vme_bridge *find_bridge(struct vme_resource *resource) in find_bridge() argument
56 switch (resource->type) { in find_bridge()
58 return list_entry(resource->entry, struct vme_master_resource, in find_bridge()
62 return list_entry(resource->entry, struct vme_slave_resource, in find_bridge()
66 return list_entry(resource->entry, struct vme_dma_resource, in find_bridge()
70 return list_entry(resource->entry, struct vme_lm_resource, in find_bridge()
84 void *vme_alloc_consistent(struct vme_resource *resource, size_t size, in vme_alloc_consistent() argument
89 if (resource == NULL) { in vme_alloc_consistent()
94 bridge = find_bridge(resource); in vme_alloc_consistent()
119 void vme_free_consistent(struct vme_resource *resource, size_t size, in vme_free_consistent() argument
[all …]
/drivers/net/tokenring/
Dibmtr_cs.c134 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; in ibmtr_attach()
135 link->resource[0]->end = 4; in ibmtr_attach()
183 link->resource[0]->start = 0xA20; in ibmtr_config()
187 link->resource[0]->start = 0xA24; in ibmtr_config()
192 dev->base_addr = link->resource[0]->start; in ibmtr_config()
202 link->resource[2]->flags |= WIN_DATA_WIDTH_16|WIN_MEMORY_TYPE_CM|WIN_ENABLE; in ibmtr_config()
203 link->resource[2]->flags |= WIN_USE_WAIT; in ibmtr_config()
204 link->resource[2]->start = 0; in ibmtr_config()
205 link->resource[2]->end = 0x2000; in ibmtr_config()
206 ret = pcmcia_request_window(link, link->resource[2], 250); in ibmtr_config()
[all …]
/drivers/tty/serial/8250/
Dserial_cs.c381 if ((p_dev->resource[1]->end != 0) && in pfc_config()
382 (resource_size(p_dev->resource[1]) == 8)) { in pfc_config()
383 port = p_dev->resource[1]->start; in pfc_config()
386 (resource_size(p_dev->resource[0]) == 0x40)) { in pfc_config()
387 port = p_dev->resource[0]->start + 0x28; in pfc_config()
402 if (p_dev->resource[0]->start == 0) in simple_config_check()
408 if (p_dev->resource[0]->end != size_table[(*try >> 1)]) in simple_config_check()
411 p_dev->resource[0]->end = 8; in simple_config_check()
412 p_dev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in simple_config_check()
413 p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; in simple_config_check()
[all …]
/drivers/tc/
Dtc.c114 tdev->resource.start = slotaddr; in tc_bus_add_devices()
115 tdev->resource.end = slotaddr + devsize - 1; in tc_bus_add_devices()
117 tdev->resource.start = extslotaddr; in tc_bus_add_devices()
118 tdev->resource.end = extslotaddr + devsize - 1; in tc_bus_add_devices()
127 tdev->resource.name = tdev->name; in tc_bus_add_devices()
128 tdev->resource.flags = IORESOURCE_MEM; in tc_bus_add_devices()
161 tc_bus.resource[0].start = tc_bus.slot_base; in tc_init()
162 tc_bus.resource[0].end = tc_bus.slot_base + in tc_init()
165 tc_bus.resource[0].name = tc_bus.name; in tc_init()
166 tc_bus.resource[0].flags = IORESOURCE_MEM; in tc_init()
[all …]
/drivers/mfd/
Dtwl4030-audio.c48 struct twl4030_audio_resource resource[TWL4030_AUDIO_RES_MAX]; member
62 audio->resource[id].reg); in twl4030_audio_set_resource()
65 val |= audio->resource[id].mask; in twl4030_audio_set_resource()
67 val &= ~audio->resource[id].mask; in twl4030_audio_set_resource()
70 val, audio->resource[id].reg); in twl4030_audio_set_resource()
81 audio->resource[id].reg); in twl4030_audio_get_resource()
102 if (!audio->resource[id].request_count) in twl4030_audio_enable_resource()
108 audio->resource[id].request_count++; in twl4030_audio_enable_resource()
131 if (!audio->resource[id].request_count) { in twl4030_audio_disable_resource()
137 audio->resource[id].request_count--; in twl4030_audio_disable_resource()
[all …]
/drivers/pci/
Dsetup-res.c36 struct resource *res = dev->resource + resno; in pci_update_resource()
93 int pci_claim_resource(struct pci_dev *dev, int resource) in pci_claim_resource() argument
95 struct resource *res = &dev->resource[resource]; in pci_claim_resource()
96 struct resource *root, *conflict; in pci_claim_resource()
133 struct resource *res = dev->resource + resno; in __pci_assign_resource()
171 static int pci_revert_fw_address(struct resource *res, struct pci_dev *dev, in pci_revert_fw_address()
174 struct resource *root, *conflict; in pci_revert_fw_address()
211 struct resource *res = dev->resource + resno; in _pci_assign_resource()
244 struct resource *res = dev->resource + resno; in pci_reassign_resource()
268 struct resource *res = dev->resource + resno; in pci_assign_resource()
[all …]
Drom.c27 struct resource *res = pdev->resource + PCI_ROM_RESOURCE; in pci_enable_rom()
116 struct resource *res = &pdev->resource[PCI_ROM_RESOURCE]; in pci_map_rom()
184 struct resource *res = &pdev->resource[PCI_ROM_RESOURCE];
217 struct resource *res = &pdev->resource[PCI_ROM_RESOURCE]; in pci_unmap_rom()
238 struct resource *res = &pdev->resource[PCI_ROM_RESOURCE];
258 struct resource *res = &pdev->resource[PCI_ROM_RESOURCE]; in pci_cleanup_rom()
Dsetup-bus.c35 struct resource *res;
64 struct pci_dev *dev, struct resource *res, in add_to_list()
89 struct resource *res) in remove_from_list()
103 struct resource *res) in get_res_add_size()
109 int idx = res - &dev_res->dev->resource[0]; in get_res_add_size()
129 struct resource *r; in pdev_sort_resources()
134 r = &dev->resource[i]; in pdev_sort_resources()
194 static inline void reset_resource(struct resource *res) in reset_resource()
216 struct resource *res; in reassign_resources_sorted()
240 idx = res - &add_res->dev->resource[0]; in reassign_resources_sorted()
[all …]
/drivers/pcmcia/
Dpcmcia_cis.c204 p_dev->resource[0]->start = p_dev->resource[0]->end = 0; in pcmcia_do_loop_config()
205 p_dev->resource[1]->start = p_dev->resource[1]->end = 0; in pcmcia_do_loop_config()
209 p_dev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in pcmcia_do_loop_config()
210 p_dev->resource[0]->flags |= in pcmcia_do_loop_config()
217 p_dev->resource[1]->flags = p_dev->resource[0]->flags; in pcmcia_do_loop_config()
218 p_dev->resource[1]->start = io->win[1-i].base; in pcmcia_do_loop_config()
219 p_dev->resource[1]->end = io->win[1-i].len; in pcmcia_do_loop_config()
221 p_dev->resource[0]->start = io->win[i].base; in pcmcia_do_loop_config()
222 p_dev->resource[0]->end = io->win[i].len; in pcmcia_do_loop_config()
231 p_dev->resource[2]->start = p_dev->resource[2]->end = 0; in pcmcia_do_loop_config()
[all …]
/drivers/mtd/devices/
Dms02-nv.c112 struct resource *mod_res; in ms02nv_init_one()
113 struct resource *diag_res; in ms02nv_init_one()
114 struct resource *user_res; in ms02nv_init_one()
115 struct resource *csr_res; in ms02nv_init_one()
153 mp->resource.module = mod_res; in ms02nv_init_one()
166 mp->resource.diag_ram = diag_res; in ms02nv_init_one()
179 mp->resource.user_ram = user_res; in ms02nv_init_one()
192 mp->resource.csr = csr_res; in ms02nv_init_one()
259 release_resource(mp->resource.csr); in ms02nv_remove_one()
260 kfree(mp->resource.csr); in ms02nv_remove_one()
[all …]
/drivers/pnp/pnpacpi/
Drsparser.c823 struct acpi_resource **resource = data; in pnpacpi_type_resources() local
826 (*resource)->type = res->type; in pnpacpi_type_resources()
827 (*resource)->length = sizeof(struct acpi_resource); in pnpacpi_type_resources()
829 (*resource)->data.irq.descriptor_length = in pnpacpi_type_resources()
831 (*resource)++; in pnpacpi_type_resources()
842 struct acpi_resource *resource; in pnpacpi_build_resource_template() local
859 resource = (struct acpi_resource *)buffer->pointer; in pnpacpi_build_resource_template()
861 pnpacpi_type_resources, &resource); in pnpacpi_build_resource_template()
868 resource->type = ACPI_RESOURCE_TYPE_END_TAG; in pnpacpi_build_resource_template()
874 struct acpi_resource *resource, in pnpacpi_encode_irq() argument
[all …]
/drivers/ssb/
Ddriver_chipcommon_pmu.c357 u8 resource; /* The resource number */ member
368 u8 resource; /* The resource number */ member
374 { .resource = SSB_PMURES_4328_EXT_SWITCHER_PWM, .updown = 0x0101, },
375 { .resource = SSB_PMURES_4328_BB_SWITCHER_PWM, .updown = 0x1F01, },
376 { .resource = SSB_PMURES_4328_BB_SWITCHER_BURST, .updown = 0x010F, },
377 { .resource = SSB_PMURES_4328_BB_EXT_SWITCHER_BURST, .updown = 0x0101, },
378 { .resource = SSB_PMURES_4328_ILP_REQUEST, .updown = 0x0202, },
379 { .resource = SSB_PMURES_4328_RADIO_SWITCHER_PWM, .updown = 0x0F01, },
380 { .resource = SSB_PMURES_4328_RADIO_SWITCHER_BURST, .updown = 0x0F01, },
381 { .resource = SSB_PMURES_4328_ROM_SWITCH, .updown = 0x0101, },
[all …]
/drivers/scsi/pcmcia/
Daha152x_stub.c125 if ((p_dev->resource[0]->end < 0x20) && in aha152x_config_check()
126 (p_dev->resource[1]->end >= 0x20)) in aha152x_config_check()
127 p_dev->resource[0]->start = p_dev->resource[1]->start; in aha152x_config_check()
129 if (p_dev->resource[0]->start >= 0xffff) in aha152x_config_check()
132 p_dev->resource[1]->start = p_dev->resource[1]->end = 0; in aha152x_config_check()
133 p_dev->resource[0]->end = 0x20; in aha152x_config_check()
134 p_dev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in aha152x_config_check()
135 p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; in aha152x_config_check()
163 s.io_port = link->resource[0]->start; in aha152x_config_cs()
/drivers/firewire/
Dcore-cdev.c109 struct client_resource resource; member
116 struct client_resource resource; member
121 struct client_resource resource; member
129 struct client_resource resource; member
135 struct client_resource resource; member
156 static void schedule_if_iso_resource(struct client_resource *resource) in schedule_if_iso_resource() argument
158 if (resource->release == release_iso_resource) in schedule_if_iso_resource()
159 schedule_iso_resource(container_of(resource, in schedule_if_iso_resource()
160 struct iso_resource, resource), 0); in schedule_if_iso_resource()
487 struct client_resource *resource, gfp_t gfp_mask) in add_client_resource() argument
[all …]
/drivers/ide/
Dide-cs.c170 if (!(pdev->resource[0]->flags & IO_DATA_PATH_WIDTH_8)) { in pcmcia_check_one_config()
171 pdev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in pcmcia_check_one_config()
172 pdev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; in pcmcia_check_one_config()
174 pdev->resource[1]->flags &= ~IO_DATA_PATH_WIDTH; in pcmcia_check_one_config()
175 pdev->resource[1]->flags |= IO_DATA_PATH_WIDTH_8; in pcmcia_check_one_config()
177 if (pdev->resource[1]->end) { in pcmcia_check_one_config()
178 pdev->resource[0]->end = 8; in pcmcia_check_one_config()
179 pdev->resource[1]->end = (*is_kme) ? 2 : 1; in pcmcia_check_one_config()
181 if (pdev->resource[0]->end < 16) in pcmcia_check_one_config()
206 io_base = link->resource[0]->start; in ide_config()
[all …]
/drivers/ata/
Dpata_pcmcia.c173 if (!(pdev->resource[0]->flags & IO_DATA_PATH_WIDTH_8)) { in pcmcia_check_one_config()
174 pdev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH; in pcmcia_check_one_config()
175 pdev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; in pcmcia_check_one_config()
177 pdev->resource[1]->flags &= ~IO_DATA_PATH_WIDTH; in pcmcia_check_one_config()
178 pdev->resource[1]->flags |= IO_DATA_PATH_WIDTH_8; in pcmcia_check_one_config()
180 if (pdev->resource[1]->end) { in pcmcia_check_one_config()
181 pdev->resource[0]->end = 8; in pcmcia_check_one_config()
182 pdev->resource[1]->end = (*is_kme) ? 2 : 1; in pcmcia_check_one_config()
184 if (pdev->resource[0]->end < 16) in pcmcia_check_one_config()
224 io_base = pdev->resource[0]->start; in pcmcia_init_one()
[all …]

12345678910>>...43