changeset 2b5fbdcbfb5d in /z/repo/m5
details: http://repo.m5sim.org/m5?cmd=changeset;node=2b5fbdcbfb5d
description:
        IGbE: return 0 on an invalid descriptor size instead of -1.

        Asserts where descSize() get called with assert if we end up returning
        0.

diffstat:

 src/dev/i8254xGBe_defs.hh |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (18 lines):

diff -r 6a7207241112 -r 2b5fbdcbfb5d src/dev/i8254xGBe_defs.hh
--- a/src/dev/i8254xGBe_defs.hh Tue Nov 23 17:08:41 2010 -0500
+++ b/src/dev/i8254xGBe_defs.hh Fri Nov 26 20:47:23 2010 -0500
@@ -484,12 +484,12 @@
         unsigned descSize()
         {
             switch(bsize()) {
-                case 0: return bsex() == 0 ? 2048 : -1;
+                case 0: return bsex() == 0 ? 2048 : 0;
                 case 1: return bsex() == 0 ? 1024 : 16384;
                 case 2: return bsex() == 0 ? 512 : 8192;
                 case 3: return bsex() == 0 ? 256 : 4096;
                 default:
-                        return -1;
+                        return 0;
             }
         }
     };
_______________________________________________
m5-dev mailing list
m5-dev@m5sim.org
http://m5sim.org/mailman/listinfo/m5-dev

Reply via email to