]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[stp] Fix incorrectly disambiguated errors
authorMichael Brown <mcb30@ipxe.org>
Thu, 14 Jan 2016 12:39:01 +0000 (12:39 +0000)
committerMichael Brown <mcb30@ipxe.org>
Thu, 14 Jan 2016 12:39:35 +0000 (12:39 +0000)
The three nominally-disambiguated ENOTSUP errors accidentally all used
the same error disambiguator, rendering them identical.  Fix by
changing all three values.  We avoid reusing the 0x01 disambiguator
value, since that remains ambiguous in older binaries.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/net/stp.c

index d4e65a1a2ad93f45fecc2dfb6e067b4428cba540..defdaed9ed351b2d1fe76f7d450ea76202ae5313 100644 (file)
@@ -40,15 +40,15 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
 /* Disambiguate the various error causes */
 #define ENOTSUP_PROTOCOL __einfo_error ( EINFO_ENOTSUP_PROTOCOL )
 #define EINFO_ENOTSUP_PROTOCOL                                 \
-       __einfo_uniqify ( EINFO_ENOTSUP, 0x01,                  \
+       __einfo_uniqify ( EINFO_ENOTSUP, 0x02,                  \
                          "Non-STP packet received" )
 #define ENOTSUP_VERSION __einfo_error ( EINFO_ENOTSUP_VERSION )
 #define EINFO_ENOTSUP_VERSION                                  \
-       __einfo_uniqify ( EINFO_ENOTSUP, 0x01,                  \
+       __einfo_uniqify ( EINFO_ENOTSUP, 0x03,                  \
                          "Legacy STP packet received" )
 #define ENOTSUP_TYPE __einfo_error ( EINFO_ENOTSUP_TYPE )
 #define EINFO_ENOTSUP_TYPE                                     \
-       __einfo_uniqify ( EINFO_ENOTSUP, 0x01,                  \
+       __einfo_uniqify ( EINFO_ENOTSUP, 0x04,                  \
                          "Non-RSTP packet received" )
 
 /**