Lines Matching refs:sccb

56 static int __init sclp_cmd_sync_early(sclp_cmdw_t cmd, void *sccb)  in sclp_cmd_sync_early()  argument
61 rc = sclp_service_call(cmd, sccb); in sclp_cmd_sync_early()
78 struct read_info_sccb *sccb; in sclp_read_info_early() local
82 sccb = &early_read_info_sccb; in sclp_read_info_early()
85 memset(sccb, 0, sizeof(*sccb)); in sclp_read_info_early()
86 sccb->header.length = sizeof(*sccb); in sclp_read_info_early()
87 sccb->header.function_code = 0x80; in sclp_read_info_early()
88 sccb->header.control_mask[2] = 0x80; in sclp_read_info_early()
89 rc = sclp_cmd_sync_early(commands[i], sccb); in sclp_read_info_early()
94 if (sccb->header.response_code == 0x10) { in sclp_read_info_early()
98 if (sccb->header.response_code != 0x1f0) in sclp_read_info_early()
105 struct read_info_sccb *sccb; in sclp_facilities_detect() local
111 sccb = &early_read_info_sccb; in sclp_facilities_detect()
112 sclp_facilities = sccb->facilities; in sclp_facilities_detect()
113 sclp_fac84 = sccb->fac84; in sclp_facilities_detect()
114 rnmax = sccb->rnmax ? sccb->rnmax : sccb->rnmax2; in sclp_facilities_detect()
115 rzm = sccb->rnsize ? sccb->rnsize : sccb->rnsize2; in sclp_facilities_detect()
135 struct read_info_sccb *sccb; in sclp_get_ipl_info() local
139 sccb = &early_read_info_sccb; in sclp_get_ipl_info()
141 if (sccb->flags & 0x2) in sclp_get_ipl_info()
143 memcpy(&info->loadparm, &sccb->loadparm, LOADPARM_LEN); in sclp_get_ipl_info()
153 static int do_sync_request(sclp_cmdw_t cmd, void *sccb) in do_sync_request() argument
163 request->sccb = sccb; in do_sync_request()
204 struct read_cpu_info_sccb *sccb) in sclp_fill_cpu_info() argument
206 char *page = (char *) sccb; in sclp_fill_cpu_info()
209 info->configured = sccb->nr_configured; in sclp_fill_cpu_info()
210 info->standby = sccb->nr_standby; in sclp_fill_cpu_info()
211 info->combined = sccb->nr_configured + sccb->nr_standby; in sclp_fill_cpu_info()
213 memcpy(&info->cpu, page + sccb->offset_configured, in sclp_fill_cpu_info()
220 struct read_cpu_info_sccb *sccb; in sclp_get_cpu_info() local
224 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_get_cpu_info()
225 if (!sccb) in sclp_get_cpu_info()
227 sccb->header.length = sizeof(*sccb); in sclp_get_cpu_info()
228 rc = do_sync_request(SCLP_CMDW_READ_CPU_INFO, sccb); in sclp_get_cpu_info()
231 if (sccb->header.response_code != 0x0010) { in sclp_get_cpu_info()
233 sccb->header.response_code); in sclp_get_cpu_info()
237 sclp_fill_cpu_info(info, sccb); in sclp_get_cpu_info()
239 free_page((unsigned long) sccb); in sclp_get_cpu_info()
249 struct cpu_configure_sccb *sccb; in do_cpu_configure() local
258 sccb = kzalloc(sizeof(*sccb), GFP_KERNEL | GFP_DMA); in do_cpu_configure()
259 if (!sccb) in do_cpu_configure()
261 sccb->header.length = sizeof(*sccb); in do_cpu_configure()
262 rc = do_sync_request(cmd, sccb); in do_cpu_configure()
265 switch (sccb->header.response_code) { in do_cpu_configure()
272 sccb->header.response_code); in do_cpu_configure()
277 kfree(sccb); in do_cpu_configure()
325 struct assign_storage_sccb *sccb; in do_assign_storage() local
328 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_assign_storage()
329 if (!sccb) in do_assign_storage()
331 sccb->header.length = PAGE_SIZE; in do_assign_storage()
332 sccb->rn = rn; in do_assign_storage()
333 rc = do_sync_request(cmd, sccb); in do_assign_storage()
336 switch (sccb->header.response_code) { in do_assign_storage()
343 sccb->header.response_code, rn); in do_assign_storage()
348 free_page((unsigned long) sccb); in do_assign_storage()
372 struct attach_storage_sccb *sccb; in sclp_attach_storage() local
376 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_attach_storage()
377 if (!sccb) in sclp_attach_storage()
379 sccb->header.length = PAGE_SIZE; in sclp_attach_storage()
380 rc = do_sync_request(0x00080001 | id << 8, sccb); in sclp_attach_storage()
383 switch (sccb->header.response_code) { in sclp_attach_storage()
386 for (i = 0; i < sccb->assigned; i++) in sclp_attach_storage()
387 sclp_unassign_storage(sccb->entries[i] >> 16); in sclp_attach_storage()
394 free_page((unsigned long) sccb); in sclp_attach_storage()
573 struct read_storage_sccb *sccb; in sclp_detect_standby_memory() local
581 sccb = (void *) __get_free_page(GFP_KERNEL | GFP_DMA); in sclp_detect_standby_memory()
582 if (!sccb) in sclp_detect_standby_memory()
586 memset(sccb, 0, PAGE_SIZE); in sclp_detect_standby_memory()
587 sccb->header.length = PAGE_SIZE; in sclp_detect_standby_memory()
588 rc = do_sync_request(0x00040001 | id << 8, sccb); in sclp_detect_standby_memory()
591 switch (sccb->header.response_code) { in sclp_detect_standby_memory()
594 for (i = 0; i < sccb->assigned; i++) { in sclp_detect_standby_memory()
595 if (!sccb->entries[i]) in sclp_detect_standby_memory()
598 insert_increment(sccb->entries[i] >> 16, 0, 1); in sclp_detect_standby_memory()
604 for (i = 0; i < sccb->assigned; i++) { in sclp_detect_standby_memory()
605 if (!sccb->entries[i]) in sclp_detect_standby_memory()
608 insert_increment(sccb->entries[i] >> 16, 1, 1); in sclp_detect_standby_memory()
616 sclp_max_storage_id = sccb->max_id; in sclp_detect_standby_memory()
637 free_page((unsigned long) sccb); in sclp_detect_standby_memory()
661 struct chp_cfg_sccb *sccb; in do_chp_configure() local
667 sccb = (struct chp_cfg_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_chp_configure()
668 if (!sccb) in do_chp_configure()
670 sccb->header.length = sizeof(*sccb); in do_chp_configure()
671 rc = do_sync_request(cmd, sccb); in do_chp_configure()
674 switch (sccb->header.response_code) { in do_chp_configure()
683 sccb->header.response_code); in do_chp_configure()
688 free_page((unsigned long) sccb); in do_chp_configure()
736 struct chp_info_sccb *sccb; in sclp_chp_read_info() local
742 sccb = (struct chp_info_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_chp_read_info()
743 if (!sccb) in sclp_chp_read_info()
745 sccb->header.length = sizeof(*sccb); in sclp_chp_read_info()
746 rc = do_sync_request(SCLP_CMDW_READ_CHPATH_INFORMATION, sccb); in sclp_chp_read_info()
749 if (sccb->header.response_code != 0x0010) { in sclp_chp_read_info()
751 "(response=0x%04x)\n", sccb->header.response_code); in sclp_chp_read_info()
755 memcpy(info->recognized, sccb->recognized, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
756 memcpy(info->standby, sccb->standby, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
757 memcpy(info->configured, sccb->configured, SCLP_CHP_INFO_MASK_SIZE); in sclp_chp_read_info()
759 free_page((unsigned long) sccb); in sclp_chp_read_info()