/openbmc/linux/drivers/s390/char/ |
H A D | sclp_early.c | 29 struct read_info_sccb *sccb; in sclp_early_facilities_detect() local 32 sccb = sclp_early_get_info(); in sclp_early_facilities_detect() 33 if (!sccb) in sclp_early_facilities_detect() 36 sclp.facilities = sccb->facilities; in sclp_early_facilities_detect() 37 sclp.has_sprp = !!(sccb->fac84 & 0x02); in sclp_early_facilities_detect() 38 sclp.has_core_type = !!(sccb->fac84 & 0x01); in sclp_early_facilities_detect() 39 sclp.has_gsls = !!(sccb->fac85 & 0x80); in sclp_early_facilities_detect() 40 sclp.has_64bscao = !!(sccb->fac116 & 0x80); in sclp_early_facilities_detect() 41 sclp.has_cmma = !!(sccb->fac116 & 0x40); in sclp_early_facilities_detect() 42 sclp.has_esca = !!(sccb->fac116 & 0x08); in sclp_early_facilities_detect() [all …]
|
H A D | sclp_early_core.c | 64 int sclp_early_cmd(sclp_cmdw_t cmd, void *sccb) in sclp_early_cmd() argument 70 rc = sclp_service_call(cmd, sccb); in sclp_early_cmd() 89 struct write_sccb *sccb; in sclp_early_print_lm() local 95 sccb = (struct write_sccb *) sclp_early_sccb; in sclp_early_print_lm() 96 end = (unsigned char *) sccb + EARLY_SCCB_SIZE - 1; in sclp_early_print_lm() 97 memset(sccb, 0, sizeof(*sccb)); in sclp_early_print_lm() 98 ptr = (unsigned char *) &sccb->msg.mdb.mto; in sclp_early_print_lm() 114 len = ptr - (unsigned char *) sccb; in sclp_early_print_lm() 115 sccb->header.length = len - offsetof(struct write_sccb, header); in sclp_early_print_lm() 116 msg = &sccb->msg; in sclp_early_print_lm() [all …]
|
H A D | sclp_cmd.c | 39 int sclp_sync_request(sclp_cmdw_t cmd, void *sccb) in sclp_sync_request() argument 41 return sclp_sync_request_timeout(cmd, sccb, 0); in sclp_sync_request() 44 int sclp_sync_request_timeout(sclp_cmdw_t cmd, void *sccb, int timeout) in sclp_sync_request_timeout() argument 56 request->sccb = sccb; in sclp_sync_request_timeout() 90 struct read_cpu_info_sccb *sccb; in _sclp_get_core_info() local 95 sccb = (void *)__get_free_pages(GFP_KERNEL | GFP_DMA | __GFP_ZERO, get_order(length)); in _sclp_get_core_info() 96 if (!sccb) in _sclp_get_core_info() 98 sccb->header.length = length; in _sclp_get_core_info() 99 sccb->header.control_mask[2] = 0x80; in _sclp_get_core_info() 100 rc = sclp_sync_request_timeout(SCLP_CMDW_READ_CPU_INFO, sccb, in _sclp_get_core_info() [all …]
|
H A D | sclp_sdias.c | 61 struct sdias_sccb *sccb = sclp_sdias_sccb; in sdias_sclp_send() local 82 if (!(sccb->evbuf.hdr.flags & 0x80)) { in sdias_sclp_send() 84 sccb->evbuf.hdr.flags); in sdias_sclp_send() 88 * for the sync interface the response is in the initial sccb in sdias_sclp_send() 91 memcpy(&sdias_evbuf, &sccb->evbuf, sizeof(sdias_evbuf)); in sdias_sclp_send() 108 struct sdias_sccb *sccb = sclp_sdias_sccb; in sclp_sdias_blk_count() local 114 memset(sccb, 0, sizeof(*sccb)); in sclp_sdias_blk_count() 117 sccb->hdr.length = sizeof(*sccb); in sclp_sdias_blk_count() 118 sccb->evbuf.hdr.length = sizeof(struct sdias_evbuf); in sclp_sdias_blk_count() 119 sccb->evbuf.hdr.type = EVTYP_SDIAS; in sclp_sdias_blk_count() [all …]
|
H A D | sclp_pci.c | 60 struct pci_cfg_sccb *sccb; in do_pci_configure() local 66 sccb = (struct pci_cfg_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_pci_configure() 67 if (!sccb) in do_pci_configure() 70 sccb->header.length = PAGE_SIZE; in do_pci_configure() 71 sccb->atype = SCLP_ATYPE_PCI; in do_pci_configure() 72 sccb->aid = fid; in do_pci_configure() 73 rc = sclp_sync_request(cmd, sccb); in do_pci_configure() 76 switch (sccb->header.response_code) { in do_pci_configure() 82 cmd, sccb->header.response_code); in do_pci_configure() 87 free_page((unsigned long) sccb); in do_pci_configure() [all …]
|
H A D | sclp.h | 123 #define sccb_get_generic_mask(sccb, i) \ argument 125 __typeof__(sccb) __sccb = sccb; \ 129 #define sccb_get_recv_mask(sccb) sccb_get_generic_mask(sccb, 0) argument 130 #define sccb_get_send_mask(sccb) sccb_get_generic_mask(sccb, 1) argument 131 #define sccb_get_sclp_recv_mask(sccb) sccb_get_generic_mask(sccb, 2) argument 132 #define sccb_get_sclp_send_mask(sccb) sccb_get_generic_mask(sccb, 3) argument 134 #define sccb_set_generic_mask(sccb, i, val) \ argument 136 __typeof__(sccb) __sccb = sccb; \ 140 #define sccb_set_recv_mask(sccb, val) sccb_set_generic_mask(sccb, 0, val) argument 141 #define sccb_set_send_mask(sccb, val) sccb_set_generic_mask(sccb, 1, val) argument [all …]
|
H A D | sclp_rw.c | 23 * The room for the SCCB (only for writing) is not equal to a pages size 44 struct sccb_header *sccb; in sclp_make_buffer() local 46 sccb = (struct sccb_header *) page; in sclp_make_buffer() 49 * of the sccb page. in sclp_make_buffer() 51 buffer = ((struct sclp_buffer *) ((addr_t) sccb + PAGE_SIZE)) - 1; in sclp_make_buffer() 52 buffer->sccb = sccb; in sclp_make_buffer() 61 /* initialize sccb */ in sclp_make_buffer() 62 memset(sccb, 0, sizeof(struct sccb_header)); in sclp_make_buffer() 63 sccb->length = sizeof(struct sccb_header); in sclp_make_buffer() 75 return buffer->sccb; in sclp_unmake_buffer() [all …]
|
H A D | sclp_ftp.c | 42 pr_debug("SCLP (ET7) TX-IRQ, SCCB @ 0x%p: %*phN\n", in sclp_ftp_txcb() 43 req->sccb, 24, req->sccb); in sclp_ftp_txcb() 91 struct sclp_diag_sccb *sccb; in sclp_ftp_et7() local 97 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_ftp_et7() 98 if (!req || !sccb) { in sclp_ftp_et7() 103 sccb->hdr.length = SCLP_DIAG_FTP_EVBUF_LEN + in sclp_ftp_et7() 105 sccb->evbuf.hdr.type = EVTYP_DIAG_TEST; in sclp_ftp_et7() 106 sccb->evbuf.hdr.length = SCLP_DIAG_FTP_EVBUF_LEN; in sclp_ftp_et7() 107 sccb->evbuf.hdr.flags = 0; /* clear processed-buffer */ in sclp_ftp_et7() 108 sccb->evbuf.route = SCLP_DIAG_FTP_ROUTE; in sclp_ftp_et7() [all …]
|
H A D | sclp.c | 110 static inline int abbrev_len(sclp_cmdw_t cmd, struct sccb_header *sccb) in abbrev_len() argument 112 struct evbuf_header *evbuf = (struct evbuf_header *)(sccb + 1); in abbrev_len() 113 int len = sccb->length, limit = SCLP_TRACE_MAX_SIZE; in abbrev_len() 115 /* Full SCCB tracing if debug level is set to max. */ in abbrev_len() 128 sclp_cmdw_t cmd, struct sccb_header *sccb, in sclp_trace_sccb() argument 132 if (sccb) { in sclp_trace_sccb() 133 sclp_trace_bin(prio + 1, sccb, abbrev_len(cmd, sccb), in sclp_trace_sccb() 134 err ? sccb->length : 0); in sclp_trace_sccb() 150 struct sccb_header *sccb = req->sccb; in sclp_trace_req() local 162 summary.response = sccb ? sccb->response_code : 0; in sclp_trace_req() [all …]
|
H A D | sclp_ctl.c | 58 struct sccb_header *sccb; in sclp_ctl_ioctl_sccb() local 66 sccb = (void *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_ctl_ioctl_sccb() 67 if (!sccb) in sclp_ctl_ioctl_sccb() 70 copy_from_user(sccb, u64_to_uptr(ctl_sccb.sccb), PAGE_SIZE); in sclp_ctl_ioctl_sccb() 72 sizeof(sccb->length) > copied || sccb->length > copied) { in sclp_ctl_ioctl_sccb() 76 if (sccb->length < 8) { in sclp_ctl_ioctl_sccb() 80 rc = sclp_sync_request(ctl_sccb.cmdw, sccb); in sclp_ctl_ioctl_sccb() 83 if (copy_to_user(u64_to_uptr(ctl_sccb.sccb), sccb, sccb->length)) in sclp_ctl_ioctl_sccb() 86 free_page((unsigned long) sccb); in sclp_ctl_ioctl_sccb() 91 * SCLP SCCB ioctl function
|
H A D | sclp_vt220.c | 49 /* VT220 SCCB */ 123 page = request->sclp_req.sccb; in sclp_vt220_process_queue() 155 struct sclp_vt220_sccb *sccb; in sclp_vt220_callback() local 162 sccb = (struct sclp_vt220_sccb *) vt220_request->sclp_req.sccb; in sclp_vt220_callback() 165 switch (sccb->header.response_code) { in sclp_vt220_callback() 176 if (sclp_remove_processed((struct sccb_header *) sccb) > 0) { in sclp_vt220_callback() 178 sccb->header.response_code = 0x0000; in sclp_vt220_callback() 188 sccb->header.response_code = 0x0000; in sclp_vt220_callback() 223 struct sclp_vt220_sccb *sccb; in sclp_vt220_emit_current() local 227 sccb = (struct sclp_vt220_sccb *) in sclp_vt220_emit_current() [all …]
|
H A D | sclp_config.c | 95 struct sclp_ofb_sccb *sccb; in sclp_ofb_send_req() local 100 sccb = (struct sclp_ofb_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in sclp_ofb_send_req() 101 if (!sccb) in sclp_ofb_send_req() 103 /* Setup SCCB for Control-Program Identification */ in sclp_ofb_send_req() 104 sccb->header.length = sizeof(struct sclp_ofb_sccb); in sclp_ofb_send_req() 105 sccb->ofb_evbuf.header.length = sizeof(struct sclp_ofb_evbuf); in sclp_ofb_send_req() 106 sccb->ofb_evbuf.header.type = EVTYP_CONFMGMDATA; in sclp_ofb_send_req() 107 sccb->ofb_evbuf.cm_data.ev_qualifier = EV_QUAL_OPEN4BUSINESS; in sclp_ofb_send_req() 108 memcpy(sccb->ofb_evbuf.ev_data, ev_data, len); in sclp_ofb_send_req() 115 rc = sclp_sync_request(SCLP_CMDW_WRITE_EVENT_DATA, sccb); in sclp_ofb_send_req() [all …]
|
H A D | sclp_ap.c | 24 struct ap_cfg_sccb *sccb; in do_ap_configure() local 30 sccb = (struct ap_cfg_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in do_ap_configure() 31 if (!sccb) in do_ap_configure() 34 sccb->header.length = PAGE_SIZE; in do_ap_configure() 36 rc = sclp_sync_request(cmd, sccb); in do_ap_configure() 39 switch (sccb->header.response_code) { in do_ap_configure() 44 apid, cmd, sccb->header.response_code); in do_ap_configure() 49 free_page((unsigned long) sccb); in do_ap_configure()
|
H A D | sclp_cpi_sys.c | 82 struct cpi_sccb *sccb; in cpi_prepare_req() local 88 sccb = (struct cpi_sccb *) get_zeroed_page(GFP_KERNEL | GFP_DMA); in cpi_prepare_req() 89 if (!sccb) { in cpi_prepare_req() 94 /* setup SCCB for Control-Program Identification */ in cpi_prepare_req() 95 sccb->header.length = sizeof(struct cpi_sccb); in cpi_prepare_req() 96 sccb->cpi_evbuf.header.length = sizeof(struct cpi_evbuf); in cpi_prepare_req() 97 sccb->cpi_evbuf.header.type = EVTYP_CTLPROGIDENT; in cpi_prepare_req() 98 evb = &sccb->cpi_evbuf; in cpi_prepare_req() 114 req->sccb = sccb; in cpi_prepare_req() 122 free_page((unsigned long) req->sccb); in cpi_free_req() [all …]
|
H A D | sclp_rw.h | 57 /* The number of empty mto buffers that can be contained in a single sccb. */ 68 void *sccb; member 77 unsigned int char_sum; /* # chars in sccb */ 78 unsigned int messages; /* # messages in sccb */
|
H A D | sclp_sd.c | 192 struct sclp_sd_sccb *sccb = (void *) page; in sclp_sd_sync() local 197 sclp_sd_listener_init(&listener, __pa(sccb)); in sclp_sd_sync() 200 /* Prepare SCCB */ in sclp_sd_sync() 201 memset(sccb, 0, PAGE_SIZE); in sclp_sd_sync() 202 sccb->hdr.length = sizeof(sccb->hdr) + sizeof(sccb->evbuf); in sclp_sd_sync() 203 evbuf = &sccb->evbuf; in sclp_sd_sync() 217 rc = sclp_sync_request(SCLP_CMDW_WRITE_EVENT_DATA, sccb); in sclp_sd_sync() 223 if (sccb->hdr.response_code == 0x73f0) { in sclp_sd_sync() 228 if (sccb->hdr.response_code != 0x0020 || !(evbuf->hdr.flags & 0x80)) { in sclp_sd_sync() 261 eq, di, sccb->hdr.response_code, evbuf->hdr.flags, in sclp_sd_sync()
|
H A D | sclp_diag.h | 80 * struct sclp_diag_sccb - Diagnostic Test (ET7) SCCB 81 * @hdr: SCCB header
|
/openbmc/qemu/hw/s390x/ |
H A D | sclp.c | 63 * An extended-length SCCB is only allowed for Read SCP/CPU Info and in sccb_verify_boundary() 66 * SCCB length is provided. in sccb_verify_boundary() 107 static void read_SCP_info(SCLPDevice *sclp, SCCB *sccb) in read_SCP_info() argument 109 ReadInfo *read_info = (ReadInfo *) sccb; in read_SCP_info() 117 CPUEntry *entries_start = (void *)sccb + offset_cpu; in read_SCP_info() 119 if (be16_to_cpu(sccb->h.length) < required_len) { in read_SCP_info() 120 if (ext_len_sccb_supported(sccb->h)) { in read_SCP_info() 121 sccb->h.length = cpu_to_be16(required_len); in read_SCP_info() 123 sccb->h.response_code = cpu_to_be16(SCLP_RC_INSUFFICIENT_SCCB_LENGTH); in read_SCP_info() 176 sccb->h.response_code = cpu_to_be16(SCLP_RC_NORMAL_READ_COMPLETION); in read_SCP_info() [all …]
|
H A D | event-facility.c | 109 static uint16_t write_event_length_check(SCCB *sccb) in write_event_length_check() argument 114 WriteEventData *wed = (WriteEventData *) sccb; in write_event_length_check() 117 for (slen = sccb_data_len(sccb); slen > 0; slen -= elen) { in write_event_length_check() 131 EventBufferHeader *event_buf, SCCB *sccb) in handle_write_event_buf() argument 154 static uint16_t handle_sccb_write_events(SCLPEventFacility *ef, SCCB *sccb) in handle_sccb_write_events() argument 160 WriteEventData *wed = (WriteEventData *) sccb; in handle_sccb_write_events() 166 for (slen = sccb_data_len(sccb); slen > 0; slen -= elen) { in handle_sccb_write_events() 174 rc = handle_write_event_buf(ef, event_buf, sccb); in handle_sccb_write_events() 181 static void write_event_data(SCLPEventFacility *ef, SCCB *sccb) in write_event_data() argument 183 if (sccb->h.function_code != SCLP_FC_NORMAL_WRITE) { in write_event_data() [all …]
|
/openbmc/qemu/pc-bios/s390-ccw/ |
H A D | sclp.c | 31 static int sclp_service_call(unsigned int command, void *sccb) in sclp_service_call() argument 39 : "=&d" (cc) : "d" (command), "a" (__pa(sccb)) in sclp_service_call() 51 WriteEventMask *sccb = (void *)_sccb; in sclp_set_write_mask() local 53 sccb->h.length = sizeof(WriteEventMask); in sclp_set_write_mask() 54 sccb->mask_length = sizeof(unsigned int); in sclp_set_write_mask() 55 sccb->cp_receive_mask = receive_mask; in sclp_set_write_mask() 56 sccb->cp_send_mask = send_mask; in sclp_set_write_mask() 58 sclp_service_call(SCLP_CMD_WRITE_EVENT_MASK, sccb); in sclp_set_write_mask() 68 WriteEventData *sccb = (void *)_sccb; in write() local 79 /* We would overflow the sccb buffer, abort early */ in write() [all …]
|
H A D | sclp.h | 36 /* Service Call Control Block (SCCB) and its elements */ 62 typedef struct SCCB { struct 65 } __attribute__((packed)) SCCB; typedef
|
/openbmc/qemu/include/hw/s390x/ |
H A D | sclp.h | 70 /* Service Call Control Block (SCCB) and its elements */ 83 * - some of the embedded structures below the SCCB can appear multiple times 85 * - we work on a private copy of the SCCB, since there are several length 142 * When the Extended-Length SCCB (ELS) feature is enabled the 188 typedef struct SCCB { struct 191 } QEMU_PACKED SCCB; typedef 211 void (*read_SCP_info)(SCLPDevice *sclp, SCCB *sccb); 212 void (*read_cpu_info)(SCLPDevice *sclp, SCCB *sccb); 215 void (*execute)(SCLPDevice *sclp, SCCB *sccb, uint32_t code); 216 void (*service_interrupt)(SCLPDevice *sclp, uint32_t sccb); [all …]
|
H A D | s390-pci-bus.h | 389 void s390_pci_sclp_configure(SCCB *sccb); 390 void s390_pci_sclp_deconfigure(SCCB *sccb);
|
/openbmc/linux/drivers/base/regmap/ |
H A D | regmap-sccb.c | 2 // Register map access API - SCCB support 11 * sccb_is_available - Check if the adapter supports SCCB protocol 14 * Return true if the I2C adapter is capable of using SCCB helper functions, 22 * If we ever want support for hardware doing SCCB natively, we will in sccb_is_available() 31 * regmap_sccb_read - Read data from SCCB slave device 67 * regmap_sccb_write - Write data to SCCB slave device 72 * This executes the SCCB 3-phase write transmission cycle, returning negative
|
/openbmc/linux/drivers/scsi/ |
H A D | FlashPoint.c | 3 FlashPoint.c -- FlashPoint SCCB Manager for Linux 5 This file contains the FlashPoint SCCB Manager from BusLogic's FlashPoint 28 struct sccb; 29 typedef void (*CALL_BK_FN) (struct sccb *); 69 /* SCCB struct used for both SCCB and UCB manager compiles! 70 * The UCB Manager treats the SCCB as it's 'native hardware structure' 74 struct sccb { struct 108 struct sccb *Sccb_forwardlink; argument 109 struct sccb *Sccb_backlink; argument 153 #define SCCB_COMPLETE 0x00 /* SCCB completed without error */ [all …]
|