]>
Commit | Line | Data |
---|---|---|
6a930a95 BS |
1 | From: Yi Zou <yi.zou@intel.com> |
2 | Subject: [FcOE] check return for fc_set_mfs | |
3 | References: bnc #459142 | |
4 | ||
5 | Signed-off-by: Yi Zou <yi.zou@intel.com> | |
6 | Acked-by: Bernhard Walle <bwalle@suse.de> | |
7 | --- | |
8 | ||
9 | drivers/scsi/fcoe/fcoe_sw.c | 3 ++- | |
10 | 1 file changed, 2 insertions(+), 1 deletion(-) | |
11 | ||
12 | ||
13 | --- a/drivers/scsi/fcoe/fcoe_sw.c | |
14 | +++ b/drivers/scsi/fcoe/fcoe_sw.c | |
15 | @@ -178,7 +178,8 @@ static int fcoe_sw_netdev_config(struct | |
16 | */ | |
17 | mfs = fc->real_dev->mtu - (sizeof(struct fcoe_hdr) + | |
18 | sizeof(struct fcoe_crc_eof)); | |
19 | - fc_set_mfs(lp, mfs); | |
20 | + if (fc_set_mfs(lp, mfs)) | |
21 | + return -EINVAL; | |
22 | ||
23 | lp->link_status = ~FC_PAUSE & ~FC_LINK_UP; | |
24 | if (!fcoe_link_ok(lp)) |