aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/block
diff options
context:
space:
mode:
authorMartin Schwidefsky <schwidefsky@de.ibm.com>2010-10-25 10:10:38 -0400
committerMartin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com>2010-10-25 10:10:19 -0400
commitf6649a7e5a9ee99e9623878f4a5579cc2f6cdd51 (patch)
tree183438313c7593565980a1445f208e0ba30162cd /drivers/s390/block
parent1e54622e0403891b10f2105663e0f9dd595a1f17 (diff)
[S390] cleanup lowcore access from external interrupts
Read external interrupts parameters from the lowcore in the first level interrupt handler in entry[64].S. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/block')
-rw-r--r--drivers/s390/block/dasd_diag.c19
-rw-r--r--drivers/s390/block/dasd_diag.h4
2 files changed, 8 insertions, 15 deletions
diff --git a/drivers/s390/block/dasd_diag.c b/drivers/s390/block/dasd_diag.c
index 2b3bc3ec054..266b34b5540 100644
--- a/drivers/s390/block/dasd_diag.c
+++ b/drivers/s390/block/dasd_diag.c
@@ -228,25 +228,22 @@ dasd_diag_term_IO(struct dasd_ccw_req * cqr)
228} 228}
229 229
230/* Handle external interruption. */ 230/* Handle external interruption. */
231static void 231static void dasd_ext_handler(unsigned int ext_int_code,
232dasd_ext_handler(__u16 code) 232 unsigned int param32, unsigned long param64)
233{ 233{
234 struct dasd_ccw_req *cqr, *next; 234 struct dasd_ccw_req *cqr, *next;
235 struct dasd_device *device; 235 struct dasd_device *device;
236 unsigned long long expires; 236 unsigned long long expires;
237 unsigned long flags; 237 unsigned long flags;
238 u8 int_code, status;
239 addr_t ip; 238 addr_t ip;
240 int rc; 239 int rc;
241 240
242 int_code = *((u8 *) DASD_DIAG_LC_INT_CODE); 241 switch (ext_int_code >> 24) {
243 status = *((u8 *) DASD_DIAG_LC_INT_STATUS);
244 switch (int_code) {
245 case DASD_DIAG_CODE_31BIT: 242 case DASD_DIAG_CODE_31BIT:
246 ip = (addr_t) *((u32 *) DASD_DIAG_LC_INT_PARM_31BIT); 243 ip = (addr_t) param32;
247 break; 244 break;
248 case DASD_DIAG_CODE_64BIT: 245 case DASD_DIAG_CODE_64BIT:
249 ip = (addr_t) *((u64 *) DASD_DIAG_LC_INT_PARM_64BIT); 246 ip = (addr_t) param64;
250 break; 247 break;
251 default: 248 default:
252 return; 249 return;
@@ -281,7 +278,7 @@ dasd_ext_handler(__u16 code)
281 cqr->stopclk = get_clock(); 278 cqr->stopclk = get_clock();
282 279
283 expires = 0; 280 expires = 0;
284 if (status == 0) { 281 if ((ext_int_code & 0xff0000) == 0) {
285 cqr->status = DASD_CQR_SUCCESS; 282 cqr->status = DASD_CQR_SUCCESS;
286 /* Start first request on queue if possible -> fast_io. */ 283 /* Start first request on queue if possible -> fast_io. */
287 if (!list_empty(&device->ccw_queue)) { 284 if (!list_empty(&device->ccw_queue)) {
@@ -296,8 +293,8 @@ dasd_ext_handler(__u16 code)
296 } else { 293 } else {
297 cqr->status = DASD_CQR_QUEUED; 294 cqr->status = DASD_CQR_QUEUED;
298 DBF_DEV_EVENT(DBF_DEBUG, device, "interrupt status for " 295 DBF_DEV_EVENT(DBF_DEBUG, device, "interrupt status for "
299 "request %p was %d (%d retries left)", cqr, status, 296 "request %p was %d (%d retries left)", cqr,
300 cqr->retries); 297 (ext_int_code >> 16) & 0xff, cqr->retries);
301 dasd_diag_erp(device); 298 dasd_diag_erp(device);
302 } 299 }
303 300
diff --git a/drivers/s390/block/dasd_diag.h b/drivers/s390/block/dasd_diag.h
index b8c78267ff3..4f71fbe60c8 100644
--- a/drivers/s390/block/dasd_diag.h
+++ b/drivers/s390/block/dasd_diag.h
@@ -18,10 +18,6 @@
18#define DEV_CLASS_FBA 0x01 18#define DEV_CLASS_FBA 0x01
19#define DEV_CLASS_ECKD 0x04 19#define DEV_CLASS_ECKD 0x04
20 20
21#define DASD_DIAG_LC_INT_CODE 132
22#define DASD_DIAG_LC_INT_STATUS 133
23#define DASD_DIAG_LC_INT_PARM_31BIT 128
24#define DASD_DIAG_LC_INT_PARM_64BIT 4536
25#define DASD_DIAG_CODE_31BIT 0x03 21#define DASD_DIAG_CODE_31BIT 0x03
26#define DASD_DIAG_CODE_64BIT 0x07 22#define DASD_DIAG_CODE_64BIT 0x07
27 23