mirror of https://github.com/PCSX2/pcsx2.git
FW: clang-format
This commit is contained in:
parent
385c698212
commit
6f98fd4b65
|
@ -570,7 +570,6 @@ Global
|
|||
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
|
||||
{E4081455-398C-4610-A87C-90A8A7D72DC3} = {703FD00B-D7A0-41E3-BD03-CEC86B385DAF}
|
||||
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}
|
||||
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}
|
||||
{04439C5F-05FB-4A9C-AAD1-5388C25377DB} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}
|
||||
{A51123F5-9505-4EAE-85E7-D320290A272C} = {88F517F9-CE1C-4005-9BDF-4481FEB55053}
|
||||
{4639972E-424E-4E13-8B07-CA403C481346} = {88F517F9-CE1C-4005-9BDF-4481FEB55053}
|
||||
|
|
19
pcsx2/FW.cpp
19
pcsx2/FW.cpp
|
@ -13,6 +13,8 @@
|
|||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "PrecompiledHeader.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string>
|
||||
using namespace std;
|
||||
|
@ -20,7 +22,7 @@ using namespace std;
|
|||
#include "FW.h"
|
||||
|
||||
u8 phyregs[16];
|
||||
s8 *fwregs;
|
||||
s8* fwregs;
|
||||
|
||||
void (*FWirq)();
|
||||
|
||||
|
@ -28,8 +30,9 @@ s32 FWopen()
|
|||
{
|
||||
memset(phyregs, 0, sizeof(phyregs));
|
||||
// Initializing our registers.
|
||||
fwregs = (s8 *)calloc(0x10000, 1);
|
||||
if (fwregs == NULL) {
|
||||
fwregs = (s8*)calloc(0x10000, 1);
|
||||
if (fwregs == NULL)
|
||||
{
|
||||
DevCon.WriteLn("FW: Error allocating Memory");
|
||||
return -1;
|
||||
}
|
||||
|
@ -41,7 +44,6 @@ void FWclose()
|
|||
// Freeing the registers.
|
||||
free(fwregs);
|
||||
fwregs = NULL;
|
||||
|
||||
}
|
||||
|
||||
void PHYWrite()
|
||||
|
@ -73,7 +75,8 @@ u32 FWread32(u32 addr)
|
|||
{
|
||||
u32 ret = 0;
|
||||
|
||||
switch (addr) {
|
||||
switch (addr)
|
||||
{
|
||||
//Node ID Register the top part is default, bottom part i got from my ps2
|
||||
case 0x1f808400:
|
||||
ret = /*(0x3ff << 22) | 1;*/ 0xffc00001;
|
||||
|
@ -107,7 +110,8 @@ u32 FWread32(u32 addr)
|
|||
|
||||
void FWwrite32(u32 addr, u32 value)
|
||||
{
|
||||
switch (addr) {
|
||||
switch (addr)
|
||||
{
|
||||
// Include other memory locations we want to catch here.
|
||||
// For example:
|
||||
//
|
||||
|
@ -126,7 +130,8 @@ void FWwrite32(u32 addr, u32 value)
|
|||
if (value & 0x40000000) //Writing to PHY
|
||||
{
|
||||
PHYWrite();
|
||||
} else if (value & 0x80000000) //Reading from PHY
|
||||
}
|
||||
else if (value & 0x80000000) //Reading from PHY
|
||||
{
|
||||
PHYRead();
|
||||
}
|
||||
|
|
|
@ -20,9 +20,9 @@
|
|||
#define FWdefs
|
||||
|
||||
// Our main memory storage, and defines for accessing it.
|
||||
extern s8 *fwregs;
|
||||
#define fwRs32(mem) (*(s32 *)&fwregs[(mem)&0xffff])
|
||||
#define fwRu32(mem) (*(u32 *)&fwregs[(mem)&0xffff])
|
||||
extern s8* fwregs;
|
||||
#define fwRs32(mem) (*(s32*)&fwregs[(mem)&0xffff])
|
||||
#define fwRu32(mem) (*(u32*)&fwregs[(mem)&0xffff])
|
||||
|
||||
//PHY Access Address for ease of use :P
|
||||
#define PHYACC fwRu32(0x8414)
|
||||
|
|
|
@ -154,6 +154,9 @@
|
|||
<Filter Include="System\Ps2\Iop\CDVD\Linux">
|
||||
<UniqueIdentifier>{a5904fb6-e846-4cbf-940c-ca1c604140a0}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="System\Ps2\Iop\FW">
|
||||
<UniqueIdentifier>{157740ae-b338-4d7f-81cb-cffa9d39a756}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="..\..\Utilities\folderdesc.txt">
|
||||
|
@ -893,7 +896,7 @@
|
|||
<Filter>System</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\FW.cpp">
|
||||
<Filter>System</Filter>
|
||||
<Filter>System\Ps2\Iop\FW</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
@ -1354,7 +1357,7 @@
|
|||
<Filter>System\Include</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\FW.h">
|
||||
<Filter>System\Include</Filter>
|
||||
<Filter>System\Ps2\Iop\FW</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
|
Loading…
Reference in New Issue