diff options
| author | Dale Ghent <daleg@omniti.com> | 2016-02-03 17:58:20 -0500 |
|---|---|---|
| committer | Robert Mustacchi <rm@joyent.com> | 2016-02-05 12:22:06 -0800 |
| commit | 238d8f47d92b5b99a374f9639e0704420d3aef77 (patch) | |
| tree | f68ddbe22369810f1720ee9a1944d979acd1a102 /usr/src | |
| parent | 4870e0a7381ec2ec57437062574e6ddc3dd48d7f (diff) | |
| download | illumos-joyent-238d8f47d92b5b99a374f9639e0704420d3aef77.tar.gz | |
6601 Various GLD drivers return EINVAL instead of ENOTSUP for unused mac_prop_id_t's
Reviewed by: Garrett D'Amore <garrett@damore.org>
Reviewed by: Dan McDonald <danmcd@omniti.com>
Reviewed by: Igor Kozhukhov <ikozhukhov@gmail.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Diffstat (limited to 'usr/src')
| -rw-r--r-- | usr/src/uts/common/io/hxge/hxge_main.c | 7 | ||||
| -rw-r--r-- | usr/src/uts/common/io/igb/igb_gld.c | 5 | ||||
| -rw-r--r-- | usr/src/uts/common/io/ixgbe/ixgbe_gld.c | 5 | ||||
| -rw-r--r-- | usr/src/uts/common/io/nxge/nxge_main.c | 5 | ||||
| -rw-r--r-- | usr/src/uts/common/io/vnic/vnic_dev.c | 3 |
5 files changed, 15 insertions, 10 deletions
diff --git a/usr/src/uts/common/io/hxge/hxge_main.c b/usr/src/uts/common/io/hxge/hxge_main.c index 12e43ecedb..102b7cb285 100644 --- a/usr/src/uts/common/io/hxge/hxge_main.c +++ b/usr/src/uts/common/io/hxge/hxge_main.c @@ -22,6 +22,7 @@ * Copyright 2010 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. * Copyright 2012 Milan Jurik. All rights reserved. + * Copyright 2016 OmniTI Computer Consulting, Inc. All rights reserved. */ /* @@ -3321,7 +3322,7 @@ hxge_m_getprop(void *barg, const char *pr_name, mac_prop_id_t pr_num, break; default: - err = EINVAL; + err = ENOTSUP; break; } @@ -3433,7 +3434,7 @@ hxge_set_priv_prop(p_hxge_t hxgep, const char *pr_name, uint_t pr_valsize, err = hxge_param_set_ip_opt(hxgep, NULL, NULL, (char *)pr_val, (caddr_t)¶m_arr[param_class_opt_ipv6_sctp]); } else { - err = EINVAL; + err = ENOTSUP; } HXGE_DEBUG_MSG((hxgep, DLADM_CTL, @@ -3503,7 +3504,7 @@ hxge_get_priv_prop(p_hxge_t hxgep, const char *pr_name, uint_t pr_valsize, value = (int)param_arr[param_class_opt_ipv6_sctp].value; } else { - err = EINVAL; + err = ENOTSUP; } if (err == 0) { diff --git a/usr/src/uts/common/io/igb/igb_gld.c b/usr/src/uts/common/io/igb/igb_gld.c index a97dc5aee1..d754c79949 100644 --- a/usr/src/uts/common/io/igb/igb_gld.c +++ b/usr/src/uts/common/io/igb/igb_gld.c @@ -27,6 +27,7 @@ * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2013, Nexenta Systems, Inc. All rights reserved. * Copyright 2014 Pluribus Networks Inc. + * Copyright 2016 OmniTI Computer Consulting, Inc. All rights reserved. */ #include "igb_sw.h" @@ -1116,7 +1117,7 @@ setup_link: err = igb_set_priv_prop(igb, pr_name, pr_valsize, pr_val); break; default: - err = EINVAL; + err = ENOTSUP; break; } @@ -1218,7 +1219,7 @@ igb_m_getprop(void *arg, const char *pr_name, mac_prop_id_t pr_num, err = igb_get_priv_prop(igb, pr_name, pr_valsize, pr_val); break; default: - err = EINVAL; + err = ENOTSUP; break; } return (err); diff --git a/usr/src/uts/common/io/ixgbe/ixgbe_gld.c b/usr/src/uts/common/io/ixgbe/ixgbe_gld.c index bfce23ddd9..4501451d99 100644 --- a/usr/src/uts/common/io/ixgbe/ixgbe_gld.c +++ b/usr/src/uts/common/io/ixgbe/ixgbe_gld.c @@ -26,6 +26,7 @@ /* * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2012 Nexenta Systems, Inc. All rights reserved. + * Copyright 2016 OmniTI Computer Consulting, Inc. All rights reserved. */ #include "ixgbe_sw.h" @@ -431,7 +432,7 @@ setup_link: err = ixgbe_set_priv_prop(ixgbe, pr_name, pr_valsize, pr_val); break; default: - err = EINVAL; + err = ENOTSUP; break; } mutex_exit(&ixgbe->gen_lock); @@ -504,7 +505,7 @@ ixgbe_m_getprop(void *arg, const char *pr_name, mac_prop_id_t pr_num, pr_valsize, pr_val); break; default: - err = EINVAL; + err = ENOTSUP; break; } return (err); diff --git a/usr/src/uts/common/io/nxge/nxge_main.c b/usr/src/uts/common/io/nxge/nxge_main.c index e07682c932..a2ef343c76 100644 --- a/usr/src/uts/common/io/nxge/nxge_main.c +++ b/usr/src/uts/common/io/nxge/nxge_main.c @@ -20,6 +20,7 @@ */ /* * Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright 2016 OmniTI Computer Consulting, Inc. All rights reserved. */ /* @@ -5136,7 +5137,7 @@ nxge_set_priv_prop(p_nxge_t nxgep, const char *pr_name, uint_t pr_valsize, return (err); } - return (EINVAL); + return (ENOTSUP); } static int @@ -5145,7 +5146,7 @@ nxge_get_priv_prop(p_nxge_t nxgep, const char *pr_name, uint_t pr_valsize, { p_nxge_param_t param_arr = nxgep->param_arr; char valstr[MAXNAMELEN]; - int err = EINVAL; + int err = ENOTSUP; uint_t strsize; NXGE_DEBUG_MSG((nxgep, NXGE_CTL, diff --git a/usr/src/uts/common/io/vnic/vnic_dev.c b/usr/src/uts/common/io/vnic/vnic_dev.c index a01e11b964..3cacbe395b 100644 --- a/usr/src/uts/common/io/vnic/vnic_dev.c +++ b/usr/src/uts/common/io/vnic/vnic_dev.c @@ -21,6 +21,7 @@ /* * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2015 Joyent, Inc. + * Copyright 2016 OmniTI Computer Consulting, Inc. All rights reserved. */ #include <sys/types.h> @@ -1098,7 +1099,7 @@ vnic_m_getprop(void *arg, const char *pr_name, mac_prop_id_t pr_num, ret = vnic_get_secondary_macs(vn, pr_valsize, pr_val); break; default: - ret = EINVAL; + ret = ENOTSUP; break; } |
