Lines Matching full:sccb
40 int sclp_sync_request(sclp_cmdw_t cmd, void *sccb) in sclp_sync_request() argument
42 return sclp_sync_request_timeout(cmd, sccb, 0); in sclp_sync_request()
45 int sclp_sync_request_timeout(sclp_cmdw_t cmd, void *sccb, int timeout) in sclp_sync_request_timeout() argument
57 request->sccb = sccb; in sclp_sync_request_timeout()
91 struct read_cpu_info_sccb *sccb; in _sclp_get_core_info() local
96 sccb = (void *)__get_free_pages(GFP_KERNEL | GFP_DMA | __GFP_ZERO, get_order(length)); in _sclp_get_core_info()
97 if (!sccb) in _sclp_get_core_info()
99 sccb->header.length = length; in _sclp_get_core_info()
100 sccb->header.control_mask[2] = 0x80; in _sclp_get_core_info()
101 rc = sclp_sync_request_timeout(SCLP_CMDW_READ_CPU_INFO, sccb, in _sclp_get_core_info()
105 if (sccb->header.response_code != 0x0010) { in _sclp_get_core_info()
107 sccb->header.response_code); in _sclp_get_core_info()
111 sclp_fill_core_info(info, sccb); in _sclp_get_core_info()
113 free_pages((unsigned long) sccb, get_order(length)); in _sclp_get_core_info()
123 struct cpu_configure_sccb *sccb; in do_core_configure() local
132 sccb = kzalloc(sizeof(*sccb), GFP_KERNEL | GFP_DMA); in do_core_configure()
133 if (!sccb) in do_core_configure()
135 sccb->header.length = sizeof(*sccb); in do_core_configure()
136 rc = sclp_sync_request_timeout(cmd, sccb, SCLP_QUEUE_INTERVAL); in do_core_configure()
139 switch (sccb->header.response_code) { in do_core_configure()
145 cmd, sccb->header.response_code); in do_core_configure()
150 kfree(sccb); in do_core_configure()
196 struct assign_storage_sccb *sccb; in do_assign_storage() local
199 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_assign_storage()
200 if (!sccb) in do_assign_storage()
202 sccb->header.length = PAGE_SIZE; in do_assign_storage()
203 sccb->rn = rn; in do_assign_storage()
204 rc = sclp_sync_request_timeout(cmd, sccb, SCLP_QUEUE_INTERVAL); in do_assign_storage()
207 switch (sccb->header.response_code) { in do_assign_storage()
213 cmd, sccb->header.response_code, rn); in do_assign_storage()
218 free_page((unsigned long) sccb); in do_assign_storage()
250 struct attach_storage_sccb *sccb; in sclp_attach_storage() local
254 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_attach_storage()
255 if (!sccb) in sclp_attach_storage()
257 sccb->header.length = PAGE_SIZE; in sclp_attach_storage()
258 sccb->header.function_code = 0x40; in sclp_attach_storage()
259 rc = sclp_sync_request_timeout(0x00080001 | id << 8, sccb, in sclp_attach_storage()
263 switch (sccb->header.response_code) { in sclp_attach_storage()
266 for (i = 0; i < sccb->assigned; i++) { in sclp_attach_storage()
267 if (sccb->entries[i]) in sclp_attach_storage()
268 sclp_unassign_storage(sccb->entries[i] >> 16); in sclp_attach_storage()
276 free_page((unsigned long) sccb); in sclp_attach_storage()
457 struct read_storage_sccb *sccb; in sclp_detect_standby_memory() local
465 sccb = (void *) __get_free_page(GFP_KERNEL | GFP_DMA); in sclp_detect_standby_memory()
466 if (!sccb) in sclp_detect_standby_memory()
470 memset(sccb, 0, PAGE_SIZE); in sclp_detect_standby_memory()
471 sccb->header.length = PAGE_SIZE; in sclp_detect_standby_memory()
472 rc = sclp_sync_request(SCLP_CMDW_READ_STORAGE_INFO | id << 8, sccb); in sclp_detect_standby_memory()
475 switch (sccb->header.response_code) { in sclp_detect_standby_memory()
478 for (i = 0; i < sccb->assigned; i++) { in sclp_detect_standby_memory()
479 if (!sccb->entries[i]) in sclp_detect_standby_memory()
482 insert_increment(sccb->entries[i] >> 16, 0, 1); in sclp_detect_standby_memory()
488 for (i = 0; i < sccb->assigned; i++) { in sclp_detect_standby_memory()
489 if (!sccb->entries[i]) in sclp_detect_standby_memory()
492 insert_increment(sccb->entries[i] >> 16, 1, 1); in sclp_detect_standby_memory()
500 sclp_max_storage_id = sccb->max_id; in sclp_detect_standby_memory()
511 free_page((unsigned long) sccb); in sclp_detect_standby_memory()
535 struct chp_cfg_sccb *sccb; in do_chp_configure() local
540 /* Prepare sccb. */ in do_chp_configure()
541 sccb = (struct chp_cfg_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_chp_configure()
542 if (!sccb) in do_chp_configure()
544 sccb->header.length = sizeof(*sccb); in do_chp_configure()
545 rc = sclp_sync_request(cmd, sccb); in do_chp_configure()
548 switch (sccb->header.response_code) { in do_chp_configure()
556 cmd, sccb->header.response_code); in do_chp_configure()
561 free_page((unsigned long) sccb); in do_chp_configure()
609 struct chp_info_sccb *sccb; in sclp_chp_read_info() local
614 /* Prepare sccb. */ in sclp_chp_read_info()
615 sccb = (struct chp_info_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_chp_read_info()
616 if (!sccb) in sclp_chp_read_info()
618 sccb->header.length = sizeof(*sccb); in sclp_chp_read_info()
619 rc = sclp_sync_request(SCLP_CMDW_READ_CHPATH_INFORMATION, sccb); in sclp_chp_read_info()
622 if (sccb->header.response_code != 0x0010) { in sclp_chp_read_info()
624 sccb->header.response_code); in sclp_chp_read_info()
628 memcpy(info->recognized, sccb->recognized, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
629 memcpy(info->standby, sccb->standby, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
630 memcpy(info->configured, sccb->configured, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
632 free_page((unsigned long) sccb); in sclp_chp_read_info()