Skip to content

Commit e71ad13

Browse files
Mario Hrosmarcan
authored andcommitted
chickens: Add preliminary T6020 support
Signed-off-by: Mario Hros <[email protected]>
1 parent afb68db commit e71ad13

3 files changed

Lines changed: 39 additions & 0 deletions

File tree

src/chickens.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
#define MIDR_PART_T8110_AVALANCHE 0x31
1919
#define MIDR_PART_T8112_BLIZZARD 0x32
2020
#define MIDR_PART_T8112_AVALANCHE 0x33
21+
#define MIDR_PART_T6020_BLIZZARD 0x34
22+
#define MIDR_PART_T6020_AVALANCHE 0x35
2123
#define MIDR_PART_T6021_BLIZZARD 0x38
2224
#define MIDR_PART_T6021_AVALANCHE 0x39
2325

@@ -31,6 +33,8 @@ void init_t6000_firestorm(int rev);
3133
void init_t6001_firestorm(int rev);
3234
void init_t8112_blizzard(void);
3335
void init_t8112_avalanche(int rev);
36+
void init_t6020_blizzard(void);
37+
void init_t6020_avalanche(int rev);
3438
void init_t6021_blizzard(void);
3539
void init_t6021_avalanche(int rev);
3640

@@ -93,6 +97,16 @@ const char *init_cpu(void)
9397
init_t8112_blizzard();
9498
break;
9599

100+
case MIDR_PART_T6020_AVALANCHE:
101+
cpu = "M2 Pro Avalanche";
102+
init_t6020_avalanche(rev);
103+
break;
104+
105+
case MIDR_PART_T6020_BLIZZARD:
106+
cpu = "M2 Pro Blizzard";
107+
init_t6020_blizzard();
108+
break;
109+
96110
case MIDR_PART_T6021_AVALANCHE:
97111
cpu = "M2 Max Avalanche";
98112
init_t6021_avalanche(rev);

src/chickens_avalanche.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,20 @@ void init_t8112_avalanche(int rev)
5151
}
5252
}
5353

54+
void init_t6020_avalanche(int rev)
55+
{
56+
UNUSED(rev);
57+
58+
init_common_avalanche();
59+
60+
reg_mask(SYS_IMP_APL_HID3, HID3_DEV_PCIE_THROTTLE_LIMIT_MASK, HID3_DEV_PCIE_THROTTLE_LIMIT(62));
61+
reg_set(SYS_IMP_APL_HID3, HID3_DEV_PCIE_THROTTLE_ENABLE);
62+
reg_set(SYS_IMP_APL_HID18, HID18_AVL_UNK27 | HID18_AVL_UNK29);
63+
reg_set(SYS_IMP_APL_HID16, HID16_AVL_UNK12);
64+
65+
reg_mask(SYS_IMP_APL_HID5, HID5_BLZ_UNK_19_18_MASK, HID5_BLZ_UNK18);
66+
}
67+
5468
void init_t6021_avalanche(int rev)
5569
{
5670
UNUSED(rev);

src/chickens_blizzard.c

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,17 @@ void init_t8112_blizzard(void)
1717
reg_set(SYS_IMP_APL_EHID18, EHID18_BLZ_UNK34);
1818
}
1919

20+
void init_t6020_blizzard(void)
21+
{
22+
init_common_blizzard();
23+
24+
reg_mask(SYS_IMP_APL_EHID9, EHID9_DEV_2_THROTTLE_LIMIT_MASK, EHID9_DEV_2_THROTTLE_LIMIT(62));
25+
reg_set(SYS_IMP_APL_EHID9, EHID9_DEV_2_THROTTLE_ENABLE);
26+
reg_set(SYS_IMP_APL_EHID18, EHID18_BLZ_UNK34);
27+
28+
reg_mask(SYS_IMP_APL_HID5, HID5_BLZ_UNK_19_18_MASK, HID5_BLZ_UNK18);
29+
}
30+
2031
void init_t6021_blizzard(void)
2132
{
2233
init_common_blizzard();

0 commit comments

Comments
 (0)