Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
12ffbbe9
Commit
12ffbbe9
authored
Feb 04, 2016
by
James Bottomley
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'mkp-scsi/4.5/scsi-fixes' into fixes
parents
6344a5cd
0fb5b1fb
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
31 additions
and
20 deletions
+31
-20
block/blk-core.c
block/blk-core.c
+4
-2
drivers/scsi/device_handler/scsi_dh_rdac.c
drivers/scsi/device_handler/scsi_dh_rdac.c
+3
-1
drivers/scsi/hisi_sas/Kconfig
drivers/scsi/hisi_sas/Kconfig
+1
-1
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
+3
-6
drivers/scsi/scsi_devinfo.c
drivers/scsi/scsi_devinfo.c
+1
-0
drivers/scsi/sd.c
drivers/scsi/sd.c
+2
-2
drivers/scsi/storvsc_drv.c
drivers/scsi/storvsc_drv.c
+11
-5
include/linux/blkdev.h
include/linux/blkdev.h
+6
-3
No files found.
block/blk-core.c
View file @
12ffbbe9
...
@@ -2455,14 +2455,16 @@ struct request *blk_peek_request(struct request_queue *q)
...
@@ -2455,14 +2455,16 @@ struct request *blk_peek_request(struct request_queue *q)
rq
=
NULL
;
rq
=
NULL
;
break
;
break
;
}
else
if
(
ret
==
BLKPREP_KILL
)
{
}
else
if
(
ret
==
BLKPREP_KILL
||
ret
==
BLKPREP_INVALID
)
{
int
err
=
(
ret
==
BLKPREP_INVALID
)
?
-
EREMOTEIO
:
-
EIO
;
rq
->
cmd_flags
|=
REQ_QUIET
;
rq
->
cmd_flags
|=
REQ_QUIET
;
/*
/*
* Mark this request as started so we don't trigger
* Mark this request as started so we don't trigger
* any debug logic in the end I/O path.
* any debug logic in the end I/O path.
*/
*/
blk_start_request
(
rq
);
blk_start_request
(
rq
);
__blk_end_request_all
(
rq
,
-
EIO
);
__blk_end_request_all
(
rq
,
err
);
}
else
{
}
else
{
printk
(
KERN_ERR
"%s: bad return=%d
\n
"
,
__func__
,
ret
);
printk
(
KERN_ERR
"%s: bad return=%d
\n
"
,
__func__
,
ret
);
break
;
break
;
...
...
drivers/scsi/device_handler/scsi_dh_rdac.c
View file @
12ffbbe9
...
@@ -562,7 +562,7 @@ static int mode_select_handle_sense(struct scsi_device *sdev,
...
@@ -562,7 +562,7 @@ static int mode_select_handle_sense(struct scsi_device *sdev,
/*
/*
* Command Lock contention
* Command Lock contention
*/
*/
err
=
SCSI_DH_RETRY
;
err
=
SCSI_DH_
IMM_
RETRY
;
break
;
break
;
default:
default:
break
;
break
;
...
@@ -612,6 +612,8 @@ static void send_mode_select(struct work_struct *work)
...
@@ -612,6 +612,8 @@ static void send_mode_select(struct work_struct *work)
err
=
mode_select_handle_sense
(
sdev
,
h
->
sense
);
err
=
mode_select_handle_sense
(
sdev
,
h
->
sense
);
if
(
err
==
SCSI_DH_RETRY
&&
retry_cnt
--
)
if
(
err
==
SCSI_DH_RETRY
&&
retry_cnt
--
)
goto
retry
;
goto
retry
;
if
(
err
==
SCSI_DH_IMM_RETRY
)
goto
retry
;
}
}
if
(
err
==
SCSI_DH_OK
)
{
if
(
err
==
SCSI_DH_OK
)
{
h
->
state
=
RDAC_STATE_ACTIVE
;
h
->
state
=
RDAC_STATE_ACTIVE
;
...
...
drivers/scsi/hisi_sas/Kconfig
View file @
12ffbbe9
config SCSI_HISI_SAS
config SCSI_HISI_SAS
tristate "HiSilicon SAS"
tristate "HiSilicon SAS"
depends on HAS_DMA
depends on HAS_DMA
&& HAS_IOMEM
depends on ARM64 || COMPILE_TEST
depends on ARM64 || COMPILE_TEST
select SCSI_SAS_LIBSAS
select SCSI_SAS_LIBSAS
select BLK_DEV_INTEGRITY
select BLK_DEV_INTEGRITY
...
...
drivers/scsi/hisi_sas/hisi_sas_v1_hw.c
View file @
12ffbbe9
...
@@ -1289,13 +1289,10 @@ static int slot_complete_v1_hw(struct hisi_hba *hisi_hba,
...
@@ -1289,13 +1289,10 @@ static int slot_complete_v1_hw(struct hisi_hba *hisi_hba,
goto
out
;
goto
out
;
}
}
if
(
cmplt_hdr_data
&
CMPLT_HDR_ERR_RCRD_XFRD_MSK
)
{
if
(
cmplt_hdr_data
&
CMPLT_HDR_ERR_RCRD_XFRD_MSK
&&
if
(
!
(
cmplt_hdr_data
&
CMPLT_HDR_CMD_CMPLT_MSK
)
||
!
(
cmplt_hdr_data
&
CMPLT_HDR_RSPNS_XFRD_MSK
))
{
!
(
cmplt_hdr_data
&
CMPLT_HDR_RSPNS_XFRD_MSK
))
ts
->
stat
=
SAS_DATA_OVERRUN
;
else
slot_err_v1_hw
(
hisi_hba
,
task
,
slot
);
slot_err_v1_hw
(
hisi_hba
,
task
,
slot
);
goto
out
;
goto
out
;
}
}
...
...
drivers/scsi/scsi_devinfo.c
View file @
12ffbbe9
...
@@ -205,6 +205,7 @@ static struct {
...
@@ -205,6 +205,7 @@ static struct {
{
"Intel"
,
"Multi-Flex"
,
NULL
,
BLIST_NO_RSOC
},
{
"Intel"
,
"Multi-Flex"
,
NULL
,
BLIST_NO_RSOC
},
{
"iRiver"
,
"iFP Mass Driver"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
{
"iRiver"
,
"iFP Mass Driver"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
{
"LASOUND"
,
"CDX7405"
,
"3.10"
,
BLIST_MAX5LUN
|
BLIST_SINGLELUN
},
{
"LASOUND"
,
"CDX7405"
,
"3.10"
,
BLIST_MAX5LUN
|
BLIST_SINGLELUN
},
{
"Marvell"
,
"Console"
,
NULL
,
BLIST_SKIP_VPD_PAGES
},
{
"MATSHITA"
,
"PD-1"
,
NULL
,
BLIST_FORCELUN
|
BLIST_SINGLELUN
},
{
"MATSHITA"
,
"PD-1"
,
NULL
,
BLIST_FORCELUN
|
BLIST_SINGLELUN
},
{
"MATSHITA"
,
"DMC-LC5"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
{
"MATSHITA"
,
"DMC-LC5"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
{
"MATSHITA"
,
"DMC-LC40"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
{
"MATSHITA"
,
"DMC-LC40"
,
NULL
,
BLIST_NOT_LOCKABLE
|
BLIST_INQUIRY_36
},
...
...
drivers/scsi/sd.c
View file @
12ffbbe9
...
@@ -761,7 +761,7 @@ static int sd_setup_discard_cmnd(struct scsi_cmnd *cmd)
...
@@ -761,7 +761,7 @@ static int sd_setup_discard_cmnd(struct scsi_cmnd *cmd)
break
;
break
;
default:
default:
ret
=
BLKPREP_
KILL
;
ret
=
BLKPREP_
INVALID
;
goto
out
;
goto
out
;
}
}
...
@@ -839,7 +839,7 @@ static int sd_setup_write_same_cmnd(struct scsi_cmnd *cmd)
...
@@ -839,7 +839,7 @@ static int sd_setup_write_same_cmnd(struct scsi_cmnd *cmd)
int
ret
;
int
ret
;
if
(
sdkp
->
device
->
no_write_same
)
if
(
sdkp
->
device
->
no_write_same
)
return
BLKPREP_
KILL
;
return
BLKPREP_
INVALID
;
BUG_ON
(
bio_offset
(
bio
)
||
bio_iovec
(
bio
).
bv_len
!=
sdp
->
sector_size
);
BUG_ON
(
bio_offset
(
bio
)
||
bio_iovec
(
bio
).
bv_len
!=
sdp
->
sector_size
);
...
...
drivers/scsi/storvsc_drv.c
View file @
12ffbbe9
...
@@ -42,6 +42,7 @@
...
@@ -42,6 +42,7 @@
#include <scsi/scsi_devinfo.h>
#include <scsi/scsi_devinfo.h>
#include <scsi/scsi_dbg.h>
#include <scsi/scsi_dbg.h>
#include <scsi/scsi_transport_fc.h>
#include <scsi/scsi_transport_fc.h>
#include <scsi/scsi_transport.h>
/*
/*
* All wire protocol details (storage protocol between the guest and the host)
* All wire protocol details (storage protocol between the guest and the host)
...
@@ -477,19 +478,18 @@ struct hv_host_device {
...
@@ -477,19 +478,18 @@ struct hv_host_device {
struct
storvsc_scan_work
{
struct
storvsc_scan_work
{
struct
work_struct
work
;
struct
work_struct
work
;
struct
Scsi_Host
*
host
;
struct
Scsi_Host
*
host
;
uint
lun
;
u8
lun
;
u8
tgt_id
;
};
};
static
void
storvsc_device_scan
(
struct
work_struct
*
work
)
static
void
storvsc_device_scan
(
struct
work_struct
*
work
)
{
{
struct
storvsc_scan_work
*
wrk
;
struct
storvsc_scan_work
*
wrk
;
uint
lun
;
struct
scsi_device
*
sdev
;
struct
scsi_device
*
sdev
;
wrk
=
container_of
(
work
,
struct
storvsc_scan_work
,
work
);
wrk
=
container_of
(
work
,
struct
storvsc_scan_work
,
work
);
lun
=
wrk
->
lun
;
sdev
=
scsi_device_lookup
(
wrk
->
host
,
0
,
0
,
lun
);
sdev
=
scsi_device_lookup
(
wrk
->
host
,
0
,
wrk
->
tgt_id
,
wrk
->
lun
);
if
(
!
sdev
)
if
(
!
sdev
)
goto
done
;
goto
done
;
scsi_rescan_device
(
&
sdev
->
sdev_gendev
);
scsi_rescan_device
(
&
sdev
->
sdev_gendev
);
...
@@ -540,7 +540,7 @@ static void storvsc_remove_lun(struct work_struct *work)
...
@@ -540,7 +540,7 @@ static void storvsc_remove_lun(struct work_struct *work)
if
(
!
scsi_host_get
(
wrk
->
host
))
if
(
!
scsi_host_get
(
wrk
->
host
))
goto
done
;
goto
done
;
sdev
=
scsi_device_lookup
(
wrk
->
host
,
0
,
0
,
wrk
->
lun
);
sdev
=
scsi_device_lookup
(
wrk
->
host
,
0
,
wrk
->
tgt_id
,
wrk
->
lun
);
if
(
sdev
)
{
if
(
sdev
)
{
scsi_remove_device
(
sdev
);
scsi_remove_device
(
sdev
);
...
@@ -940,6 +940,7 @@ static void storvsc_handle_error(struct vmscsi_request *vm_srb,
...
@@ -940,6 +940,7 @@ static void storvsc_handle_error(struct vmscsi_request *vm_srb,
wrk
->
host
=
host
;
wrk
->
host
=
host
;
wrk
->
lun
=
vm_srb
->
lun
;
wrk
->
lun
=
vm_srb
->
lun
;
wrk
->
tgt_id
=
vm_srb
->
target_id
;
INIT_WORK
(
&
wrk
->
work
,
process_err_fn
);
INIT_WORK
(
&
wrk
->
work
,
process_err_fn
);
schedule_work
(
&
wrk
->
work
);
schedule_work
(
&
wrk
->
work
);
}
}
...
@@ -1770,6 +1771,11 @@ static int __init storvsc_drv_init(void)
...
@@ -1770,6 +1771,11 @@ static int __init storvsc_drv_init(void)
fc_transport_template
=
fc_attach_transport
(
&
fc_transport_functions
);
fc_transport_template
=
fc_attach_transport
(
&
fc_transport_functions
);
if
(
!
fc_transport_template
)
if
(
!
fc_transport_template
)
return
-
ENODEV
;
return
-
ENODEV
;
/*
* Install Hyper-V specific timeout handler.
*/
fc_transport_template
->
eh_timed_out
=
storvsc_eh_timed_out
;
#endif
#endif
ret
=
vmbus_driver_register
(
&
storvsc_drv
);
ret
=
vmbus_driver_register
(
&
storvsc_drv
);
...
...
include/linux/blkdev.h
View file @
12ffbbe9
...
@@ -682,9 +682,12 @@ static inline bool blk_write_same_mergeable(struct bio *a, struct bio *b)
...
@@ -682,9 +682,12 @@ static inline bool blk_write_same_mergeable(struct bio *a, struct bio *b)
/*
/*
* q->prep_rq_fn return values
* q->prep_rq_fn return values
*/
*/
#define BLKPREP_OK 0
/* serve it */
enum
{
#define BLKPREP_KILL 1
/* fatal error, kill */
BLKPREP_OK
,
/* serve it */
#define BLKPREP_DEFER 2
/* leave on queue */
BLKPREP_KILL
,
/* fatal error, kill, return -EIO */
BLKPREP_DEFER
,
/* leave on queue */
BLKPREP_INVALID
,
/* invalid command, kill, return -EREMOTEIO */
};
extern
unsigned
long
blk_max_low_pfn
,
blk_max_pfn
;
extern
unsigned
long
blk_max_low_pfn
,
blk_max_pfn
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment