- Timestamp:
- Feb 6, 2013 1:57:03 PM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 83633
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Network/DevE1000Phy.cpp
r44529 r44565 11 11 12 12 /* 13 * Copyright (C) 2007-201 0Oracle Corporation13 * Copyright (C) 2007-2013 Oracle Corporation 14 14 * 15 15 * This file is part of VirtualBox Open Source Edition (OSE), as … … 40 40 # define SSMR3PutMem(a,b,c) 41 41 # define SSMR3GetMem(a,b,c) 42 # include <stdio.h>42 # include <stdio.h> 43 43 # define PhyLog(a) printf a 44 44 #else /* PHY_UNIT_TEST */ … … 58 58 static void softReset(PPHY pPhy); 59 59 60 /* Generic handlers ******************************************************/ 60 /** @name Generic handlers 61 * @{ */ 61 62 static uint16_t regReadDefault (PPHY pPhy, uint32_t index); 62 63 static void regWriteDefault (PPHY pPhy, uint32_t index, uint16_t u16Value); … … 65 66 static uint16_t regReadUnimplemented (PPHY pPhy, uint32_t index); 66 67 static void regWriteUnimplemented(PPHY pPhy, uint32_t index, uint16_t u16Value); 67 /* Register-specific handlers ********************************************/ 68 /** @} */ 69 /** @name Register-specific handlers 70 * @{ */ 68 71 static void regWritePCTRL (PPHY pPhy, uint32_t index, uint16_t u16Value); 69 72 static uint16_t regReadPSTATUS (PPHY pPhy, uint32_t index); 70 73 static uint16_t regReadGSTATUS (PPHY pPhy, uint32_t index); 74 /** @} */ 71 75 72 76 /** … … 84 88 void (*pfnWrite)(PPHY pPhy, uint32_t index, uint16_t u16Value); 85 89 /** Abbreviated name. */ 86 const char * szAbbrev;90 const char *pszAbbrev; 87 91 /** Full name. */ 88 const char * szName;92 const char *pszName; 89 93 } s_regMap[NUM_OF_PHY_REGS] = 90 94 { … … 156 160 { 157 161 PhyLog(("PHY#%d At %02d read attempted from write-only '%s'\n", 158 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index]. szName));162 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index].pszName)); 159 163 return 0; 160 164 } … … 171 175 { 172 176 PhyLog(("PHY#%d At %02d write attempted to read-only '%s'\n", 173 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index]. szName));177 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index].pszName)); 174 178 } 175 179 … … 186 190 { 187 191 PhyLog(("PHY#%d At %02d read attempted from unimplemented '%s'\n", 188 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index]. szName));192 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index].pszName)); 189 193 return 0; 190 194 } … … 201 205 { 202 206 PhyLog(("PHY#%d At %02d write attempted to unimplemented '%s'\n", 203 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index]. szName));207 pPhy->iInstance, s_regMap[index].u32Address, s_regMap[index].pszName)); 204 208 } 205 209 … … 244 248 PhyLog(("PHY#%d At %02d read %04X from %s (%s)\n", 245 249 pPhy->iInstance, s_regMap[index].u32Address, u16, 246 s_regMap[index]. szAbbrev, s_regMap[index].szName));250 s_regMap[index].pszAbbrev, s_regMap[index].pszName)); 247 251 } 248 252 else … … 268 272 PhyLog(("PHY#%d At %02d write %04X to %s (%s)\n", 269 273 pPhy->iInstance, s_regMap[index].u32Address, u16Value, 270 s_regMap[index]. szAbbrev, s_regMap[index].szName));274 s_regMap[index].pszAbbrev, s_regMap[index].pszName)); 271 275 s_regMap[index].pfnWrite(pPhy, index, u16Value); 272 276 } … … 374 378 375 379 #ifdef IN_RING3 380 376 381 /** 377 382 * Save PHY state. … … 404 409 return SSMR3GetMem(pSSMHandle, pPhy->au16Regs, sizeof(pPhy->au16Regs)); 405 410 } 411 406 412 #endif /* IN_RING3 */ 407 413
Note:
See TracChangeset
for help on using the changeset viewer.