5.15.226-rc1 review
Subsystems (7)
Greg Kroah-Hartman
maintainerPATCH 109/2214 misc: ibmvmc: reject oversized inbound messages
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yousef Alhouseen <[email protected]>
[ Upstream commit 18189e5d84aa0b3bc89189cba13b9105634cb6fb ]
ibmvmc_recv_msg() trusts the message length from the CRQ.
It passes that length directly to h_copy_rdma().
The destination buffer is only max_mtu bytes.
A larger length can overrun it before userspace reads the message.
Validate the CRQ length before issuing the RDMA copy.
--- drivers/misc/ibmvmc.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/misc/ibmvmc.c +7 -0
@@ -1653,6 +1653,13 @@ static int ibmvmc_recv_msg(struct crq_server_adapter *adapter,return -1 ; } +if (msg_len > buffer->size) { +dev_err (adapter->dev,"Recv_msg: msg_len 0x%lx exceeds buffer size 0x%x\n" , + msg_len, buffer->size); +spin_unlock_irqrestore (&hmc->lock, flags); +return -1 ; + } +/* RDMA the data into the partition. */ rc = h_copy_rdma(msg_len, adapter->riobn,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 110/2214 driver core: attribute_container: Unwind device_add() on attr failure
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yuho Choi <[email protected]>
[ Upstream commit 8cfe7ad274bb42c4653b645267410d4a3a23db98 ]
attribute_container_add_class_device() first calls device_add() and then creates the container attributes. If attribute_container_add_attrs() fails, the helper returns the error with the class device still registered.
Callers use an error from this helper as a failed add and do not call device_del() on that path. Undo the successful device_add() before returning the attribute creation error.
--- drivers/base/attribute_container.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/base/attribute_container.c +6 -1
@@ -455,7 +455,12 @@ attribute_container_add_class_device(struct device *classdev)if (error)return error; -return attribute_container_add_attrs (classdev); + + error =attribute_container_add_attrs (classdev); +if (error) +device_del (classdev); + +return error; }/**
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 111/2214 media: dvb-core: fix feed leak on failed DMX_ADD_PID
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rituparna Warwatkar <[email protected]>
[ Upstream commit 9fa26c971ca310dd10a3bc0014f2fc7ea7167bba ]
dvb_dmxdev_add_pid() allocates a new dmxdev_feed, links it into filter->feed.ts and, when the filter is already running, immediately starts the feed.
If starting the feed fails, the newly allocated feed remains on the list. Subsequent restart and rollback paths may then operate on this stale entry, leaving feed resources allocated and causing leaks in drivers that allocate resources from ->start_feed() and release them from ->stop_feed().
Remove the feed from the list and free it whendvb_dmxdev_start_feed() fails.
Message-ID: <[email protected]>
--- drivers/media/dvb-core/dmxdev.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)
drivers/media/dvb-core/dmxdev.c +9 -2
@@ -880,6 +880,7 @@ static int dvb_dmxdev_add_pid(struct dmxdev *dmxdev, struct dmxdev_filter *filter, u16 pid) {struct dmxdev_feed *feed; +int ret;if ((filter->type !=DMXDEV_TYPE_PES ) || (filter->state <DMXDEV_STATE_SET ))
@@ -897,8 +898,14 @@ static int dvb_dmxdev_add_pid(struct dmxdev *dmxdev, feed->pid = pid;list_add (&feed->next, &filter->feed.ts); -if (filter->state >=DMXDEV_STATE_GO ) -return dvb_dmxdev_start_feed (dmxdev, filter, feed); +if (filter->state >=DMXDEV_STATE_GO ) { + ret =dvb_dmxdev_start_feed (dmxdev, filter, feed); +if (ret <0 ) { +list_del (&feed->next); +kfree (feed); +return ret; + } + }return 0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 112/2214 media: go7007: s2250: propagate control I/O failures
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yousef Alhouseen <[email protected]>
[ Upstream commit 59dc14a6cb5ff1ae5ce2f6ebf51fe0139e1c0623 ]
The brightness and contrast paths use oldvalue after read_reg_fp() without checking whether the read succeeded. A failed read leaves oldvalue uninitialized and can write arbitrary reserved register bits.
Return read and write errors from every control path so failed hardware access cannot be reported as a successful control update.
--- drivers/media/usb/go7007/s2250-board.c | 54 ++++++++++++++++---------- 1 file changed, 33 insertions(+), 21 deletions(-)
drivers/media/usb/go7007/s2250-board.c +33 -21
@@ -365,36 +365,48 @@ static int s2250_s_ctrl(struct v4l2_ctrl *ctrl) struct s2250 *state = container_of(ctrl->handler, struct s2250, hdl);struct i2c_client *client =v4l2_get_subdevdata (&state->sd);u16 oldvalue; +int ret;switch (ctrl->id) {case V4L2_CID_BRIGHTNESS : -read_reg_fp (client,VPX322_ADDR_BRIGHTNESS0 , &oldvalue); -write_reg_fp (client,VPX322_ADDR_BRIGHTNESS0 , - ctrl->val | (oldvalue & ~0xff )); -read_reg_fp (client,VPX322_ADDR_BRIGHTNESS1 , &oldvalue); -write_reg_fp (client,VPX322_ADDR_BRIGHTNESS1 , - ctrl->val | (oldvalue & ~0xff )); -write_reg_fp (client,0x140 ,0x60 ); -break ; + ret =read_reg_fp (client,VPX322_ADDR_BRIGHTNESS0 , &oldvalue); +if (ret) +return ret; + ret =write_reg_fp (client,VPX322_ADDR_BRIGHTNESS0 , + ctrl->val | (oldvalue & ~0xff )); +if (ret) +return ret; + ret =read_reg_fp (client,VPX322_ADDR_BRIGHTNESS1 , &oldvalue); +if (ret) +return ret; + ret =write_reg_fp (client,VPX322_ADDR_BRIGHTNESS1 , + ctrl->val | (oldvalue & ~0xff )); +if (ret) +return ret; +return write_reg_fp (client,0x140 ,0x60 );case V4L2_CID_CONTRAST : -read_reg_fp (client,VPX322_ADDR_CONTRAST0 , &oldvalue); -write_reg_fp (client,VPX322_ADDR_CONTRAST0 , - ctrl->val | (oldvalue & ~0x3f )); -read_reg_fp (client,VPX322_ADDR_CONTRAST1 , &oldvalue); -write_reg_fp (client,VPX322_ADDR_CONTRAST1 , - ctrl->val | (oldvalue & ~0x3f )); -write_reg_fp (client,0x140 ,0x60 ); -break ; + ret =read_reg_fp (client,VPX322_ADDR_CONTRAST0 , &oldvalue); +if (ret) +return ret; + ret =write_reg_fp (client,VPX322_ADDR_CONTRAST0 , + ctrl->val | (oldvalue & ~0x3f )); +if (ret) +return ret; + ret =read_reg_fp (client,VPX322_ADDR_CONTRAST1 , &oldvalue); +if (ret) +return ret; + ret =write_reg_fp (client,VPX322_ADDR_CONTRAST1 , + ctrl->val | (oldvalue & ~0x3f )); +if (ret) +return ret; +return write_reg_fp (client,0x140 ,0x60 );case V4L2_CID_SATURATION : -write_reg_fp (client,VPX322_ADDR_SAT , ctrl->val); -break ; +return write_reg_fp (client,VPX322_ADDR_SAT , ctrl->val);case V4L2_CID_HUE : -write_reg_fp (client,VPX322_ADDR_HUE , ctrl->val); -break ; +return write_reg_fp (client,VPX322_ADDR_HUE , ctrl->val);default :return -EINVAL ; } -return 0 ; } static int s2250_set_fmt(struct v4l2_subdev *sd,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 113/2214 platform/x86: asus-nb-wmi: map ProArt key (0x8b) to KEY_PROG3
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Nizar Al-Kabbani <[email protected]>
[ Upstream commit 6303451189a6d8f304221065c44ccd597e0acbe5 ]
The dedicated "ProArt" key on the ASUS ProArt PX13 (HN7306) emits ASUS WMI event code 0x8b. This code is absent from the asus-nb-wmi sparse keymap, so pressing the key only produces a "Unknown key code 0x8b" message and does nothing in userspace.
On this model the key is exposed solely through the WMI interface and has no HID scancode, so it can only be handled inside asus-nb-wmi. Map 0x8b to KEY_PROG3 so the key emits a bindable event, consistent with the existing KEY_PROG3 mapping used for the ASUS programmable/Armoury key.
--- drivers/platform/x86/asus-nb-wmi.c | 1 + 1 file changed, 1 insertion(+)
drivers/platform/x86/asus-nb-wmi.c +1 -0
@@ -551,6 +551,7 @@ static const struct key_entry asus_nb_wmi_keymap[] = { { KE_KEY, 0x82, { KEY_CAMERA } }, { KE_KEY, 0x88, { KEY_RFKILL } }, /* Radio Toggle Key */ { KE_KEY, 0x8A, { KEY_PROG1 } }, /* Color enhancement mode */ + { KE_KEY, 0x8B, { KEY_PROG3 } }, /* ProArt key (PX13/HN7306) */ { KE_KEY, 0x8C, { KEY_SWITCHVIDEOMODE } }, /* SDSP DVI only */ { KE_KEY, 0x8D, { KEY_SWITCHVIDEOMODE } }, /* SDSP LCD + DVI */ { KE_KEY, 0x8E, { KEY_SWITCHVIDEOMODE } }, /* SDSP CRT + DVI */
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 114/2214 ACPI: FPDT: validate table and record lengths
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 458b40fcdd04a9a0334830de5a536d8425454e4b ]
FPDT records are supplied by firmware and are walked through length fields stored in the table itself.
Check the main-table entry length before reading an entry, check the mapped subtable length before remapping it, and check each record length before saving a typed record pointer for sysfs.
This keeps malformed firmware records from being interpreted as complete resume, suspend, or boot records when the current item is shorter than the structure consumed by the driver.
--- drivers/acpi/acpi_fpdt.c | 53 +++++++++++++++++++++++++++++++++++----- 1 file changed, 47 insertions(+), 6 deletions(-)
drivers/acpi/acpi_fpdt.c +47 -6
@@ -165,7 +165,7 @@ static int fpdt_process_subtable(u64 address, u32 subtable_type)struct fpdt_subtable_header *subtable_header;struct fpdt_record_header *record_header;char *signature = (subtable_type ==SUBTABLE_FBPT ?"FBPT" :"S3PT" ); -u32 length, offset; +u32 length, offset, remaining;int result;if (!fpdt_address_valid (address)) {
@@ -179,10 +179,17 @@ static int fpdt_process_subtable(u64 address, u32 subtable_type)if (strncmp ((char *)&subtable_header->signature, signature,4 )) {pr_info (FW_BUG "subtable signature and type mismatch!\n" ); +acpi_os_unmap_memory (subtable_header,sizeof (*subtable_header));return -EINVAL ; } length = subtable_header->length; +if (length <sizeof (*subtable_header)) { +pr_err (FW_BUG "Invalid FPDT subtable length %u.\n" , length); +acpi_os_unmap_memory (subtable_header,sizeof (*subtable_header)); +return -EINVAL ; + } +acpi_os_unmap_memory (subtable_header,sizeof (*subtable_header)); subtable_header =acpi_os_map_memory (address, length);
@@ -191,17 +198,29 @@ static int fpdt_process_subtable(u64 address, u32 subtable_type) offset =sizeof (*subtable_header);while (offset < length) { - record_header = (void *)subtable_header + offset; - offset += record_header->length; + remaining = length - offset; +if (remaining <sizeof (*record_header)) { +pr_err (FW_BUG "Truncated FPDT record header.\n" ); + result = -EINVAL ; + goto err; + } -if (!record_header->length) { -pr_err (FW_BUG "Zero-length record found in FPTD.\n" ); + record_header = (void *)subtable_header + offset; +if (record_header->length <sizeof (*record_header) || + record_header->length > remaining) { +pr_err (FW_BUG "Invalid FPDT record length %u.\n" , + record_header->length); result = -EINVAL ; goto err; } + offset += record_header->length;switch (record_header->type) {case RECORD_S3_RESUME : +if (record_header->length <sizeof (*record_resume)) { + result = -EINVAL ; + goto err; + }if (subtable_type !=SUBTABLE_S3PT ) {pr_err (FW_BUG "Invalid record %d for subtable %s\n" , record_header->type, signature);
@@ -218,6 +237,10 @@ static int fpdt_process_subtable(u64 address, u32 subtable_type) goto err;break ;case RECORD_S3_SUSPEND : +if (record_header->length <sizeof (*record_suspend)) { + result = -EINVAL ; + goto err; + }if (subtable_type !=SUBTABLE_S3PT ) {pr_err (FW_BUG "Invalid %d for subtable %s\n" , record_header->type, signature);
@@ -233,6 +256,10 @@ static int fpdt_process_subtable(u64 address, u32 subtable_type) goto err;break ;case RECORD_BOOT : +if (record_header->length <sizeof (*record_boot)) { + result = -EINVAL ; + goto err; + }if (subtable_type !=SUBTABLE_FBPT ) {pr_err (FW_BUG "Invalid %d for subtable %s\n" , record_header->type, signature);
@@ -289,7 +316,21 @@ static int __init acpi_init_fpdt(void) }while (offset < header->length) { +if (header->length - offset <sizeof (*subtable)) { +pr_err (FW_BUG "Truncated FPDT subtable entry.\n" ); + result = -EINVAL ; + goto err_subtable; + } + subtable = (void *)header + offset; +if (subtable->length <sizeof (*subtable) || + subtable->length > header->length - offset) { +pr_err (FW_BUG "Invalid FPDT subtable entry length %u.\n" , + subtable->length); + result = -EINVAL ; + goto err_subtable; + } +switch (subtable->type) {case SUBTABLE_FBPT :case SUBTABLE_S3PT :
@@ -302,7 +343,7 @@ static int __init acpi_init_fpdt(void)/* Other types are reserved in ACPI 6.4 spec. */ break ; } - offset +=sizeof (*subtable); + offset += subtable->length; }return 0 ; err_subtable:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 115/2214 ext4: reduce max cluster size to match documented 256MB limit
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Baokun Li <[email protected]>
[ Upstream commit afa3caf2fbc417f755f36e271c4b3c2d45ccda9d ]
The mke2fs man page documents:
Valid cluster-size values are from 2048 to 256M bytes per cluster.
but EXT4_MAX_CLUSTER_LOG_SIZE was set to 30 (1GB), allowing crafted filesystem images to specify cluster sizes up to 1GB.
On 32-bit systems with bigalloc enabled, the consistency check in ext4_handle_clustersize():
s_blocks_per_group == s_clusters_per_group * (clustersize / blocksize)
can overflow when the cluster ratio is large enough. Since s_blocks_per_group is not range-checked in the bigalloc path, the wrapped product can pass the consistency check, leading to inconsistent group geometry and potential out-of-bounds block allocation.
Reduce EXT4_MAX_CLUSTER_LOG_SIZE to 28 to match the documented 256MB limit. With this cap, the maximum product is:
(blocksize * 8) * (256M / blocksize) = 2^31
which fits safely in a 32-bit unsigned long for all block sizes.
--- fs/ext4/ext4.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/ext4/ext4.h +1 -1
@@ -279,7 +279,7 @@ struct ext4_io_submit {#define EXT4_MAX_BLOCK_SIZE 65536#define EXT4_MIN_BLOCK_LOG_SIZE 10#define EXT4_MAX_BLOCK_LOG_SIZE 16 -#define EXT4_MAX_CLUSTER_LOG_SIZE 30 +#define EXT4_MAX_CLUSTER_LOG_SIZE 28#ifdef __KERNEL__# define EXT4_BLOCK_SIZE (s) ((s)->s_blocksize)#else
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 116/2214 PCI: vmd: Handle BUS_RESTRICT_CFG value 3 for Arrow Lake-HX
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ali Alaei <[email protected]>
[ Upstream commit 72b32eccbcd591b9606edacf3bd7c455176d7660 ]
On Intel Arrow Lake-HX systems (e.g. Core Ultra 9 275HX on Acer Predator PH16-73), the VMD controller reports BUS_RESTRICT_CFG = 3 in the VMCONFIG register. The existing switch statement only handled values 0, 1, and 2, causing vmd_get_bus_number_start() to return -ENODEV and aborting the entire VMD probe. This leaves NVMe drives behind the VMD controller invisible to the kernel.
Hardware registers (VMCAP/VMCONFIG at offsets 0x40/0x44):
VMD 0000:00:0e.0 (8086:ad0b): VMCAP=0x000f, VMCONFIG=0x03b8 BUS_RESTRICT_CFG(0x03b8) = (0x03b8 >> 8) & 0x3 = 3
Add cfg=3 as a fallthrough to cfg=2, setting busn_start=224, which is the correct bus number base for this hardware.
Also add a PCI_POSSIBLE_ERROR() guard after reading VMCONFIG: a failed config space read returns 0xFFFF, and BUS_RESTRICT_CFG(0xFFFF) = 3, so without this guard a removed or errored device would falsely match the new case 3 instead of being caught as an error.
--- drivers/pci/controller/vmd.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/pci/controller/vmd.c +3 -0
@@ -590,6 +590,8 @@ static int vmd_get_bus_number_start(struct vmd_dev *vmd)pci_read_config_word (dev,PCI_REG_VMCAP , ®);if (BUS_RESTRICT_CAP (reg)) {pci_read_config_word (dev,PCI_REG_VMCONFIG , ®); +if (PCI_POSSIBLE_ERROR (reg)) +return -ENODEV ;switch (BUS_RESTRICT_CFG (reg)) {case 0 :
@@ -598,6 +600,7 @@ static int vmd_get_bus_number_start(struct vmd_dev *vmd)case 1 : vmd->busn_start =128 ;break ; +case 3 :case 2 : vmd->busn_start =224 ;break ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 117/2214 ext4: set EXT4_STATE_NO_EXPAND in ext4_evict_inode
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yun Zhou <[email protected]>
[ Upstream commit 2c0e4fb511f97467dafc91b6afb3414100289081 ]
An inode being evicted will never need its extra isize expanded. Set EXT4_STATE_NO_EXPAND before ext4_mark_inode_dirty() in ext4_evict_inode() to make this explicit and prevent any unnecessary work in ext4_try_to_expand_extra_isize().
This also provides defense-in-depth for the s_writepages_rwsem deadlock during mount-time orphan cleanup, ensuring the expand path is blocked for inodes under eviction regardless of how they are reached.
--- fs/ext4/inode.c | 1 + 1 file changed, 1 insertion(+)
fs/ext4/inode.c +1 -0
@@ -281,6 +281,7 @@ void ext4_evict_inode(struct inode *inode)if (ext4_inode_is_fast_symlink (inode))memset (EXT4_I (inode)->i_data,0 ,sizeof (EXT4_I (inode)->i_data)); inode->i_size =0 ; +ext4_set_inode_state (inode,EXT4_STATE_NO_EXPAND ); err =ext4_mark_inode_dirty (handle, inode);if (err) { ext4_warning(inode->i_sb,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 118/2214 wifi: mac80211: ibss: read deauth reason_code after frame length check
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Shahar Tzarfati <[email protected]>
[ Upstream commit aa4c0a649903567762edf2bbc7fff608953b3ca4 ]
The function was reading reason_code from the frame before validating that the frame is at least IEEE80211_DEAUTH_FRAME_LEN bytes long.
Move the reason_code read to after the length check so the field is guaranteed to be present before it is accessed.
--- net/mac80211/ibss.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
net/mac80211/ibss.c +3 -1
@@ -935,11 +935,13 @@ static void ieee80211_rx_mgmt_deauth_ibss(struct ieee80211_sub_if_data *sdata, struct ieee80211_mgmt *mgmt, size_t len) { -u16 reason =le16_to_cpu (mgmt->u.deauth.reason_code); +u16 reason;if (len <IEEE80211_DEAUTH_FRAME_LEN )return ; + reason =le16_to_cpu (mgmt->u.deauth.reason_code); +ibss_dbg (sdata,"RX DeAuth SA=%pM DA=%pM\n" , mgmt->sa, mgmt->da);ibss_dbg (sdata,"\tBSSID=%pM (reason: %d)\n" , mgmt->bssid, reason);sta_info_destroy_addr (sdata, mgmt->sa);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 119/2214 riscv, bpf: Add support for BPF_SDIV and BPF_SMOD in RV32 JIT
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuan-Wei Chiu <[email protected]>
[ Upstream commit 2e0fa2389c50fd3a69bb738efa74e127b7516938 ]
The current rv32 bpf jit compiler incorrectly treats BPF_SDIV and BPF_SMOD as unsigned operations. The BPF instruction set allows signed division and modulo by reusing the BPF_DIV and BPF_MOD opcodes with the instruction offset set to 1.
Update the emit_alu_r32() function to accept an 'is_sdiv' variable and emit the correct div and rem instructions when the offset is 1.
Before this patch:
[ 44.161771] test_bpf: #165 ALU_SDIV_X: -6 / 2 = -3 jited:1 ret 2147483645 != -3 (0x7ffffffd != 0xfffffffd)FAIL (1 times) [ 44.167385] test_bpf: #166 ALU_SDIV_K: -6 / 2 = -3 jited:1 ret 2147483645 != -3 (0x7ffffffd != 0xfffffffd)FAIL (1 times) [ 44.171053] test_bpf: #169 ALU_SMOD_X: -7 % 2 = -1 jited:1 ret 1 != -1 (0x1 != 0xffffffff)FAIL (1 times) [ 44.172081] test_bpf: #170 ALU_SMOD_K: -7 % 2 = -1 jited:1 ret 1 != -1 (0x1 != 0xffffffff)FAIL (1 times)
After this patch:
[ 16.002192] test_bpf: #165 ALU_SDIV_X: -6 / 2 = -3 jited:1 95 PASS [ 16.002983] test_bpf: #166 ALU_SDIV_K: -6 / 2 = -3 jited:1 1059 PASS [ 16.017167] test_bpf: #169 ALU_SMOD_X: -7 % 2 = -1 jited:1 136 PASS [ 16.023002] test_bpf: #170 ALU_SMOD_K: -7 % 2 = -1 jited:1 109 PASS
--- arch/riscv/net/bpf_jit_comp32.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-)
arch/riscv/net/bpf_jit_comp32.c +10 -5
@@ -509,12 +509,15 @@ static void emit_alu_r64(const s8 *dst, const s8 *src, }static void emit_alu_r32 (const s8 *dst,const s8 *src, -struct rv_jit_context *ctx,const u8 op) +struct rv_jit_context *ctx, +const struct bpf_insn *insn) {const s8 *tmp1 = bpf2rv32[TMP_REG_1 ];const s8 *tmp2 = bpf2rv32[TMP_REG_2 ];const s8 *rd =bpf_get_reg32 (dst, tmp1, ctx);const s8 *rs =bpf_get_reg32 (src, tmp2, ctx); +u8 op =BPF_OP (insn->code); +bool is_signed = insn->off ==1 ;switch (op) {case BPF_MOV :
@@ -539,10 +542,12 @@ static void emit_alu_r32(const s8 *dst, const s8 *src,emit (rv_mul (lo (rd),lo (rd),lo (rs)), ctx);break ;case BPF_DIV : -emit (rv_divu (lo (rd),lo (rd),lo (rs)), ctx); +emit (is_signed ?rv_div (lo (rd),lo (rd),lo (rs)) : +rv_divu (lo (rd),lo (rd),lo (rs)), ctx);break ;case BPF_MOD : -emit (rv_remu (lo (rd),lo (rd),lo (rs)), ctx); +emit (is_signed ?rv_rem (lo (rd),lo (rd),lo (rs)) : +rv_remu (lo (rd),lo (rd),lo (rs)), ctx);break ;case BPF_LSH :emit (rv_sll (lo (rd),lo (rd),lo (rs)), ctx);
@@ -1044,7 +1049,7 @@ int bpf_jit_emit_insn(const struct bpf_insn *insn, struct rv_jit_context *ctx,emit_imm32 (tmp2, imm, ctx); src = tmp2; } -emit_alu_r32 (dst, src, ctx,BPF_OP (code)); +emit_alu_r32 (dst, src, ctx, insn);break ;case BPF_ALU |BPF_MOV |BPF_K :
@@ -1068,7 +1073,7 @@ int bpf_jit_emit_insn(const struct bpf_insn *insn, struct rv_jit_context *ctx,* src is ignored---choose tmp2 as a dummy register since it * is not on the stack. */ -emit_alu_r32 (dst, tmp2, ctx,BPF_OP (code)); +emit_alu_r32 (dst, tmp2, ctx, insn);break ;case BPF_ALU |BPF_END |BPF_FROM_LE :
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 120/2214 power: supply: cros_pchg: unregister EC notifier
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 631adfa03595c63b2a621cdc62db60bb1ce5f91c ]
cros_pchg_probe() registers an EC event notifier whose callback uses the devm-allocated charger_data via container_of(). The driver has no remove callback and does not unregister the notifier, so the notifier chain can retain a pointer to freed driver state after unbind or probe cleanup.
Register a devm cleanup action immediately after the notifier is installed so the notifier is unregistered before the driver state is released. Also fail probe if the notifier cannot be registered, instead of leaving a charger device that cannot receive EC events.
--- drivers/power/supply/cros_peripheral_charger.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)
drivers/power/supply/cros_peripheral_charger.c +11 -2
@@ -282,6 +282,14 @@ static int cros_ec_notify(struct notifier_block *nb,return cros_pchg_event (charger, host_event); } +static void cros_pchg_unregister_notifier (void *data) +{ +struct charger_data *charger = data; + +blocking_notifier_chain_unregister (&charger->ec_device->event_notifier, + &charger->notifier); +} +static int cros_pchg_probe (struct platform_device *pdev) {struct device *dev = &pdev->dev;
@@ -367,9 +375,10 @@ static int cros_pchg_probe(struct platform_device *pdev) ret =blocking_notifier_chain_register (&ec_dev->ec_dev->event_notifier, nb);if (ret <0 ) -dev_err (dev,"Failed to register notifier (err:%d)\n" , ret); +return dev_err_probe (dev, ret,"Failed to register notifier\n" ); -return 0 ; +return devm_add_action_or_reset (dev, cros_pchg_unregister_notifier, + charger); }static struct platform_driver cros_pchg_driver = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 121/2214 power: reset: piix4-poweroff: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit ffefc5d9a052f67bc87b57d1107fd7cc1fa1a3d4 ]
The driver has a match table for the pci bus wired into its driver structure, but the table is not exported with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE() entry so module alias information is generated for automatic module loading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the driver registration structure, and the missing module alias publication.
--- drivers/power/reset/piix4-poweroff.c | 1 + 1 file changed, 1 insertion(+)
drivers/power/reset/piix4-poweroff.c +1 -0
@@ -96,6 +96,7 @@ static const struct pci_device_id piix4_poweroff_ids[] = { { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82371AB_3) }, { 0 }, }; +MODULE_DEVICE_TABLE (pci, piix4_poweroff_ids);static struct pci_driver piix4_poweroff_driver = { .name = "piix4-poweroff",
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 122/2214 riscv, bpf: Add support for BPF_MOVSX in RV32 JIT
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuan-Wei Chiu <[email protected]>
[ Upstream commit c6a08afdfe3a81b1a54e921921e9481dd6c78f8a ]
The current rv32 bpf jit compiler incorrectly treats BPF_MOVSX as a standard zero-extended move operation. The bpf instruction set allows sign-extension moves by reusing the BPF_MOV opcode with the instruction offset set to 8, 16, or 32.
Update the bpf_jit_emit_insn() function to check the offset field for both ALU and ALU64 MOV operations. If the offset is non-zero, emit the correct slli and srai instructions to perform the sign extension.
Before this patch:
[ 19.549705] test_bpf: #82 ALU_MOVSX | BPF_B jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times) [ 19.551354] test_bpf: #83 ALU_MOVSX | BPF_H jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times) [ 19.552576] test_bpf: #84 ALU64_MOVSX | BPF_B jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times) [ 19.553542] test_bpf: #85 ALU64_MOVSX | BPF_H jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times) [ 19.554807] test_bpf: #86 ALU64_MOVSX | BPF_W jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times)
After this patch:
[ 17.931172] test_bpf: #82 ALU_MOVSX | BPF_B jited:1 125 PASS [ 17.932198] test_bpf: #83 ALU_MOVSX | BPF_H jited:1 124 PASS [ 17.933039] test_bpf: #84 ALU64_MOVSX | BPF_B jited:1 124 PASS [ 17.933918] test_bpf: #85 ALU64_MOVSX | BPF_H jited:1 124 PASS [ 17.934751] test_bpf: #86 ALU64_MOVSX | BPF_W jited:1 122 PASS
--- arch/riscv/net/bpf_jit_comp32.c | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+)
arch/riscv/net/bpf_jit_comp32.c +32 -0
@@ -975,6 +975,24 @@ int bpf_jit_emit_insn(const struct bpf_insn *insn, struct rv_jit_context *ctx,switch (code) {case BPF_ALU64 |BPF_MOV |BPF_X : +if (insn->off !=0 ) { +const s8 *rd =bpf_get_reg64 (dst, tmp1, ctx); +const s8 *rs =bpf_get_reg64 (src, tmp2, ctx); + +if (insn->off ==8 ) { +emit (rv_slli (lo (rd),lo (rs),24 ), ctx); +emit (rv_srai (lo (rd),lo (rd),24 ), ctx); + }else if (insn->off ==16 ) { +emit (rv_slli (lo (rd),lo (rs),16 ), ctx); +emit (rv_srai (lo (rd),lo (rd),16 ), ctx); + }else { +emit (rv_addi (lo (rd),lo (rs),0 ), ctx); + } +emit (rv_srai (hi (rd),lo (rd),31 ), ctx); +bpf_put_reg64 (dst, rd, ctx); +break ; + } + fallthrough;case BPF_ALU64 |BPF_ADD |BPF_X :case BPF_ALU64 |BPF_ADD |BPF_K :
@@ -1025,6 +1043,20 @@ int bpf_jit_emit_insn(const struct bpf_insn *insn, struct rv_jit_context *ctx,emit_zext64 (dst, ctx);break ; } +if (insn->off !=0 ) { +const s8 *rd =bpf_get_reg32 (dst, tmp1, ctx); +const s8 *rs =bpf_get_reg32 (src, tmp2, ctx); + +if (insn->off ==8 ) { +emit (rv_slli (lo (rd),lo (rs),24 ), ctx); +emit (rv_srai (lo (rd),lo (rd),24 ), ctx); + }else if (insn->off ==16 ) { +emit (rv_slli (lo (rd),lo (rs),16 ), ctx); +emit (rv_srai (lo (rd),lo (rd),16 ), ctx); + } +bpf_put_reg32 (dst, rd, ctx); +break ; + } fallthrough;case BPF_ALU |BPF_ADD |BPF_X :
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 123/2214 wifi: cfg80211: include cf1 offset when sending chandef
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lachlan Hodges <[email protected]>
[ Upstream commit 5a69b8dffd2a1b06e4cc4c9003c639eb78bac4cd ]
The cf1 offset is not included when sending the chandef leading to incorrect channel resolution in usermode. Include it.
--- net/wireless/nl80211.c | 4 ++++ 1 file changed, 4 insertions(+)
net/wireless/nl80211.c +4 -0
@@ -3571,6 +3571,10 @@ static int nl80211_send_chandef(struct sk_buff *msg,return -ENOBUFS ;if (nla_put_u32 (msg,NL80211_ATTR_CENTER_FREQ1 , chandef->center_freq1))return -ENOBUFS ; +if (chandef->freq1_offset && +nla_put_u32 (msg,NL80211_ATTR_CENTER_FREQ1_OFFSET , + chandef->freq1_offset)) +return -ENOBUFS ;if (chandef->center_freq2 &&nla_put_u32 (msg,NL80211_ATTR_CENTER_FREQ2 , chandef->center_freq2))return -ENOBUFS ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 124/2214 drm/panel: simple: Add Kyocera tcg070wvlq panel
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Heiko Schocher <[email protected]>
[ Upstream commit 900517da69afca6f72dacf14278aee3b65275507 ]
Commit 922fb2db0287 ("dt-bindings: display: simple: Add Kyocera tcg070wvlq panel") added the compatible string for the Kyocera tcg070wvlq panel to the devicetree bindings documentation (panel-simple.yaml), but the corresponding entry was not added to the panel-simple driver.
Add the missing compatible entry to the driver.
--- drivers/gpu/drm/panel/panel-simple.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/panel/panel-simple.c +3 -0
@@ -4775,6 +4775,9 @@ static const struct of_device_id platform_of_match[] = { }, { .compatible = "koe,tx31d200vm0baa", .data = &koe_tx31d200vm0baa, + }, { + .compatible = "kyo,tcg070wvlq", + .data = &lg_lb070wv8, }, { .compatible = "kyo,tcg121xglp", .data = &kyo_tcg121xglp,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 125/2214 iommu/qcom: Check pm_runtime_resume_and_get() return in probe
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Mukesh Ojha <[email protected]>
[ Upstream commit e910315ae08a23bc953daed10b1c518abac1df49 ]
The SMMU_INTR_SEL_NS register write in qcom_iommu_device_probe() uses pm_runtime_get_sync() without checking the return value. If runtime resume fails the subsequent writel_relaxed() would access hardware with clocks potentially disabled.
Switch to pm_runtime_resume_and_get() which handles the usage-count cleanup on failure, check the return value, and unwind the already registered iommu device on error.
--- drivers/iommu/arm/arm-smmu/qcom_iommu.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/iommu/arm/arm-smmu/qcom_iommu.c +5 -1
@@ -854,13 +854,17 @@ static int qcom_iommu_device_probe(struct platform_device *pdev)bus_set_iommu (&platform_bus_type, &qcom_iommu_ops);if (qcom_iommu->local_base) { -pm_runtime_get_sync (dev); + ret =pm_runtime_resume_and_get (dev); +if (ret) + goto err_iommu_unregister;writel_relaxed (0xffffffff , qcom_iommu->local_base +SMMU_INTR_SEL_NS );pm_runtime_put_sync (dev); }return 0 ; +err_iommu_unregister: +iommu_device_unregister (&qcom_iommu->iommu); err_sysfs_remove:iommu_device_sysfs_remove (&qcom_iommu->iommu); err_pm_disable:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 126/2214 iommu/qcom: Publish pgtbl_ops before releasing init_mutex
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Mukesh Ojha <[email protected]>
[ Upstream commit a05b67cd45ad09a19f41b2d37255da714512e0ca ]
qcom_domain->pgtbl_ops was assigned after mutex_unlock(). Another thread calling qcom_iommu_init_domain() would see qcom_domain->iommu already set (domain fully initialized) and skip re-initialization under the mutex. If it then called qcom_iommu_map() before the first thread set pgtbl_ops, it would observe a NULL ops pointer and return -ENODEV for valid mappings.
Move the assignment to before mutex_unlock() so that once the mutex is released the domain is fully visible to concurrent operations.
--- drivers/iommu/arm/arm-smmu/qcom_iommu.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/iommu/arm/arm-smmu/qcom_iommu.c +2 -3
@@ -312,13 +312,12 @@ static int qcom_iommu_init_domain(struct iommu_domain *domain, ctx->domain = domain; } -mutex_unlock (&qcom_domain->init_mutex); -/* Publish page table ops for map/unmap */ qcom_domain->pgtbl_ops = pgtbl_ops; -return 0 ; +mutex_unlock (&qcom_domain->init_mutex); +return 0 ; out_clear_iommu: qcom_domain->iommu =NULL ; out_unlock:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 127/2214 wifi: ath11k: validate regulatory capability phy_id
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit f8729a40ebcc94d164be8f154483a21669f3ab52 ]
ath11k_wmi_tlv_ext_hal_reg_caps() copies firmware regulatory capability records into soc->hal_reg_cap[] using reg_cap.phy_id as the destination index. The loop count is bounded by num_phy, but the phy_id embedded in each record is not checked against the fixed MAX_RADIOS-sized destination array.
Reject firmware records whose phy_id does not fit soc->hal_reg_cap[] before copying the parsed capability.
--- drivers/net/wireless/ath/ath11k/wmi.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/net/wireless/ath/ath11k/wmi.c +6 -0
@@ -4106,6 +4106,12 @@ static int ath11k_wmi_tlv_ext_hal_reg_caps(struct ath11k_base *soc,return ret; } +if (reg_cap.phy_id >=ARRAY_SIZE (soc->hal_reg_cap)) { +ath11k_warn (soc,"invalid reg cap phy_id %u\n" , + reg_cap.phy_id); +return -EINVAL ; + } +memcpy (&soc->hal_reg_cap[reg_cap.phy_id], ®_cap,sizeof (reg_cap)); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 128/2214 wifi: ath10k: trigger hardware recovery upon rx failures
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Manikanta Pubbisetty <[email protected]>
[ Upstream commit f78210dd4bea09090b828adc2733cad4b9916306 ]
When an error occurs during RX packet processing (e.g., MSDU done failure), the driver sets rx_confused and drops all subsequent RX packets until a Wi-Fi ON/OFF cycle clears the flag. This can leave the device in a bad state where it cannot process RX data traffic.
Instead of leaving the device in such a state, trigger hardware recovery so that such an error state can be reset and the device can function again normally.
Tested-on: WCN3990 hw1.0 WLAN.HL.3.2.2.c10-00754-QCAHLSWMTPL-1
Tested-on: QCA6174 hw3.2 PCI WLAN.RM.4.4.1-00288-QCARMSWPZ-1
Tested-on: QCA6174 hw3.2 SDIO WLAN.RMH.4.4.1-00189
--- drivers/net/wireless/ath/ath10k/htt_rx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/net/wireless/ath/ath10k/htt_rx.c +3 -3
@@ -2223,10 +2223,8 @@ static int ath10k_htt_rx_handle_amsdu(struct ath10k_htt *htt)if (ret <0 ) {ath10k_warn (ar,"rx ring became corrupted: %d\n" , ret);__skb_queue_purge (&amsdu); -/* FIXME: It's probably a good idea to reboot the -* device instead of leaving it inoperable. -*/ htt->rx_confused = true; +ath10k_core_start_recovery (ar);return ret; }
@@ -3183,6 +3181,7 @@ static int ath10k_htt_rx_in_ord_ind(struct ath10k *ar, struct sk_buff *skb)if (ret <0 ) {ath10k_warn (ar,"failed to pop paddr list: %d\n" , ret); htt->rx_confused = true; +ath10k_core_start_recovery (ar);return -EIO ; }
@@ -3216,6 +3215,7 @@ static int ath10k_htt_rx_in_ord_ind(struct ath10k *ar, struct sk_buff *skb)ath10k_warn (ar,"failed to extract amsdu: %d\n" , ret); htt->rx_confused = true;__skb_queue_purge (&list); +ath10k_core_start_recovery (ar);return -EIO ; } }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 129/2214 ext4: check return value of ext4_get_block() in ext4_load_tail_bh()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zhang Yi <[email protected]>
[ Upstream commit 705a3fd3bac167f1dabe3d3bba46cd484c5528dd ]
ext4_load_tail_bh() ignores the return value of ext4_get_block(), so an I/O or allocation failure is silently discarded. buffer_mapped(bh) stays false and the function returns NULL, which callers such as ext4_block_do_zero_range() treat as "nothing to do" and return success. This can mask real failures during zero-range, truncate, or punch-hole operations, potentially exposing stale data if the block was not actually a hole and needed zeroing. So propagate the error to the callers.
--- fs/ext4/inode.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
fs/ext4/inode.c +3 -1
@@ -3750,7 +3750,9 @@ static int __ext4_block_zero_page_range(handle_t *handle, }if (!buffer_mapped (bh)) {BUFFER_TRACE (bh,"unmapped" ); -ext4_get_block (inode, iblock, bh,0 ); + err =ext4_get_block (inode, iblock, bh,0 ); +if (err <0 ) + goto unlock;/* unmapped? It's a hole - nothing to do */ if (!buffer_mapped (bh)) {BUFFER_TRACE (bh,"still unmapped" );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 130/2214 bitops: make the *_bit_le functions use unsigned long
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Benjamin Marzinski <[email protected]>
[ Upstream commit 1c61b0a6e5c472737619f74f79c390363ee258df ]
The *_bit_le functions use a signed integer for the bit number. However, the *_bit functions can use an unsigned long. This causes problems if there is a large bitmap and a bit number > 0x80000000 is passed in. Since that is a negative int, it will get sign extended to a long when getting passed to the *_bit function, turning it into a huge bit number. This usually ends up with the memory address wrapping around and the function accessing memory before the start of the bitmap.
Avoid this by making the *_bit_le functions take an unsigned long.
This can be triggered by faking an almost 4TB dm-mirror device, which uses bitmaps to track the mirror regions:
$ dmsetup create bigzero --table '0 8589934590 zero' $ dmsetup create mymirror --table '0 8589934590 mirror core 2 2 nosync 2 /dev/mapper/bigzero 0 /dev/mapper/bigzero 0'
This will access memory before the start of the sync_bits bitmap, and likely hit the guard page of the previously allocated clean_bits bitmap, causing a kernel panic with the old code.
I looked and didn't see any crazy code using the signed int to intentionally try and access bits before some address within the bitmap.
--- include/asm-generic/bitops/le.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
include/asm-generic/bitops/le.h +9 -9
@@ -80,47 +80,47 @@ unsigned long find_next_bit_le(const void *addr, unsigned#error "Please fix <asm/byteorder.h>"#endif -static inline int test_bit_le (int nr,const void *addr) +static inline int test_bit_le (unsigned long nr,const void *addr) {return test_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline void set_bit_le (int nr,void *addr) +static inline void set_bit_le (unsigned long nr,void *addr) {set_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline void clear_bit_le (int nr,void *addr) +static inline void clear_bit_le (unsigned long nr,void *addr) {clear_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline void __set_bit_le (int nr,void *addr) +static inline void __set_bit_le (unsigned long nr,void *addr) {__set_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline void __clear_bit_le (int nr,void *addr) +static inline void __clear_bit_le (unsigned long nr,void *addr) {__clear_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline int test_and_set_bit_le (int nr,void *addr) +static inline int test_and_set_bit_le (unsigned long nr,void *addr) {return test_and_set_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline int test_and_clear_bit_le (int nr,void *addr) +static inline int test_and_clear_bit_le (unsigned long nr,void *addr) {return test_and_clear_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline int __test_and_set_bit_le (int nr,void *addr) +static inline int __test_and_set_bit_le (unsigned long nr,void *addr) {return __test_and_set_bit (nr ^BITOP_LE_SWIZZLE , addr); } -static inline int __test_and_clear_bit_le (int nr,void *addr) +static inline int __test_and_clear_bit_le (unsigned long nr,void *addr) {return __test_and_clear_bit (nr ^BITOP_LE_SWIZZLE , addr); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 131/2214 soc: ixp4xx: qmgr: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 01479280fa5d4691013bcd64fdfd935117b69769 ]
The driver has an OF match table wired to .of_match_table, but does not export the table with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE(of, ...) entry so module alias information is generated for OF based module autoloading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the platform driver, and the missing module alias publication.
Message-ID: <[email protected]>
--- drivers/soc/ixp4xx/ixp4xx-qmgr.c | 1 + 1 file changed, 1 insertion(+)
drivers/soc/ixp4xx/ixp4xx-qmgr.c +1 -0
@@ -455,6 +455,7 @@ static const struct of_device_id ixp4xx_qmgr_of_match[] = { }, {}, }; +MODULE_DEVICE_TABLE (of, ixp4xx_qmgr_of_match);static struct platform_driver ixp4xx_qmgr_driver = { .driver = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 132/2214 PCI/portdrv: Allow probing even without child services
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Brian Norris <[email protected]>
[ Upstream commit 834171efeefffb1a0f2136f32e76669bbc11db86 ]
The PCIe port driver fails to probe if it finds no child services, presumably under the assumption that the driver is not useful in that case. However, the driver *can* still be useful for power management support -- namely, it still configures the port for runtime PM / D3, which may be important for allowing a bridge to enter low power modes.
Thus, allow probe to succeed even if no IRQs and no child services are available. This also mirrors existing behavior for ports that don't support any portdrv services (PCIe hotplug, AER, DPC, PME, bwctrl), where we'd also probe successfully.
This change is a bit more important after commit f5cd8a929c82 ("PCI: dwc:
Remove MSI/MSIX capability for Root Port if iMSI-RX is used as MSI controller"), because it's common for some DWC-based systems to:
1. have only the "aer" and "pcie_pme" port services available and
2. not define legacy INTx interrupts properly in their device tree.
After commit f5cd8a929c82, such systems may fail pcie_init_service_irqs() and so exit with -ENODEV.
--- drivers/pci/pcie/portdrv_core.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-)
drivers/pci/pcie/portdrv_core.c +14 -14
@@ -319,8 +319,8 @@ static int pcie_device_init(struct pci_dev *pdev, int service, int irq)*/ int pcie_port_device_register (struct pci_dev *dev) { -int status, capabilities, i, nr_service;int irqs[PCIE_PORT_DEVICE_MAXSERVICES ]; +int status, capabilities, i;/* Enable PCI Express port device */ status =pci_enable_device (dev);
@@ -344,29 +344,29 @@ int pcie_port_device_register(struct pci_dev *dev)if (status) { capabilities &=PCIE_PORT_SERVICE_HP ;if (!capabilities) - goto error_disable; + goto out; }/* Allocate child services if any */ - status = -ENODEV ; - nr_service =0 ;for (i =0 ; i <PCIE_PORT_DEVICE_MAXSERVICES ; i++) {int service =1 << i;if (!(capabilities & service))continue ; -if (!pcie_device_init (dev, service, irqs[i])) - nr_service++; +if (pcie_device_init (dev, service, irqs[i])) + capabilities &= ~service; } -if (!nr_service) - goto error_cleanup_irqs; -return 0 ; +out: +/* +* With no child services, we shouldn't need bus mastering or any IRQ +* vectors we allocated. +*/ +if (!capabilities) { +pci_free_irq_vectors (dev); +pci_clear_master (dev); + } -error_cleanup_irqs: -pci_free_irq_vectors (dev); -error_disable: -pci_disable_device (dev); -return status; +return 0 ; }typedef int (*pcie_callback_t )(struct pcie_device *);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 133/2214 fs/ntfs3: reserve NUL byte when converting UTF-16 names
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kyle Zeng <[email protected]>
[ Upstream commit 4871fedaabbfd574ac0a075b80e75afdd532e11e ]
ntfs_utf16_to_nls() appends a trailing NUL to the converted output, but it passes the caller-supplied size directly to the conversion loop. For the UTF-8 path, utf16s_to_utf8s() can legitimately fill all buf_len bytes and return buf_len, after which ntfs_utf16_to_nls() writes the terminator one byte past the end of the destination buffer.
The same contract problem exists for the NLS path when a converted character consumes the last available byte.
Reserve one byte for the terminator before doing either conversion. The function continues to return the number of converted bytes, excluding the NUL terminator.
--- fs/ntfs3/dir.c | 5 +++++ 1 file changed, 5 insertions(+)
fs/ntfs3/dir.c +5 -0
@@ -24,6 +24,11 @@ int ntfs_utf16_to_nls(struct ntfs_sb_info *sbi, const __le16 *name, u32 len,static_assert (sizeof (wchar_t) ==sizeof (__le16)); +if (buf_len <=0 ) +return -EINVAL ; + + buf_len -=1 ; +if (!nls) {/* UTF-16 -> UTF-8 */ ret = utf16s_to_utf8s(name, len, UTF16_LITTLE_ENDIAN, buf,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 134/2214 ntfs3: fix info-leak in ntfs_rename()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konstantin Komarov <[email protected]>
[ Upstream commit 2fa56613b25d0c983ef3ff6d3e865d4254280abe ]
Hard to say about copy_to_user_iter(), but at least the first splat looks correct. At the end of fill_name_de(), data layout is:
struct NTFS_DE *e = buf;
...
|<- data_size + sizeof(struct NTFS_DE) ->|<- XXX ->|
buf |-----------------------------------------------------------
|<- ALIGN(data_size, 8) + sizeof(struct NTFS_DE) ->| ;; e->sizeIf 'buf' was allocated with kmalloc(), XXX remains uninitialized and passed as such to memcpy() called from hdr_insert_de().
So using kzalloc() for all buffers passed to fill_name_de() looks the simplest and most safe solution. OTOH if someone would have said that an overhead of PAGE_SIZE'd memset() is too large, more fine-granted solution is to memset() XXX only.
--- fs/ntfs3/namei.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
fs/ntfs3/namei.c +7 -2
@@ -20,7 +20,7 @@ int fill_name_de(struct ntfs_sb_info *sbi, void *buf, const struct qstr *name, {int err;struct NTFS_DE *e = buf; -u16 data_size; +u16 data_size, real_size, aligned_size;struct ATTR_FILE_NAME *fname = (struct ATTR_FILE_NAME *)(e +1 );#ifndef CONFIG_NTFS3_64BIT_CLUSTER
@@ -51,7 +51,12 @@ int fill_name_de(struct ntfs_sb_info *sbi, void *buf, const struct qstr *name, fname->type =FILE_NAME_POSIX ; data_size =fname_full_size (fname); - e->size =cpu_to_le16 (ALIGN (data_size,8 ) +sizeof (struct NTFS_DE )); + real_size = data_size +sizeof (struct NTFS_DE ); + aligned_size =ALIGN (data_size,8 ) +sizeof (struct NTFS_DE ); +if (aligned_size > real_size) +memset ((char *)buf + real_size,0 , aligned_size - real_size); + + e->size =cpu_to_le16 (aligned_size); e->key_size =cpu_to_le16 (data_size); e->flags =0 ; e->res =0 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 135/2214 fs/ntfs3: fix lseek EINVAL on sparse/compressed files with 64-bit clusters
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Senjin <[email protected]>
[ Upstream commit 789af83e41aef54c1ff1cee16adc27822e0a0d71 ]
When CONFIG_NTFS3_64BIT_CLUSTER is enabled, sbi->maxbytes_sparse is set to -1. As a signed loff_t this is -1LL, the most negative value. Any lseek on a sparse or compressed file passes this as maxsize to vfs_setpos(), which returns -EINVAL whenever offset > maxsize, and since -1LL is less than any non-negative offset, every seek fails, including lseek(fd, 0, SEEK_SET).
The intent of -1 here appears to be "no limit" (matching the spirit of MAX_LFS_FILESIZE assigned to sbi->maxbytes and sb->s_maxbytes in the same block), but the signed type makes it the minimum instead of the maximum.
Fix by assigning MAX_LFS_FILESIZE to sbi->maxbytes_sparse in the 64-bit cluster path, consistent with the other two limits set there.
Observed on a 16 TB NTFS volume with 0xFFFFFEFF total clusters compiled with CONFIG_NTFS3_64BIT_CLUSTER=y. Sequential reads via dd/cp worked correctly; any lseek call on sparse files returned EINVAL, preventing archive managers and other tools from random-accessing files on the volume. The non-64-bit-cluster path correctly sets maxbytes_sparse to (1ull << (cluster_bits + 32)) - 1, a large positive value.
--- fs/ntfs3/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/ntfs3/super.c +1 -1
@@ -863,7 +863,7 @@ static int ntfs_init_from_boot(struct super_block *sb, u32 sector_size,#ifdef CONFIG_NTFS3_64BIT_CLUSTER if (clusters >= (1ull << (64 - sbi->cluster_bits))) sbi->maxbytes =-1 ; - sbi->maxbytes_sparse =-1 ; + sbi->maxbytes_sparse =MAX_LFS_FILESIZE ; sb->s_maxbytes =MAX_LFS_FILESIZE ;#else /* Maximum size for sparse file. */
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 136/2214 fs/ntfs3: load ATTR_BITMAP run extents from $MFT extension records
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konstantin Komarov <[email protected]>
[ Upstream commit e31886cb6e0e14cf65e27da0bf1a422ff419d893 ]
When $MFT's ATTR_BITMAP attribute is heavily fragmented, its run list can span multiple MFT extension records (attribute list entries with vcn > 0). The non-primary segment handler in ntfs_read_mft() only processed ATTR_DATA extension segments for MFT_REC_MFT, silently skipping any ATTR_BITMAP segments. This left sbi->mft.bitmap.run incomplete, causing wnd_init() to fail with -ENOENT when wnd_rescan() tried to look up a VCN not covered by the truncated run list.
Observed on a 16 TB NTFS volume (0xFFFFFEFF total clusters) whose MFT bitmap run list was split across 97 extents in extension records. wnd_rescan() successfully looked up VCNs 0-122 from the runs loaded from the base record, then failed at VCN 123 (the last cluster of the bitmap) whose run was only present in an extension record.
Fix by extending the MFT_REC_MFT special case to also handle ATTR_BITMAP extension segments, storing their runs into sbi->mft.bitmap.run the same way the primary segment does.
--- fs/ntfs3/inode.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
fs/ntfs3/inode.c +8 -2
@@ -125,10 +125,16 @@ static struct inode *ntfs_read_mft(struct inode *inode,if (le && le->vcn) {/* This is non primary attribute segment. Ignore if not MFT. */ -if (ino !=MFT_REC_MFT || attr->type !=ATTR_DATA ) +if (ino !=MFT_REC_MFT ) + goto next_attr; + +if (attr->type ==ATTR_DATA ) + run = &ni->file.run; +else if (attr->type ==ATTR_BITMAP ) + run = &sbi->mft.bitmap.run; +else goto next_attr; - run = &ni->file.run; asize =le32_to_cpu (attr->size); goto attr_unpack_run; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 137/2214 firmware: imx: scu: manage mailbox channels and global handle
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 55c748d596f841a18cf659ce0999f64029a5c88c ]
imx_scu_probe() requests mailbox channels with the non-managed mbox_request_channel_byname() helper and then publishes sc_ipc through the global imx_sc_ipc_handle. Later probe failures, including child population failure, can leave the channels and global handle live after the probe has failed.
Register devres actions to free each mailbox channel and clear the global handle. Also depopulate partially created child devices when devm_of_platform_populate() reports an error.
--- drivers/firmware/imx/imx-scu.c | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-)
drivers/firmware/imx/imx-scu.c +24 -1
@@ -81,6 +81,17 @@ static int imx_sc_linux_errmap[IMX_SC_ERR_LAST] = {static struct imx_sc_ipc *imx_sc_ipc_handle; +static void imx_scu_free_mbox_chan (void *data) +{ +mbox_free_channel (data); +} + +static void imx_scu_clear_handle (void *data) +{ +if (imx_sc_ipc_handle == data) + imx_sc_ipc_handle =NULL ; +} +static inline int imx_sc_to_linux_errno (int errno) {if (errno >=IMX_SC_ERR_NONE && errno <IMX_SC_ERR_LAST )
@@ -321,6 +332,11 @@ static int imx_scu_probe(struct platform_device *pdev)dev_dbg (dev,"request mbox chan %s\n" , chan_name);/* chan_name is not used anymore by framework */ kfree (chan_name); + + ret =devm_add_action_or_reset (dev, imx_scu_free_mbox_chan, + sc_chan->ch); +if (ret) +return ret; } sc_ipc->dev = dev;
@@ -328,6 +344,9 @@ static int imx_scu_probe(struct platform_device *pdev)init_completion (&sc_ipc->done); imx_sc_ipc_handle = sc_ipc; + ret =devm_add_action_or_reset (dev, imx_scu_clear_handle, sc_ipc); +if (ret) +return ret; ret =imx_scu_soc_init (dev);if (ret)
@@ -340,7 +359,11 @@ static int imx_scu_probe(struct platform_device *pdev)dev_info (dev,"NXP i.MX SCU Initialized\n" ); -return devm_of_platform_populate (dev); + ret =devm_of_platform_populate (dev); +if (ret) +of_platform_depopulate (dev); + +return ret; }static const struct of_device_id imx_scu_match[] = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 138/2214 hsi: omap_ssi: remove debugfs on port creation failure
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 760318e2e69857214314e94ac477219f0c89106b ]
ssi_probe() creates the controller debugfs tree before creating the SSI port child devices. If a port device cannot be created, the error path removes any children and tears down the controller, but leaves the debugfs tree behind.
Remove the controller debugfs tree on the port creation failure path, matching the normal remove path.
--- drivers/hsi/controllers/omap_ssi_core.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/hsi/controllers/omap_ssi_core.c +3 -0
@@ -542,6 +542,9 @@ static int ssi_probe(struct platform_device *pd)return err; out3:device_for_each_child (&pd->dev,NULL , ssi_remove_ports); +#ifdef CONFIG_DEBUG_FS +ssi_debug_remove_ctrl (ssi); +#endif out2:ssi_remove_controller (ssi);pm_runtime_disable (&pd->dev);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 139/2214 iommu/rockchip: Clear stale page faults before enabling stall
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiaxing Hu <[email protected]>
[ Upstream commit b10d5920cafa292ee3cab9c20f813da4fe4f00b8 ]
Boot firmware can leave an IOMMU bank in PAGE_FAULT_ACTIVE before the driver has configured paging:
PAGE_FAULT_ACTIVE=1 STALL_ACTIVE=0 IDLE=1
Such a bank ignores CMD_ENABLE_STALL and never reaches STALL_ACTIVE, so rk_iommu_enable_stall()'s readx_poll_timeout() spins until it times out (seen on the RK3576 NPU, whose MMUs share this poll across banks).
Rather than special-casing these banks in the stall path, acknowledge the stale fault with CMD_PAGE_FAULT_DONE before enabling stall, so every bank starts from a clean state and the normal stall sequence applies to all of them. Banks without a pending fault are untouched.
--- drivers/iommu/rockchip-iommu.c | 13 +++++++++++++ 1 file changed, 13 insertions(+)
drivers/iommu/rockchip-iommu.c +13 -0
@@ -418,6 +418,19 @@ static int rk_iommu_enable_stall(struct rk_iommu *iommu)if (!rk_iommu_is_paging_enabled (iommu))return 0 ; +/* +* Boot firmware can leave a bank in PAGE_FAULT_ACTIVE with no handler +* (PAGE_FAULT_ACTIVE & !STALL_ACTIVE & IDLE). Such a bank ignores +* CMD_ENABLE_STALL and never reaches STALL_ACTIVE, timing out the poll +* below. Acknowledge any stale fault first so every bank starts clean. +*/ +for (i =0 ; i < iommu->num_mmu; i++) { +if (rk_iommu_read (iommu->bases[i],RK_MMU_STATUS ) & +RK_MMU_STATUS_PAGE_FAULT_ACTIVE ) +writel (RK_MMU_CMD_PAGE_FAULT_DONE , + iommu->bases[i] +RK_MMU_COMMAND ); + } +rk_iommu_command (iommu,RK_MMU_CMD_ENABLE_STALL ); ret = readx_poll_timeout(rk_iommu_is_stall_active, iommu, val,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 140/2214 scsi: ibmvfc: check for NULL evt in implicit LOGO and target delete path
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tyrel Datwyler <[email protected]>
[ Upstream commit 0122eab60b151d7815f420a91c7315944a037714 ]
Unlike ibmvfc_tgt_implicit_logout the ibmvfc_tgt_implicit_logout_and_del path fails to check for a NULL evt returned from ibmvfc_get_reserved_event and passes that directly to ibmvfc_send_event which will unconditionally derefence the evt.
Check for a NULL evt and perform same escalation as ibmvfc_implicit_logout.
--- drivers/scsi/ibmvscsi/ibmvfc.c | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/scsi/ibmvscsi/ibmvfc.c +8 -0
@@ -4364,6 +4364,14 @@ static void ibmvfc_tgt_implicit_logout_and_del(struct ibmvfc_target *tgt) evt =__ibmvfc_tgt_get_implicit_logout_evt (tgt, ibmvfc_tgt_implicit_logout_and_del_done); +if (!evt) { + vhost->discovery_threads--; +ibmvfc_set_tgt_action (tgt,IBMVFC_TGT_ACTION_NONE ); +kref_put (&tgt->kref, ibmvfc_release_tgt); +__ibmvfc_reset_host (vhost); +return ; + } +ibmvfc_set_tgt_action (tgt,IBMVFC_TGT_ACTION_LOGOUT_RPORT_WAIT );if (ibmvfc_send_event (evt, vhost, default_timeout)) { vhost->discovery_threads--;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 141/2214 scsi: ibmvfc: free ibmvfc_target allocations with mempool_free
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tyrel Datwyler <[email protected]>
[ Upstream commit 99143433f7f14139ac373c553ec8e1317d0ae58a ]
The ibmvfc_target *tgt structures for discovery are allocated using mempool_alloc but in turn free'd via kfree in ibmvfc_release_target breaking pool guarentees.
Fixup ibmvfc_release_target to call mempool_free instead so that memory is properly returned to the mempool instead of the general allocator.
--- drivers/scsi/ibmvscsi/ibmvfc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/ibmvscsi/ibmvfc.c +1 -1
@@ -1352,7 +1352,7 @@ static void ibmvfc_set_rport_dev_loss_tmo(struct fc_rport *rport, u32 timeout)static void ibmvfc_release_tgt (struct kref *kref) { struct ibmvfc_target *tgt = container_of(kref, struct ibmvfc_target, kref); -kfree (tgt); +mempool_free (tgt, tgt->vhost->tgt_pool); }/**
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 142/2214 udf: Fix bh leak for unallocated space entries
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jan Kara <[email protected]>
[ Upstream commit d95094d4c0a62ea17b8a7c6399b42381b8a55bc0 ]
When processing unallocated space entries we didn't properly release the inode bh. Fix it.
--- fs/udf/inode.c | 1 + 1 file changed, 1 insertion(+)
fs/udf/inode.c +1 -0
@@ -1342,6 +1342,7 @@ static int udf_read_inode(struct inode *inode, bool hidden_inode)memcpy (iinfo->i_data, bh->b_data +sizeof (struct unallocSpaceEntry ), bs -sizeof (struct unallocSpaceEntry )); +brelse (bh);return 0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 143/2214 udf: bound lengthAllocDescs from unallocated space entry
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jay Vadayath <[email protected]>
[ Upstream commit b8228f59dc58aea06dc024efd8f64c2d048c4578 ]
udf_read_inode() copies the on-disk lengthAllocDescs field of a USE (unallocSpaceEntry) inode into iinfo->i_lenAlloc without checking that it fits in the i_data buffer that is subsequently allocated for the inode. udf_count_free_table(), called from udf_statfs(), then walks the allocation descriptor array up to i_lenAlloc bytes, so a crafted UDF image with lengthAllocDescs larger than (blocksize - sizeof(struct unallocSpaceEntry)) causes udf_get_fileshortad() to read past the end of the kmalloc'd i_data buffer.
KASAN report from mounting a crafted UDF image and calling statfs() from an unprivileged process:
BUG: KASAN: slab-out-of-bounds in udf_get_fileshortad+0x126/0x130 Read of size 4 at addr ffff8880042137d8 by task poc/65 Call Trace: dump_stack_lvl+0x53/0x70 print_report+0xce/0x610 kasan_report+0xce/0x100 udf_get_fileshortad+0x126/0x130 udf_current_aext+0x3c4/0xa10 udf_next_aext+0x241/0x440 udf_statfs+0xb7d/0x11c0 statfs_by_dentry+0x117/0x1e0 user_statfs+0xac/0x130 __do_sys_statfs+0x80/0xe0 do_syscall_64+0x102/0x5a0 entry_SYSCALL_64_after_hwframe+0x77/0x7f
Reject USE inodes whose lengthAllocDescs would place descriptors past the end of the i_data buffer, mirroring the checks the rest of the UDF code performs on descriptor lengths.
This bug was discovered by Artiphishell's vTriage pipeline, which generated a userspace reproducer that reliably triggers the KASAN report on an unpatched kernel. The fix below was drafted with the Claude coding assistant; a userspace reproducer (and the crafted UDF image) is available on request.
--- fs/udf/inode.c | 4 ++++ 1 file changed, 4 insertions(+)
fs/udf/inode.c +4 -0
@@ -1335,6 +1335,10 @@ static int udf_read_inode(struct inode *inode, bool hidden_inode) iinfo->i_lenAlloc =le32_to_cpu ( ((struct unallocSpaceEntry *)bh->b_data)-> lengthAllocDescs); +if (iinfo->i_lenAlloc > bs -sizeof (struct unallocSpaceEntry )) { + ret = -EFSCORRUPTED ; + goto out; + } ret =udf_alloc_i_data (inode, bs -sizeof (struct unallocSpaceEntry ));if (ret)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 144/2214 clk: imx: imx8qxp: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit cd21fdcbef3fb32136f72075ab668b075423b3f6 ]
The driver has a match table for the of bus wired into its driver structure, but the table is not exported with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE() entry so module alias information is generated for automatic module loading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the driver registration structure, and the missing module alias publication.
--- drivers/clk/imx/clk-imx8qxp.c | 1 + 1 file changed, 1 insertion(+)
drivers/clk/imx/clk-imx8qxp.c +1 -0
@@ -315,6 +315,7 @@ static const struct of_device_id imx8qxp_match[] = { { .compatible = "fsl,imx8qm-clk", &imx_clk_scu_rsrc_imx8qm, }, {/* sentinel */ } }; +MODULE_DEVICE_TABLE (of, imx8qxp_match);static struct platform_driver imx8qxp_clk_driver = { .driver = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 145/2214 clk: imx: imx8qxp-lpcg: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit e89485455ac49925565061733c0d73d568333fc0 ]
The driver has a match table for the of bus wired into its driver structure, but the table is not exported with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE() entry so module alias information is generated for automatic module loading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the driver registration structure, and the missing module alias publication.
--- drivers/clk/imx/clk-imx8qxp-lpcg.c | 1 + 1 file changed, 1 insertion(+)
drivers/clk/imx/clk-imx8qxp-lpcg.c +1 -0
@@ -359,6 +359,7 @@ static const struct of_device_id imx8qxp_lpcg_match[] = { { .compatible = "fsl,imx8qxp-lpcg", NULL }, {/* sentinel */ } }; +MODULE_DEVICE_TABLE (of, imx8qxp_lpcg_match);static struct platform_driver imx8qxp_lpcg_clk_driver = { .driver = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 146/2214 media: cx88: fix memory leak in cx8802_register_driver() error path
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chen Changcheng <[email protected]>
[ Upstream commit e228b8b1a5b47a72b265671dc6d864c0da5528d0 ]
In cx8802_register_driver(), when drv->probe(driver) fails (non-zero), the allocated cx8802_driver struct is freed neither in the else branch nor later in cx8802_unregister_driver() (which only frees entries that were added to dev->drvlist on success). Each failed probe leaks the driver struct.
Add kfree(driver) in the else branch to fix the leak.
--- drivers/media/pci/cx88/cx88-mpeg.c | 1 + 1 file changed, 1 insertion(+)
drivers/media/pci/cx88/cx88-mpeg.c +1 -0
@@ -640,6 +640,7 @@ int cx8802_register_driver(struct cx8802_driver *drv)list_add_tail (&driver->drvlist, &dev->drvlist); }else {pr_err ("cx8802 probe failed, err = %d\n" , err); +kfree (driver); }mutex_unlock (&drv->core->lock); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 147/2214 clk: tegra: support 48MHz clock for pll_p_out1
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Osipenko <[email protected]>
[ Upstream commit 46e31d69a547530fbef499bde888b6bb45a1deac ]
UEFI on Surface2 sets pll_p_out1 to 48MHz which is not supported by kernel and causes BUG() early on. Add 48MHz clock support for pll_p_out1.
--- drivers/clk/tegra/clk-pll.c | 1 + 1 file changed, 1 insertion(+)
drivers/clk/tegra/clk-pll.c +1 -0
@@ -575,6 +575,7 @@ static int _calc_rate(struct clk_hw *hw, struct tegra_clk_pll_freq_table *cfg,break ;case 9600000 :case 28800000 : +case 48000000 :/* * PLL_P_OUT1 rate is not listed in PLLA table */
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 148/2214 ata: ata_generic: Dont store pci_device_id
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Gary Guo <[email protected]>
[ Upstream commit 4f3075f629077a8cb3d3455c794a1f4a8fc8b43e ]
pci_device_id is not guaranteed to live longer than probe due to presence of dynamic ID. All information apart from driver_data can be easily retrieved from pci_dev, so just store driver_data.
--- drivers/ata/ata_generic.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/ata/ata_generic.c +3 -3
@@ -51,11 +51,11 @@ enum {static int generic_set_mode (struct ata_link *link,struct ata_device **unused) {struct ata_port *ap = link->ap; -const struct pci_device_id *id = ap->host->private_data; +unsigned long driver_data = (unsigned long )ap->host->private_data;int dma_enabled =0 ;struct ata_device *dev; -if (id->driver_data &ATA_GEN_FORCE_DMA ) { +if (driver_data &ATA_GEN_FORCE_DMA ) { dma_enabled =0xff ; }else if (ap->ioaddr.bmdma_addr) {/* Bits 5 and 6 indicate if DMA is active on master/slave */
@@ -206,7 +206,7 @@ static int ata_generic_init_one(struct pci_dev *dev, const struct pci_device_idreturn rc;pcim_pin_device (dev); } -return ata_pci_bmdma_init_one (dev, ppi, &generic_sht, (void *)id,0 ); +return ata_pci_bmdma_init_one (dev, ppi, &generic_sht, (void *)id->driver_data,0 ); }static struct pci_device_id ata_generic[] = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 149/2214 ALSA: hda/conexant: Add NULL check for dc_mode_path
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: wangdicheng <[email protected]>
[ Upstream commit 273806f38ce95c95c288a03d3de1e423cd3e5543 ]
snd_hda_add_new_path() returns NULL when no path exists between the given NIDs, but olpc_xo_update_mic_pins() passes dc_mode_path straight to snd_hda_activate_path() which dereferences it without checking. Add the missing NULL guards, same as the local path variable already has in the same function.
--- sound/pci/hda/patch_conexant.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
sound/pci/hda/patch_conexant.c +4 -2
@@ -467,7 +467,8 @@ static void olpc_xo_update_mic_pins(struct hda_codec *codec)if (!spec->dc_enable) {/* disable DC bias path and pin for port F */ update_mic_pin (codec,0x1e ,0 ); -snd_hda_activate_path (codec, spec->dc_mode_path, false, false); +if (spec->dc_mode_path) +snd_hda_activate_path (codec, spec->dc_mode_path, false, false);/* update port B (ext mic) and C (int mic) */ /* OLPC defers mic widget control until when capture is
@@ -503,7 +504,8 @@ static void olpc_xo_update_mic_pins(struct hda_codec *codec)update_mic_pin (codec,0x1b ,0 );/* enable DC bias path and pin */ update_mic_pin (codec,0x1e , spec->recording ?PIN_IN :0 ); -snd_hda_activate_path (codec, spec->dc_mode_path, true, false); +if (spec->dc_mode_path) +snd_hda_activate_path (codec, spec->dc_mode_path, true, false); } }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 150/2214 exfat: free new directory cluster if zeroing fails
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yichong Chen <[email protected]>
[ Upstream commit ce12a39bed483008683438962b3a605374e6f803 ]
exfat_alloc_new_dir() allocates a cluster for a new directory before zeroing it. If exfat_zeroed_cluster() fails, the function returns the error but leaves the allocated cluster in use.
Free the newly allocated cluster before returning the zeroing error.
--- fs/exfat/dir.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
fs/exfat/dir.c +7 -1
@@ -325,7 +325,13 @@ int exfat_alloc_new_dir(struct inode *inode, struct exfat_chain *clu)if (ret)return ret; -return exfat_zeroed_cluster (inode, clu->dir); + ret =exfat_zeroed_cluster (inode, clu->dir); +if (ret) { +exfat_free_cluster (inode, clu); +return ret; + } + +return 0 ; }int exfat_calc_num_entries (struct exfat_uni_name *p_uniname)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 151/2214 ALSA: hda/realtek: add missing NULL check for codec->bus->pci
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bob Song <[email protected]>
[ Upstream commit 3b36ac93739e7b119a30affaee9c2dd41f24efbb ]
In alc269_probe(), codec->bus->pci is dereferenced without a NULL check for the ALC236 vendor ID case. Add the missing check, consistent with the existing pattern used elsewhere in the same function.
--- sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+)
sound/pci/hda/patch_realtek.c +1 -0
@@ -10479,6 +10479,7 @@ static int patch_alc269(struct hda_codec *codec) spec->init_hook = alc256_init; spec->gen.mixer_nid =0 ;/* ALC256 does not have any loopback mixer path */ if (codec->core.vendor_id ==0x10ec0236 && + codec->bus->pci && codec->bus->pci->vendor !=PCI_VENDOR_ID_AMD ) spec->en_3kpull_low = false;break ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 152/2214 fs/ntfs3: Fix memory leak in indx_find_sort()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Konstantin Komarov <[email protected]>
[ Upstream commit 194491be54e1c9e4d29d3ee777b05ff031c4b670 ]
When popping a level from the index lookup stack, indx_find_sort() frees the struct indx_node but not the index buffer it owns. Every call that descends and then pops a level leaks that allocation.
Free n->index before freeing the node itself.
--- fs/ntfs3/index.c | 1 + 1 file changed, 1 insertion(+)
fs/ntfs3/index.c +1 -0
@@ -1332,6 +1332,7 @@ int indx_find_sort(struct ntfs_index *indx, struct ntfs_inode *ni,/* Pop one level. */ if (n) {fnd_pop (fnd); +kfree (n->index);kfree (n); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 153/2214 mfd: ipaq-micro: Fix out-of-bounds stack read in ipaq_micro_str
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmitry Torokhov <[email protected]>
[ Upstream commit da3a98c941753255418616d249e5b40db0927c26 ]
ipaq_micro_str() decodes a UTF-16LE string into an ASCII string. It copies characters to a stack buffer retstr, but fails to null-terminate it. When kstrdup() is called on retstr, it can read past the buffer into uninitialized stack memory, potentially leaking stack contents.
Fix this by initializing retstr to zero.
--- drivers/mfd/ipaq-micro.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mfd/ipaq-micro.c +1 -1
@@ -224,7 +224,7 @@ static void ipaq_micro_eeprom_read(struct ipaq_micro *micro,static char *ipaq_micro_str (u8 *wchar,u8 len) { -char retstr[256 ]; +char retstr[256 ] = {0 };u8 i;for (i =0 ; i < len /2 ; i++)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 154/2214 ALSA: hda/realtek: add missing error checks for COEF index reads in alc269
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bob Song <[email protected]>
[ Upstream commit 5b106b40ed22098f2bc049efb645148d038444bd ]
alc_read_coef_idx() and alc_read_coefex_idx() can return -1 on error via snd_hda_codec_read(). Several codec initialization and shutdown functions save these return values and later write them back to hardware registers without checking for errors, potentially corrupting COEF register state on a read failure.
Add error checks in:
- alc282_init() and alc282_shutup(): check coef78 before write-back
- alc285_hp_init(): check coef38/coef0d/coef36 before update, check val before write-back, and break polling loop on error
- alc294_hp_init(): break polling loop on read error
--- sound/pci/hda/patch_realtek.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-)
sound/pci/hda/patch_realtek.c +14 -8
@@ -3420,7 +3420,8 @@ static void alc282_init(struct hda_codec *codec)msleep (100 );/* Headphone capless set to normal mode */ -alc_write_coef_idx (codec,0x78 , coef78); +if (coef78 !=-1 ) +alc_write_coef_idx (codec,0x78 , coef78); }static void alc282_shutup (struct hda_codec *codec)
@@ -3457,7 +3458,8 @@ static void alc282_shutup(struct hda_codec *codec)alc_auto_setup_eapd (codec, false);alc_shutup_pins (codec); -alc_write_coef_idx (codec,0x78 , coef78); +if (coef78 !=-1 ) +alc_write_coef_idx (codec,0x78 , coef78); }static const struct coef_fw alc283_coefs[] = {
@@ -3709,15 +3711,19 @@ static void alc285_hp_init(struct hda_codec *codec)alc_write_coefex_idx (codec,0x58 ,0x00 ,0xf888 );/* HP depop procedure start */ val =alc_read_coefex_idx (codec,0x58 ,0x00 ); -for (i =0 ; i <20 && val &0x8000 ; i++) { +for (i =0 ; i <20 && val !=-1 && val &0x8000 ; i++) {msleep (50 ); val =alc_read_coefex_idx (codec,0x58 ,0x00 ); }/* Wait for depop procedure finish */ -alc_write_coefex_idx (codec,0x58 ,0x00 , val);/* write back the result */ -alc_update_coef_idx (codec,0x38 ,1 <<4 , coef38); -alc_update_coef_idx (codec,0x0d ,0x110 , coef0d); -alc_update_coef_idx (codec,0x36 ,3 <<13 , coef36); +if (val !=-1 ) +alc_write_coefex_idx (codec,0x58 ,0x00 , val);/* write back the result */ +if (coef38 !=-1 ) +alc_update_coef_idx (codec,0x38 ,1 <<4 , coef38); +if (coef0d !=-1 ) +alc_update_coef_idx (codec,0x0d ,0x110 , coef0d); +if (coef36 !=-1 ) +alc_update_coef_idx (codec,0x36 ,3 <<13 , coef36);msleep (50 );alc_update_coef_idx (codec,0x4a ,1 <<15 ,0 );
@@ -3982,7 +3988,7 @@ static void alc294_hp_init(struct hda_codec *codec)/* Wait for depop procedure finish */ val =alc_read_coefex_idx (codec,0x58 ,0x01 ); -for (i =0 ; i <20 && val &0x0080 ; i++) { +for (i =0 ; i <20 && val !=-1 && val &0x0080 ; i++) {msleep (50 ); val =alc_read_coefex_idx (codec,0x58 ,0x01 ); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 155/2214 regulator: rt6245: Restore state on enable failure
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: bui duc phuc <[email protected]>
[ Upstream commit e95a0a309ca02bf26dc937cdeb3fe2a235c65f63 ]
Currently, if regcache_sync() fails after the enable GPIO has been asserted, the driver returns with enable_gpio still set high and regcache_cache_only() left disabled. This leaves the device state inconsistent with the disabled state, where the enable GPIO is low and cache_only is enabled.
On failure, restore the original state by setting cache_only back to true and driving the enable GPIO low before returning the error.
--- drivers/regulator/rt6245-regulator.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/regulator/rt6245-regulator.c +4 -1
@@ -49,8 +49,11 @@ static int rt6245_enable(struct regulator_dev *rdev)regcache_cache_only (regmap, false); ret =regcache_sync (regmap); -if (ret) +if (ret) { +regcache_cache_only (regmap, true); +gpiod_direction_output (priv->enable_gpio,0 );return ret; + } priv->enable_state = true;return 0 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 156/2214 romfs: detect hard link cycles
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: 이상호 <[email protected]>
[ Upstream commit d30b5a954e0a4dcc16bba9c310c13709a6169a52 ]
romfs_iget() follows on-disk hard link entries until it reaches a non-hard link inode:
pos = be32_to_cpu(ri.spec) & ROMFH_MASK;
The target position is image-controlled, and the loop does not detect cycles. A crafted romfs image can make the root inode a hard link. The hard link can point back to itself and leave mount(2) spinning in the kernel.
Reject excessive hard link indirection with -ELOOP. Normal romfs images do not need long hard link chains. This bounds corrupted-image traversal. Propagate romfs_iget() errors from lookup because hard link traversal can now fail with -ELOOP.
--- fs/romfs/super.c | 8 ++++++++ 1 file changed, 8 insertions(+)
fs/romfs/super.c +8 -0
@@ -249,6 +249,8 @@ static struct dentry *romfs_lookup(struct inode *dir, struct dentry *dentry,if ((be32_to_cpu (ri.next) &ROMFH_TYPE ) ==ROMFH_HRD ) offset =be32_to_cpu (ri.spec) &ROMFH_MASK ; inode =romfs_iget (dir->i_sb, offset); +if (IS_ERR (inode)) +return ERR_CAST (inode);break ; }
@@ -271,6 +273,8 @@ static const struct inode_operations romfs_dir_inode_operations = { .lookup = romfs_lookup, }; +#define ROMFS_MAX_HARDLINK_DEPTH 64 +/* * get a romfs inode based on its position in the image (which doubles as the * inode number)
@@ -282,6 +286,7 @@ static struct inode *romfs_iget(struct super_block *sb, unsigned long pos)struct inode *i;unsigned long nlen;unsigned nextfh; +unsigned int depth =0 ;int ret;umode_t mode;
@@ -298,6 +303,9 @@ static struct inode *romfs_iget(struct super_block *sb, unsigned long pos)if ((nextfh &ROMFH_TYPE ) !=ROMFH_HRD )break ; +if (++depth >ROMFS_MAX_HARDLINK_DEPTH ) +return ERR_PTR (-ELOOP ); + pos =be32_to_cpu (ri.spec) &ROMFH_MASK ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 157/2214 virtio_console: take a kref in find_port_by_vq() to fix port UAF
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Hari Mishal <[email protected]>
[ Upstream commit 18dd0b4e489e4f0e3b748cf36ccb909c75a3efab ]
find_port_by_vq() returns a raw struct port pointer without taking a reference on it, unlike find_port_by_devt_in_portdev() which does. find_port_by_vq()'s only two callers, in_intr() and out_intr(), run as virtqueue interrupt callbacks, entirely independent of and possibly concurrently with unplug_port(), which itself runs from a workqueue when the host sends a VIRTIO_CONSOLE_PORT_REMOVE control message.
unplug_port() removes the port from portdev->ports under ports_lock, then later drops its last reference with kref_put(), freeing it via remove_port(). find_port_by_vq() also walks portdev->ports under ports_lock, so if it finds the port still on the list, the list removal, and therefore the eventual kref_put(), has not happened yet, and taking a reference at that point is always safe. Without doing so, in_intr()/out_intr() can be left holding a pointer to a port that unplug_port() frees on another core before they are done using it.
Both triggers are host-controlled as the host decides when to send the PORT_REMOVE control message and when to kick the port's data vq. So a malicious backend could race the two on purpose, without any guest side cooperation. The freed object is a generic kmalloc allocation containing a wait_queue_head_t, which in_intr()/out_intr() pass to wake_up_interruptible() after touching the stale pointer. wake_up_interruptible() invokes a function pointer read out of the wait queue's entries. If the freed slab slot is reclaimed with attacker influenced content before that call, then this is an arbitrary function call primitive rather than just undefined behaviour.
Take a reference in find_port_by_vq() while still holding ports_lock, matching find_port_by_devt_in_portdev(), and release it in in_intr() and out_intr() once they are done with the port.
--- drivers/char/virtio_console.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-)
drivers/char/virtio_console.c +12 -1
@@ -312,6 +312,12 @@ static struct port *find_port_by_id(struct ports_device *portdev, u32 id)return port; } +/* +* Finds a port by the virtqueue and returns a pointer to struct port +* with the reference count incremented. +* +* Callers MUST decrement it when finished. +*/ static struct port *find_port_by_vq (struct ports_device *portdev,struct virtqueue *vq) {
@@ -320,8 +326,10 @@ static struct port *find_port_by_vq(struct ports_device *portdev,spin_lock_irqsave (&portdev->ports_lock, flags);list_for_each_entry (port, &portdev->ports, list) -if (port->in_vq == vq || port->out_vq == vq) +if (port->in_vq == vq || port->out_vq == vq) { +kref_get (&port->kref); goto out; + } port =NULL ; out:spin_unlock_irqrestore (&portdev->ports_lock, flags);
@@ -1745,6 +1753,7 @@ static void out_intr(struct virtqueue *vq) }wake_up_interruptible (&port->waitqueue); +kref_put (&port->kref, remove_port); }static void in_intr (struct virtqueue *vq)
@@ -1790,6 +1799,8 @@ static void in_intr(struct virtqueue *vq)if (is_console_port (port) &&hvc_poll (port->cons.hvc))hvc_kick (); + +kref_put (&port->kref, remove_port); }static void control_intr (struct virtqueue *vq)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 158/2214 wifi: mt76: mt7603: free beacon SKB on error
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: David Bauer <[email protected]>
[ Upstream commit 965cbdbdfbd37a659a05ff88e49c216975bd9d2e ]
The SKB containing the generated beacon is not freed when the beacon queue is deected stuck and scheduled for recovery.
Fixes potential memory leaks in case the beacon queue is detected stuck.
--- drivers/net/wireless/mediatek/mt76/mt7603/beacon.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/wireless/mediatek/mt76/mt7603/beacon.c +2 -0
@@ -56,6 +56,7 @@ mt7603_update_beacon_iter(void *priv, u8 *mac, struct ieee80211_vif *vif) FIELD_PREP(MT_DMA_FQCR0_TARGET_QID, MT_TX_HW_QUEUE_BCN));if (!mt76_poll (dev,MT_DMA_FQCR0 ,MT_DMA_FQCR0_BUSY ,0 ,5000 )) { dev->beacon_check =MT7603_WATCHDOG_TIMEOUT ; +dev_kfree_skb (skb); goto out; }
@@ -63,6 +64,7 @@ mt7603_update_beacon_iter(void *priv, u8 *mac, struct ieee80211_vif *vif) FIELD_PREP(MT_DMA_FQCR0_TARGET_QID, MT_TX_HW_QUEUE_BMC));if (!mt76_poll (dev,MT_DMA_FQCR0 ,MT_DMA_FQCR0_BUSY ,0 ,5000 )) { dev->beacon_check =MT7603_WATCHDOG_TIMEOUT ; +dev_kfree_skb (skb); goto out; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 159/2214 wifi: mt76: mt76x02: report rx FCS errors to mac80211
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Devin Wittmayer <[email protected]>
[ Upstream commit ddae0bcb01e71c1184bb3f526f9622e31dc38f3b ]
When the fcsfail filter is enabled the hardware passes frames with a bad FCS up to the driver, but mt76x02_mac_process_rx() never checks MT_RXINFO_CRCERR and hands them to mac80211 without RX_FLAG_FAILED_FCS_CRC. In monitor mode the radiotap flags byte then never gets IEEE80211_RADIOTAP_F_BADFCS set and corrupted frames cannot be told apart from clean ones.
Set RX_FLAG_FAILED_FCS_CRC from the descriptor CRC error bit, matching mt7603, mt7615, mt7915, mt7921, mt7925 and mt7996.
--- drivers/net/wireless/mediatek/mt76/mt76x02_mac.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/wireless/mediatek/mt76/mt76x02_mac.c +3 -0
@@ -794,6 +794,9 @@ int mt76x02_mac_process_rx(struct mt76x02_dev *dev, struct sk_buff *skb,if (rxinfo &MT_RXINFO_L2PAD ) pad_len +=2 ; +if (rxinfo &MT_RXINFO_CRCERR ) + status->flag |=RX_FLAG_FAILED_FCS_CRC ; +if (rxinfo &MT_RXINFO_DECRYPT ) { status->flag |=RX_FLAG_DECRYPTED ; status->flag |=RX_FLAG_MMIC_STRIPPED ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 160/2214 wifi: mt76: mt7603: add 0x7592 EEPROM chip ID
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ahmed Naseef <[email protected]>
[ Upstream commit d16447d7470502e998d82e806ca7ed49d1baa853 ]
Some EcoNet based routers ship an on-flash EEPROM whose chip-id is 0x7592 instead of the expected 0x7603. The device probes as PCI 14c3:7603 and the hardware MT_HW_CHIPID register reports 0x7603, independent of the EEPROM value.
This is seen across multiple EcoNet EN751221 and EN7528 based devices (for example the Genexis Platinum 4410).
--- drivers/net/wireless/mediatek/mt76/mt7603/eeprom.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/wireless/mediatek/mt76/mt7603/eeprom.c +1 -0
@@ -142,6 +142,7 @@ static int mt7603_check_eeprom(struct mt76_dev *dev)case 0x7628 :case 0x7603 :case 0x7600 : +case 0x7592 :return 0 ;default :return -EINVAL ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 161/2214 netfilter: conntrack: tcp: use UNACK timeout for non-closing RST packets
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Minghao Zhang <[email protected]>
[ Upstream commit bf80e6802273a900311b44e47c9b1a59c6d2473c ]
Commit be0502a3f2e9 ("netfilter: conntrack: tcp: only close if RST matches exact sequence") keeps an established conntrack entry in ESTABLISHED when an in-window RST does not match the expected sequence number exactly, so the endpoint can validate the RST with a challenge ACK.
The timeout selection nevertheless uses the CLOSE timeout for every RST packet. The bug is that timeout selection is based on the packet type, not on the state transition result: even when RST validation keeps new_state in ESTABLISHED, the timeout is still forced to TCP_CONNTRACK_CLOSE.
Linux TCP independently rate limits challenge ACKs per socket. A second non-exact RST can therefore arrive after the first challenge ACK has restored the timeout but before the rate limit expires. The second RST lowers the timeout to 10 seconds again while the endpoint suppresses the second challenge ACK, allowing the conntrack entry to expire while both TCP endpoints remain established.
Using the ESTABLISHED timeout for such RSTs would avoid this short expiration window, but it could also retain stale entries for the five-day default because conntrack cannot reliably match the endpoint's exact TCP state.
Use the UNACK timeout for RST packets that leave the conntrack entry in TCP_CONNTRACK_ESTABLISHED. Exact-match RSTs and accepted RST packet trains still fall through to timeouts[new_state], which preserves the CLOSE timeout when conntrack accepts the RST as closing the flow.
This avoids the aggressive 10-second expiration window for non-exact RSTs while preserving the short timeout for RSTs that conntrack accepts as closing the flow.
--- net/netfilter/nf_conntrack_proto_tcp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
net/netfilter/nf_conntrack_proto_tcp.c +3 -2
@@ -1221,8 +1221,9 @@ int nf_conntrack_tcp_packet(struct nf_conn *ct,if (ct->proto.tcp.retrans >= tn->tcp_max_retrans && timeouts[new_state] > timeouts[TCP_CONNTRACK_RETRANS ]) timeout = timeouts[TCP_CONNTRACK_RETRANS ]; -else if (unlikely (index ==TCP_RST_SET )) - timeout = timeouts[TCP_CONNTRACK_CLOSE ]; +else if (unlikely (index ==TCP_RST_SET && + new_state ==TCP_CONNTRACK_ESTABLISHED )) + timeout = timeouts[TCP_CONNTRACK_UNACK ];else if ((ct->proto.tcp.seen[0 ].flags | ct->proto.tcp.seen[1 ].flags) &IP_CT_TCP_FLAG_DATA_UNACKNOWLEDGED && timeouts[new_state] > timeouts[TCP_CONNTRACK_UNACK ])
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 162/2214 netfilter: nf_tables: call skb_valid_dst() before skb_dst()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pablo Neira Ayuso <[email protected]>
[ Upstream commit 689db98e535bf8efb5bc9c36f4fd3de3bd715eb6 ]
When fetching the dst_entry from the skb, check if it valid, ie. this is not a template dst, for extensions that can be used from the netdev ingress and egress chains.
--- net/ipv4/netfilter/nf_reject_ipv4.c | 6 ++++-- net/ipv6/netfilter/nf_reject_ipv6.c | 8 ++++++-- net/netfilter/nft_meta.c | 6 ++++-- net/netfilter/nft_rt.c | 6 ++++-- net/netfilter/nft_xfrm.c | 9 ++++++++- 5 files changed, 26 insertions(+), 9 deletions(-)
net/ipv4/netfilter/nf_reject_ipv4.c +4 -2
@@ -8,6 +8,7 @@#include <net/tcp.h> #include <net/route.h> #include <net/dst.h> +#include <net/dst_metadata.h> #include <net/netfilter/ipv4/nf_reject.h> #include <linux/netfilter_ipv4.h> #include <linux/netfilter_bridge.h>
@@ -254,6 +255,7 @@ static int nf_reject_fill_skb_dst(struct sk_buff *skb_in)if (!dst)return -1 ; +skb_dst_drop (skb_in);skb_dst_set (skb_in, dst);return 0 ; }
@@ -272,7 +274,7 @@ void nf_send_reset(struct net *net, struct sock *sk, struct sk_buff *oldskb,if (!oth)return ; -if (!skb_dst (oldskb) &&nf_reject_fill_skb_dst (oldskb) <0 ) +if (!skb_valid_dst (oldskb) &&nf_reject_fill_skb_dst (oldskb) <0 )return ;if (skb_rtable (oldskb)->rt_flags & (RTCF_BROADCAST |RTCF_MULTICAST ))
@@ -341,7 +343,7 @@ void nf_send_unreach(struct sk_buff *skb_in, int code, int hook)if (iph->frag_off &htons (IP_OFFSET ))return ; -if (!skb_dst (skb_in) &&nf_reject_fill_skb_dst (skb_in) <0 ) +if (!skb_valid_dst (skb_in) &&nf_reject_fill_skb_dst (skb_in) <0 )return ;if (skb_csum_unnecessary (skb_in) || !nf_reject_verify_csum (proto)) {
net/ipv6/netfilter/nf_reject_ipv6.c +6 -2
@@ -8,6 +8,7 @@#include <net/ip6_route.h> #include <net/ip6_fib.h> #include <net/ip6_checksum.h> +#include <net/dst_metadata.h> #include <net/netfilter/ipv6/nf_reject.h> #include <linux/netfilter_ipv6.h> #include <linux/netfilter_bridge.h>
@@ -291,6 +292,7 @@ static int nf_reject6_fill_skb_dst(struct sk_buff *skb_in)if (!dst)return -1 ; +skb_dst_drop (skb_in);skb_dst_set (skb_in, dst);return 0 ; }
@@ -325,10 +327,12 @@ void nf_send_reset6(struct net *net, struct sock *sk, struct sk_buff *oldskb, fl6.fl6_sport = otcph->dest; fl6.fl6_dport = otcph->source; -if (!skb_dst (oldskb)) { +if (!skb_valid_dst (oldskb)) {nf_ip6_route (net, &dst,flowi6_to_flowi (&fl6), false);if (!dst)return ; + +skb_dst_drop (oldskb);skb_dst_set (oldskb, dst); }
@@ -424,7 +428,7 @@ void nf_send_unreach6(struct net *net, struct sk_buff *skb_in,if (hooknum ==NF_INET_LOCAL_OUT && skb_in->dev ==NULL ) skb_in->dev = net->loopback_dev; -if (!skb_dst (skb_in) &&nf_reject6_fill_skb_dst (skb_in) <0 ) +if (!skb_valid_dst (skb_in) &&nf_reject6_fill_skb_dst (skb_in) <0 )return ;icmpv6_send (skb_in,ICMPV6_DEST_UNREACH , code,0 );
net/netfilter/nft_meta.c +4 -2
@@ -20,6 +20,7 @@#include <net/dst.h> #include <net/ip.h> #include <net/sock.h> +#include <net/dst_metadata.h> #include <net/tcp_states.h> /* for TCP_TIME_WAIT */ #include <net/netfilter/nf_tables.h> #include <net/netfilter/nf_tables_core.h>
@@ -270,11 +271,12 @@ static bool nft_meta_get_eval_ifname(enum nft_meta_keys key, u32 *dest, static noinline boolnft_meta_get_eval_rtclassid (const struct sk_buff *skb,u32 *dest) { -const struct dst_entry *dst =skb_dst (skb); +const struct dst_entry *dst; -if (!dst) +if (!skb_valid_dst (skb))return false; + dst =skb_dst (skb); *dest = dst->tclassid;return true; }
net/netfilter/nft_rt.c +4 -2
@@ -8,6 +8,7 @@#include <linux/netfilter.h> #include <linux/netfilter/nf_tables.h> #include <net/dst.h> +#include <net/dst_metadata.h> #include <net/ip6_route.h> #include <net/route.h> #include <net/netfilter/nf_tables.h>
@@ -59,10 +60,11 @@ void nft_rt_get_eval(const struct nft_expr *expr,u32 *dest = ®s->data[priv->dreg];const struct dst_entry *dst; - dst =skb_dst (skb); -if (!dst) +if (!skb_valid_dst (skb)) goto err; + dst =skb_dst (skb); +switch (priv->key) {#ifdef CONFIG_IP_ROUTE_CLASSID case NFT_RT_CLASSID :
net/netfilter/nft_xfrm.c +8 -1
@@ -12,6 +12,7 @@#include <linux/netfilter/nf_tables.h> #include <net/netfilter/nf_tables_core.h> #include <net/netfilter/nf_tables.h> +#include <net/dst_metadata.h> #include <linux/in.h> #include <net/xfrm.h>
@@ -174,9 +175,15 @@ static void nft_xfrm_get_eval_out(const struct nft_xfrm *priv,struct nft_regs *regs, const struct nft_pktinfo *pkt) { - const struct dst_entry *dst = skb_dst(pkt->skb); + const struct dst_entry *dst;int i; +if (!skb_valid_dst (pkt->skb)) { + regs->verdict.code =NFT_BREAK ; +return ; + } + + dst =skb_dst (pkt->skb);for (i =0 ; dst && dst->xfrm; dst = ((const struct xfrm_dst *)dst)->child, i++) {if (i < priv->spnum)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 163/2214 wifi: mt76: set the EOSP bit in the QoS header of the last released frame
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Felix Fietkau <[email protected]>
[ Upstream commit 0b8d2524716099ea4743fa65bc364f94b3106a31 ]
When the driver implements .release_buffered_frames, mac80211 leaves the U-APSD signalling entirely to the driver: "In this case it is also responsible for setting the EOSP flag in the QoS header of the frames" (include/net/mac80211.h). Only IEEE80211_TX_STATUS_EOSP was being set, which merely ends the service period inside mac80211, so on air the service period was never terminated. Clients that wait for EOSP before going back to doze keep the SP open and stop triggering, which stalls all downlink traffic for that station.
Set the wire EOSP bit on the last frame of a U-APSD service period. EOSP has no meaning for a PS-Poll response, so pass the release reason down and leave those frames alone.
--- drivers/net/wireless/mediatek/mt76/tx.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
drivers/net/wireless/mediatek/mt76/tx.c +12 -4
@@ -343,16 +343,23 @@ mt76_txq_dequeue(struct mt76_phy *phy, struct mt76_txq *mtxq)static void mt76_queue_ps_skb (struct mt76_phy *phy,struct ieee80211_sta *sta, -struct sk_buff *skb,bool last) +struct sk_buff *skb,bool last, +enum ieee80211_frame_release_type reason) {struct mt76_wcid *wcid = (struct mt76_wcid *)sta->drv_priv;struct ieee80211_tx_info *info =IEEE80211_SKB_CB (skb); +struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; info->control.flags |=IEEE80211_TX_CTRL_PS_RESPONSE ; -if (last) +if (last) { info->flags |=IEEE80211_TX_STATUS_EOSP |IEEE80211_TX_CTL_REQ_TX_STATUS ; +if (reason ==IEEE80211_FRAME_RELEASE_UAPSD && +ieee80211_is_data_qos (hdr->frame_control)) + *ieee80211_get_qos_ctl (hdr) |=IEEE80211_QOS_CTL_EOSP ; + } +mt76_skb_set_moredata (skb, !last);__mt76_tx_queue_skb (phy,MT_TXQ_PSD , skb, wcid, sta,NULL ); }
@@ -385,14 +392,15 @@ mt76_release_buffered_frames(struct ieee80211_hw *hw, struct ieee80211_sta *sta, nframes--;if (last_skb) -mt76_queue_ps_skb (phy, sta, last_skb, false); +mt76_queue_ps_skb (phy, sta, last_skb, false, + reason); last_skb = skb; }while (nframes); }if (last_skb) { -mt76_queue_ps_skb (phy, sta, last_skb, true); +mt76_queue_ps_skb (phy, sta, last_skb, true, reason); dev->queue_ops->kick (dev, hwq); }else {ieee80211_sta_eosp (sta);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 164/2214 wifi: mt76: mt7603: fix U-APSD service period termination
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Felix Fietkau <[email protected]>
[ Upstream commit 697badc27a9b3b2a8d86092abeed767714f735a2 ]
Frames released from the driver PS queue were all tagged with MORE_DATA and none of them ever carried the EOSP bit, so from the client's point of view a U-APSD service period was started but never finished. Clients that keep their receiver on until EOSP arrives stop sending trigger frames, and all downlink traffic for that station stalls until they give up. ieee80211_sta_eosp() only cleared the service period state inside mac80211, which is why the mismatch went unnoticed.
Assign MORE_DATA per frame and set the wire EOSP bit on the last one. If the last released frame is a bufferable MMPDU it has no QoS control field to carry EOSP, so let mac80211 append a QoS-Null frame instead.
Also stop handing the remaining frame budget to mt76_release_buffered_frames() once frames have been released from the PS
queue: both would signal the end of the same service period. Releasing fewer frames than requested is allowed, and MORE_DATA tells the client to trigger again.
--- .../net/wireless/mediatek/mt76/mt7603/main.c | 74 ++++++++++++++++--- 1 file changed, 63 insertions(+), 11 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7603/main.c +63 -11
@@ -408,13 +408,33 @@ mt7603_sta_ps(struct mt76_dev *mdev, struct ieee80211_sta *sta, bool ps)mt7603_ps_tx_list (dev, &list); } +static struct ieee80211_hdr * +mt7603_ps_skb_hdr (struct sk_buff *skb) +{ +return (struct ieee80211_hdr *)&skb->data[MT_TXD_SIZE ]; +} + +/* +* Buffered frames can be recycled into the PS queue by mt7603_filter_tx(), so +* both bits have to be assigned, not just set. +*/ static void -mt7603_ps_set_more_data (struct sk_buff *skb) +mt7603_ps_set_flags (struct sk_buff *skb,bool more_data,bool eosp) { -struct ieee80211_hdr *hdr; +struct ieee80211_hdr *hdr =mt7603_ps_skb_hdr (skb); + +if (more_data) + hdr->frame_control |=cpu_to_le16 (IEEE80211_FCTL_MOREDATA ); +else + hdr->frame_control &= ~cpu_to_le16 (IEEE80211_FCTL_MOREDATA ); + +if (!ieee80211_is_data_qos (hdr->frame_control)) +return ; - hdr = (struct ieee80211_hdr *)&skb->data[MT_TXD_SIZE ]; - hdr->frame_control |=cpu_to_le16 (IEEE80211_FCTL_MOREDATA ); +if (eosp) + *ieee80211_get_qos_ctl (hdr) |=IEEE80211_QOS_CTL_EOSP ; +else + *ieee80211_get_qos_ctl (hdr) &= ~IEEE80211_QOS_CTL_EOSP ; } static void
@@ -427,7 +447,10 @@ mt7603_release_buffered_frames(struct ieee80211_hw *hw,struct mt7603_dev *dev = hw->priv;struct mt7603_sta *msta = (struct mt7603_sta *)sta->drv_priv;struct sk_buff_head list; -struct sk_buff *skb, *tmp; +struct sk_buff *skb, *tmp, *last; +bool eosp_null, uapsd; +u16 pending =0 ; +u8 last_tid;__skb_queue_head_init (&list);
@@ -443,20 +466,49 @@ mt7603_release_buffered_frames(struct ieee80211_hw *hw,skb_set_queue_mapping (skb,MT_TXQ_PSD );__skb_unlink (skb, &msta->psq); -mt7603_ps_set_more_data (skb);__skb_queue_tail (&list, skb); nframes--; } + +skb_queue_walk (&msta->psq, skb) + pending |= BIT(skb->priority);spin_unlock_bh (&dev->ps_lock); -if (!skb_queue_empty (&list)) -ieee80211_sta_eosp (sta); + last =skb_peek_tail (&list); +if (!last) { +mt76_release_buffered_frames (hw, sta, tids, nframes, reason, + more_data); +return ; + } + +/* +* End the service period here instead of passing the remaining frame +* budget on to mt76_release_buffered_frames(), which would signal the +* end of the same service period a second time. +*/ + uapsd = reason ==IEEE80211_FRAME_RELEASE_UAPSD ; + more_data |= !!(pending & tids); + + skb_queue_walk(&list, skb) +mt7603_ps_set_flags (skb, skb != last || more_data, + skb == last && uapsd); + +/* +* EOSP lives in the QoS control field, so a bufferable MMPDU cannot +* terminate a U-APSD service period on its own. In that case mac80211 +* has to append a QoS-Null frame, which ends the SP through its tx +* status. +*/ + eosp_null = uapsd && + !ieee80211_is_data_qos (mt7603_ps_skb_hdr (last)->frame_control); + last_tid =__fls (tids);mt7603_ps_tx_list (dev, &list); -if (nframes) -mt76_release_buffered_frames (hw, sta, tids, nframes, reason, - more_data); +if (eosp_null) +ieee80211_send_eosp_nullfunc (sta, last_tid); +else +ieee80211_sta_eosp (sta); } static int
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 165/2214 wifi: brcmfmac: Set DMA direction for msgbuf packet IDs
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Can Peng <[email protected]>
[ Upstream commit f0ba5fd51ff23077ce66cb9be79d41a4b7c19c5e ]
brcmf_msgbuf_init_pktids() takes the DMA direction from its callers, but never stores it in the packet ID state. Since the state is zeroed, pktids->direction remains DMA_BIDIRECTIONAL for both the TX and RX packet ID pools.
All msgbuf packet ID map and unmap paths use pktids->direction. As a result, TX buffers requested with DMA_TO_DEVICE and RX buffers requested with DMA_FROM_DEVICE are mapped and unmapped as DMA_BIDIRECTIONAL instead.
Store the caller-provided direction when initializing the packet ID state.
--- drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c +1 -0
@@ -309,6 +309,7 @@ brcmf_msgbuf_init_pktids(u32 nr_array_entries, } pktids->array = array; pktids->array_size = nr_array_entries; + pktids->direction = direction;return pktids; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 166/2214 wifi: brcmfmac: validate msgbuf flowring IDs before use
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Can Peng <[email protected]>
[ Upstream commit 32856f39fefdc75bd253cab999f996750628648e ]
Firmware messages carry flow_ring_id values which brcmfmac converts to an internal flowid by subtracting BRCMF_H2D_MSGRING_FLOWRING_IDSTART. The resulting value is used as a bit index in txstatus_done_map and as an array index into msgbuf->flowrings and the flowring state.
Validate the firmware supplied flow_ring_id before using it. This prevents flow_ring_id values below BRCMF_H2D_MSGRING_FLOWRING_IDSTART from underflowing and rejects values outside msgbuf->max_flowrings.
In the tx status path, complete the packet with an error after removing a valid packet id so the skb is not leaked when the flow ring id is invalid.
--- .../broadcom/brcm80211/brcmfmac/msgbuf.c | 46 ++++++++++++++++--- 1 file changed, 40 insertions(+), 6 deletions(-)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c +40 -6
@@ -561,6 +561,28 @@ brcmf_msgbuf_remove_flowring(struct brcmf_msgbuf *msgbuf, u16 flowid)brcmf_flowring_delete (msgbuf->flow, flowid); } +static bool brcmf_msgbuf_get_flowid (struct brcmf_msgbuf *msgbuf, +u16 flow_ring_id,u16 *flowid) +{ +u32 id = flow_ring_id; + +if (id <BRCMF_H2D_MSGRING_FLOWRING_IDSTART ) { +bphy_err (msgbuf->drvr,"invalid flowring id %u\n" , + flow_ring_id); +return false; + } + + id -=BRCMF_H2D_MSGRING_FLOWRING_IDSTART ; +if (id >= msgbuf->max_flowrings) { +bphy_err (msgbuf->drvr,"invalid flowring id %u\n" , + flow_ring_id); +return false; + } + + *flowid = id; +return true; +} +static struct brcmf_msgbuf_work_item *brcmf_msgbuf_dequeue_work (struct brcmf_msgbuf *msgbuf)
@@ -877,17 +899,23 @@ brcmf_msgbuf_process_txstatus(struct brcmf_msgbuf *msgbuf, void *buf)struct msgbuf_tx_status *tx_status;u32 idx;struct sk_buff *skb; +u16 flow_ring_id;u16 flowid; tx_status = (struct msgbuf_tx_status *)buf; idx =le32_to_cpu (tx_status->msg.request_id) -1 ; - flowid =le16_to_cpu (tx_status->compl_hdr.flow_ring_id); - flowid -=BRCMF_H2D_MSGRING_FLOWRING_IDSTART ; + flow_ring_id =le16_to_cpu (tx_status->compl_hdr.flow_ring_id); skb =brcmf_msgbuf_get_pktid (msgbuf->drvr->bus_if->dev, msgbuf->tx_pktids, idx);if (!skb)return ; +if (!brcmf_msgbuf_get_flowid (msgbuf, flow_ring_id, &flowid)) { +brcmf_txfinalize (brcmf_get_ifp (msgbuf->drvr, tx_status->msg.ifidx), + skb, false); +return ; + } +set_bit (flowid, msgbuf->txstatus_done_map); commonring = msgbuf->flowrings[flowid];atomic_dec (&commonring->outstanding_tx);
@@ -1234,13 +1262,16 @@ brcmf_msgbuf_process_flow_ring_create_response(struct brcmf_msgbuf *msgbuf,struct msgbuf_flowring_create_resp *flowring_create_resp;u16 status;u16 flowid; +u16 flow_ring_id; flowring_create_resp = (struct msgbuf_flowring_create_resp *)buf; - flowid =le16_to_cpu (flowring_create_resp->compl_hdr.flow_ring_id); - flowid -=BRCMF_H2D_MSGRING_FLOWRING_IDSTART ; + flow_ring_id =le16_to_cpu (flowring_create_resp->compl_hdr.flow_ring_id); status =le16_to_cpu (flowring_create_resp->compl_hdr.status); +if (!brcmf_msgbuf_get_flowid (msgbuf, flow_ring_id, &flowid)) +return ; +if (status) {bphy_err (drvr,"Flowring creation failed, code %d\n" , status);brcmf_msgbuf_remove_flowring (msgbuf, flowid);
@@ -1263,13 +1294,16 @@ brcmf_msgbuf_process_flow_ring_delete_response(struct brcmf_msgbuf *msgbuf,struct msgbuf_flowring_delete_resp *flowring_delete_resp;u16 status;u16 flowid; +u16 flow_ring_id; flowring_delete_resp = (struct msgbuf_flowring_delete_resp *)buf; - flowid =le16_to_cpu (flowring_delete_resp->compl_hdr.flow_ring_id); - flowid -=BRCMF_H2D_MSGRING_FLOWRING_IDSTART ; + flow_ring_id =le16_to_cpu (flowring_delete_resp->compl_hdr.flow_ring_id); status =le16_to_cpu (flowring_delete_resp->compl_hdr.status); +if (!brcmf_msgbuf_get_flowid (msgbuf, flow_ring_id, &flowid)) +return ; +if (status) {bphy_err (drvr,"Flowring deletion failed, code %d\n" , status);brcmf_flowring_delete (msgbuf->flow, flowid);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 167/2214 HID: quirks: Add ALWAYS_POLL quirk for Beitong BTP-KP20D dongle
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Aaron Ma <[email protected]>
[ Upstream commit bfff246b3a31cb45ec297ca5e2a77c1410b207ac ]
The BTP-KP20D dongle in Direct/HID mode (20dd:5159) re-enumerates every few seconds because usbhid never submits its interrupt-IN URB: no HID driver binds to the vendor-specific report descriptor, so the device is never opened, and the firmware treats the idle endpoint as a lost link.
Add HID_QUIRK_ALWAYS_POLL to keep the interrupt-IN URB submitted from probe time.
--- drivers/hid/hid-ids.h | 3 +++ drivers/hid/hid-quirks.c | 1 + 2 files changed, 4 insertions(+)
drivers/hid/hid-ids.h +3 -0
@@ -233,6 +233,9 @@#define USB_VENDOR_ID_BAANTO 0x2453#define USB_DEVICE_ID_BAANTO_MT_190W2 0x0100 +#define USB_VENDOR_ID_BEITONG 0x20dd +#define USB_DEVICE_ID_BEITONG_KP20D 0x5159 +#define USB_VENDOR_ID_BELKIN 0x050d#define USB_DEVICE_ID_FLIP_KVM 0x3201
drivers/hid/hid-quirks.c +1 -0
@@ -45,6 +45,7 @@ static const struct hid_device_id hid_quirks[] = { { HID_USB_DEVICE(USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_CS682), HID_QUIRK_NOGET }, { HID_USB_DEVICE(USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_CS692), HID_QUIRK_NOGET }, { HID_USB_DEVICE(USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_UC100KM), HID_QUIRK_NOGET }, + { HID_USB_DEVICE(USB_VENDOR_ID_BEITONG, USB_DEVICE_ID_BEITONG_KP20D), HID_QUIRK_ALWAYS_POLL }, { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_MULTI_TOUCH), HID_QUIRK_MULTI_INPUT }, { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_PIXART_USB_OPTICAL_MOUSE), HID_QUIRK_ALWAYS_POLL }, { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_PIXART_USB_OPTICAL_MOUSE2), HID_QUIRK_ALWAYS_POLL },
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 168/2214 HID: intel-ish-hid: ignore post-init ENUM_DEVICES from firmware
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Wahid Khan <[email protected]>
[ Upstream commit f3f3f6df05226dfa220c4e603310dae94595060a ]
Some ISH firmware versions (observed on Tiger Lake LP, 8086:a0fc, GUID {33AECD58-B679-4E54-9BD9-A04D34F0C226}) periodically re-send an unsolicited HOSTIF_DM_ENUM_DEVICES response roughly every 79 seconds.
The current guard collapses two distinct cases into one condition:
if (!(response_flag) || init_done) -> bad packet + ish_hw_reset
This incorrectly treats a valid post-init firmware announcement as a corrupted packet, triggering an ISH soft-reset and a full ISHTP re-initialisation cycle on each occurrence (~1100 times per day on affected hardware).
Split the check: reject messages with no response flag as before, but simply discard valid ENUM_DEVICES messages that arrive after init is complete.
--- drivers/hid/intel-ish-hid/ishtp-hid-client.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/hid/intel-ish-hid/ishtp-hid-client.c +3 -2
@@ -110,8 +110,7 @@ static void process_recv(struct ishtp_cl *hid_ishtp_cl, void *recv_buf,switch (recv_msg->hdr.command &CMD_MASK ) {case HOSTIF_DM_ENUM_DEVICES : -if ((!(recv_msg->hdr.command & ~CMD_MASK ) || - client_data->init_done)) { +if (!(recv_msg->hdr.command & ~CMD_MASK )) { ++client_data->bad_recv_cnt; report_bad_packet(hid_ishtp_cl, recv_msg, cur_pos,
@@ -119,6 +118,8 @@ static void process_recv(struct ishtp_cl *hid_ishtp_cl, void *recv_buf,ish_hw_reset (ishtp_get_ishtp_device (hid_ishtp_cl));break ; } +if (client_data->init_done) +break ; client_data->hid_dev_count = (unsigned int )*payload;if (!client_data->hid_devices) client_data->hid_devices = devm_kcalloc(
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 169/2214 net/rds: dont use unpin_user_pages_dirty_lock() from atomic context
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Allison Henderson <[email protected]>
[ Upstream commit d100966325f782aa7775e5f0e8fb04f66f56308e ]
rds_rdma_free_op() and rds_atomic_free_op() are reached from the IB send completion path via
rds_ib_tasklet_fn_send()
rds_ib_send_cqe_handler()
rds_message_put()
rds_message_purge()
rds_rdma_free_op() / rds_atomic_free_op()which runs in tasklet (softirq) context. Both functions unpin the user pages of the op with unpin_user_pages_dirty_lock(), which uses set_page_dirty_lock() and thus may take the folio lock and sleep. Sleeping in softirq context is not allowed and can deadlock or crash.
Dirtying the pages with the non-sleeping set_page_dirty() instead would just trade one bug for another, as pointed out during review:
the pinned range can be file-backed. rds_pin_pages() pins with FOLL_LONGTERM, which refuses fs-dax but takes the page-cache pages of a MAP_SHARED file mapping just fine, and RDS does not restrict what memory the caller registers as an RDMA destination.
For a file-backed page, set_page_dirty() from a tasklet can take non-irq-safe filesystem locks (e.g. mapping->i_private_lock and inode->i_lock in block_dirty_folio()) and deadlock against the task it interrupted. Without the folio lock, it races with truncation clearing folio->mapping, which is the race set_page_dirty_lock() exists to close. The pre-pin_user_pages() version of this code dirtied pages that way from the tasklet, so that bug is older than the sleeping unpin.
The page dirtying therefore has to move to process context, not merely avoid the folio lock. When the final rds_message_put() runs in atomic context, rds_rdma_free_op() and rds_atomic_free_op() now leave the op's pages pinned and flag the op. Later, rds_message_put() hands the message to a work item that unpins the flagged ops' pages and frees the message from process context. Here, unpin_user_pages_dirty_lock() is safe outside the atomic context. Everything else keeps running in the caller's context exactly as
before: the rest of the purge - the zerocopy completion, the socket put and the MR reference drops - as well as RDMA writes, whose pages the remote side only reads and which unpin without dirtying, everything on rds_tcp, and final puts that already happen in process context (socket close, connection teardown).
Deferring only the unpin means the work item touches nothing but the pinned pages and the rds module's own memory: it cannot call back into a transport module, so it changes nothing about the transports' shutdown and unload ordering. rds_exit() drains any pending unpin work via destroy_workqueue(rds_wq) before the module goes away.
The Oracle UEK kernel avoids the sleeping unpin by calling set_page_dirty() directly from the tasklet, which is subject to the file-backed page problem above, so this deliberately does not follow UEK here.
--- net/rds/message.c | 26 +++++++++++++++++++++++++ net/rds/rdma.c | 49 ++++++++++++++++++++++++++++++++++++----------- net/rds/rds.h | 10 ++++++++++ 3 files changed, 74 insertions(+), 11 deletions(-)
net/rds/message.c +26 -0
@@ -180,6 +180,19 @@ static void rds_message_purge(struct rds_message *rm)kref_put (&rm->atomic.op_rdma_mr->r_kref, __rds_put_mr_final); } +static void rds_message_unpin_worker (struct work_struct *work) +{ + struct rds_message *rm = container_of(work, struct rds_message, + m_unpin_work); + +if (rm->rdma.op_unpin_deferred) +rds_rdma_op_unpin_pages (&rm->rdma); +if (rm->atomic.op_unpin_deferred) +rds_atomic_op_unpin_page (&rm->atomic); + +kfree (rm); +} +void rds_message_put (struct rds_message *rm) {rdsdebug ("put rm %p ref %d\n" , rm,refcount_read (&rm->m_refcount));
@@ -187,8 +200,21 @@ void rds_message_put(struct rds_message *rm)if (refcount_dec_and_test (&rm->m_refcount)) {BUG_ON (!list_empty (&rm->m_sock_item));BUG_ON (!list_empty (&rm->m_conn_item)); +rds_message_purge (rm); +/* A final put in atomic context cannot dirty the ops' +* user pages on unpin, so rds_rdma_free_op() and +* rds_atomic_free_op() deferred it. Finish the unpin, +* and the free, from process context. +*/ +if (rm->rdma.op_unpin_deferred || + rm->atomic.op_unpin_deferred) { +INIT_WORK (&rm->m_unpin_work, rds_message_unpin_worker); +queue_work (rds_wq, &rm->m_unpin_work); +return ; + } +kfree (rm); } }
net/rds/rdma.c +38 -11
73 lines not on this page · raw message
net/rds/rds.h +10 -0
@@ -424,6 +424,12 @@ struct rds_message {void *m_final_op; +/* Unpins the ops' user pages and frees the message from +* process context when the final put happens in atomic +* context: dirtying the pages on unpin can sleep. +*/ +struct work_struct m_unpin_work; + struct { struct rm_atomic_op { int op_type;
@@ -447,6 +453,7 @@ struct rds_message { unsigned int op_mapped:1; unsigned int op_silent:1; unsigned int op_active:1; + unsigned int op_unpin_deferred:1;struct scatterlist *op_sg;struct rds_notifier *op_notifier;
@@ -462,6 +469,7 @@ struct rds_message { unsigned int op_mapped:1; unsigned int op_silent:1; unsigned int op_active:1; + unsigned int op_unpin_deferred:1;unsigned int op_bytes;unsigned int op_nents;unsigned int op_count;
@@ -939,6 +947,8 @@ int rds_cmsg_rdma_map(struct rds_sock *rs, struct rds_message *rm, struct cmsghdr *cmsg);void rds_rdma_free_op (struct rm_rdma_op *ro);void rds_atomic_free_op (struct rm_atomic_op *ao); +void rds_rdma_op_unpin_pages (struct rm_rdma_op *ro); +void rds_atomic_op_unpin_page (struct rm_atomic_op *ao);void rds_rdma_send_complete (struct rds_message *rm,int wc_status);void rds_atomic_send_complete (struct rds_message *rm,int wc_status); int rds_cmsg_atomic(struct rds_sock *rs, struct rds_message *rm,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 170/2214 net/rds: hold the socket while an rds_mr references it
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Håkon Bugge <[email protected]>
[ Upstream commit 9079adef042c1e7a6141dcdfd3041acd30607297 ]
Each rds_mr stores a bare back pointer to the socket that created it (mr->r_sock) but takes no reference on it. When the mr is destroyed it references the rs. Hence, provisions must be made to avoid the rs being destroyed before all mrs referencing it have been destroyed.
The MR itself is refcounted, and in-flight messages legitimately hold MR krefs that can outlive the socket: rds_release() drops the rb-tree references via rds_rdma_drop_keys(), but a send completion arriving afterwards drops the final message reference from the CQ handler and ends up in
rds_message_purge()
__rds_put_mr_final()
rds_destroy_mr() -> takes rs->rs_rdma_lockdereferencing a socket that may already have been freed.
Oracle UEK fixed the same use-after-free ("rds: Add proper refcnt when an RDS MR references an RDS Socket") after seeing crashes of the form:
PF: supervisor write access in kernel mode
_raw_spin_lock_irqsave+0x4a/0x6a __rds_put_mr_final+0x2c/0xe0 [rds] rds_message_purge+0x13c/0x150 [rds] rds_message_put+0x39/0x54 [rds] rds_ib_send_cqe_handler+0x147/0x3dd [rds_rdma]
To fix this, take a socket reference when an MR is created and drop it when the final MR kref goes away. The reference cycle is broken by rds_release(), which always runs rds_rdma_drop_keys() on close. So the socket reference held by an MR never prevents release, it only delays sk_free() until the last MR user is done.
The hold sits next to kref_init() at both allocation sites - __rds_rdma_map() and the on-demand-paging path in rds_cmsg_rdma_args() - so every MR owns exactly one socket reference from the moment it becomes kref-managed. For that to work on the ODP path, its get_mr() error handling is converted from a bare kfree() to kref_put(..., __rds_put_mr_final), with r_trans_private cleared first since it holds an ERR_PTR there; both sites then tear down through the same path and a future error-path change cannot silently leak or double-drop the reference.
[achender: port to net-next (sock_hold/sock_put in place of the UEK
rds_sock_addref/rds_sock_put helpers); also balance the reference on the rds_cmsg_rdma_args() ODP path and unify its error path with __rds_put_mr_final(); update commit message]
--- net/rds/rdma.c | 14 +++++++++++++- net/rds/rds.h | 5 ++++- 2 files changed, 17 insertions(+), 2 deletions(-)
net/rds/rdma.c +13 -1
@@ -117,6 +117,7 @@ void __rds_put_mr_final(struct kref *kref) struct rds_mr *mr = container_of(kref, struct rds_mr, r_kref);rds_destroy_mr (mr); +sock_put (rds_rs_to_sk (mr->r_sock));kfree (mr); }
@@ -243,7 +244,11 @@ static int __rds_rdma_map(struct rds_sock *rs, struct rds_get_mr_args *args,kref_init (&mr->r_kref);RB_CLEAR_NODE (&mr->r_rb_node); mr->r_trans = rs->rs_transport; +/* The MR can outlive its socket: a socket reference is held +* until the final kref is dropped in __rds_put_mr_final(). +*/ mr->r_sock = rs; +sock_hold (rds_rs_to_sk (rs));if (args->flags &RDS_RDMA_USE_ONCE ) mr->r_use_once =1 ;
@@ -762,7 +767,12 @@ int rds_cmsg_rdma_args(struct rds_sock *rs, struct rds_message *rm,RB_CLEAR_NODE (&local_odp_mr->r_rb_node);kref_init (&local_odp_mr->r_kref); local_odp_mr->r_trans = rs->rs_transport; +/* The MR can outlive its socket: a socket +* reference is held until the final kref is +* dropped in __rds_put_mr_final(). +*/ local_odp_mr->r_sock = rs; +sock_hold (rds_rs_to_sk (rs)); local_odp_mr->r_trans_private = rs->rs_transport->get_mr( NULL, 0, rs, &local_odp_mr->r_key, NULL,
@@ -771,7 +781,9 @@ int rds_cmsg_rdma_args(struct rds_sock *rs, struct rds_message *rm, ret =IS_ERR (local_odp_mr->r_trans_private);rdsdebug ("get_mr ret %d %p\"" , ret, local_odp_mr->r_trans_private); -kfree (local_odp_mr); + local_odp_mr->r_trans_private =NULL ; +kref_put (&local_odp_mr->r_kref, + __rds_put_mr_final); ret = -EOPNOTSUPP ; goto out_pages; }
net/rds/rds.h +4 -1
@@ -299,7 +299,10 @@ struct rds_mr { unsigned int r_invalidate:1; unsigned int r_write:1; -struct rds_sock *r_sock;/* back pointer to the socket that owns us */ +struct rds_sock *r_sock;/* socket that owns us; counted +* reference, dropped by +* __rds_put_mr_final() +*/ struct rds_transport *r_trans;void *r_trans_private; };
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 171/2214 net/rds: fix rds_message leak in the rds_send_xmit() drop path
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Sharath Srinivasan <[email protected]>
[ Upstream commit eb8a59a17f4a8b6f2afb4a8063e99dd96cc3fab0 ]
When rds_send_xmit() picks the next message off cp_send_queue it takes its own reference with rds_message_addref(). If the message then hits the never-retransmit check (RDS_MSG_FLUSH, or an RDMA op that was already retransmitted), it is moved to the local to_be_dropped list and that reference is dropped after the batch.
However, if RDS_MSG_ON_CONN has already been cleared, the message is not added to to_be_dropped and the reference taken above is never
dropped: cp_xmit_rm has not been set at this point, so the loop simply abandons rm and the rds_message (and everything it pins: pages, MRs, notifiers) leaks after an RDMA error.
The only other places that clear RDS_MSG_ON_CONN are rds_send_path_drop_acked() and rds_send_drop_to(), and both can run while rds_send_xmit() has dropped cp_lock between moving the message to cp_retrans and re-taking the lock in the never-retransmit check:rds_send_path_drop_acked() can ack away a message that already sat on cp_retrans - the RDS_MSG_RETRANSMITTED case above - and rds_send_drop_to() runs on socket close. Both unlink the message under cp_lock and put their own reference, leaving the xmit-path reference stranded.
Drop the reference directly in that case.
This mirrors Oracle UEK commit "net/rds: fix rds_message memleak in rds_send_xmit".
--- net/rds/send.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-)
net/rds/send.c +15 -3
@@ -288,9 +288,21 @@ int rds_send_xmit(struct rds_conn_path *cp) (rm->rdma.op_active && test_bit(RDS_MSG_RETRANSMITTED, &rm->m_flags))) {spin_lock_irqsave (&cp->cp_lock, flags); -if (test_and_clear_bit (RDS_MSG_ON_CONN , &rm->m_flags)) -list_move (&rm->m_conn_item, &to_be_dropped); -spin_unlock_irqrestore (&cp->cp_lock, flags); +if (test_and_clear_bit (RDS_MSG_ON_CONN , + &rm->m_flags)) { +/* our ref is put after the batch */ +list_move (&rm->m_conn_item, + &to_be_dropped); +spin_unlock_irqrestore (&cp->cp_lock, + flags); + }else { +/* already off the conn list; drop +* the ref taken above ourselves +*/ +spin_unlock_irqrestore (&cp->cp_lock, + flags); +rds_message_put (rm); + }continue ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 172/2214 net/rds: unpin MR pages with unpin_user_pages_dirty_lock()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Allison Henderson <[email protected]>
[ Upstream commit a507023e6ff1d0b4e7aac49b2f547fed0c21ea4e ]
The pages backing an RDS memory region are pinned in __rds_rdma_map() with rds_pin_pages(), which uses pin_user_pages_fast(): each page's refcount is biased by GUP_PIN_COUNTING_BIAS to account the pin. The scatterlist is then handed to the IB transport, and the transport releases the pages in __rds_ib_teardown_mr() with
set_page_dirty(page); put_page(page);
put_page() drops a single reference instead of removing the pin bias, so every MR teardown permanently strands the remaining references and the pages are never freed - a userspace-triggerable memory leak of up to RDS_MAX_MSG_SIZE per RDS_GET_MR/RDS_GET_MR_FOR_DEST call.
The conversion to the pin API updated the unpin sites in rdma.c but missed this one on the transport side. Release the pages with unpin_user_pages_dirty_lock(), which removes the pin bias and also dirties the page under the folio lock, closing the truncation race that a bare set_page_dirty() leaves open.
Dirtying under the folio lock can sleep, which is safe in every path that reaches __rds_ib_teardown_mr(): the registration-reuse path (rds_ib_map_frmr()) runs in syscall context, and the pool flush (rds_ib_unreg_frmr()) runs under pool->flush_lock, a mutex, and already sleeps in rds_ib_post_inv(). The WARN_ON that guarded the old irq-context set_page_dirty() case is dropped along with it.
--- net/rds/ib_rdma.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
net/rds/ib_rdma.c +1 -3
@@ -255,9 +255,7 @@ void __rds_ib_teardown_mr(struct rds_ib_mr *ibmr)/* FIXME we need a way to tell a r/w MR * from a r/o MR */ -WARN_ON (!page->mapping &&irqs_disabled ()); -set_page_dirty (page); -put_page (page); +unpin_user_pages_dirty_lock (&page,1 , true); }kfree (ibmr->sg);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 173/2214 kconfig: abort rather than loop for ever on EOF
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Simon Glass <[email protected]>
[ Upstream commit f915149f5cfbd0d4406ec0b0f57b1d2c8685ae55 ]
When a non-interactive 'make oldconfig' or 'syncconfig' meets a new int or hex symbol whose default cannot be applied, conf_string() reads a value from stdin. At end of file fgets() returns NULL, no value is set and the loop asks again. The result is an endless loop which fills the output until it exhausts memory, rather than a clean failure.
Detect this in conf_string(): if the value cannot be set and stdin is at end of file, stop with an error that names the symbol.
Note that a symbol with no default doesn't trigger this, since sym_calc_value() falls back to 0, which is accepted at end of file. The loop is triggered by a broken Kconfig file, with a default whose text fails sym_string_valid().
Such mistakes do creep in from time to time and are hard to debug, since the build fills the log with repeated prompts instead of pointing at the offending symbol. Some bad defaults draw a parse-time warning, but menu_validate_number() accepts a reference to any int or hex symbol, so a cross-type reference loops with no warning at all. For example, "0xff" is not a valid int value:
config HEXSYM
hex
default 0xff config VAL
int "Value"
default HEXSYM
Interactive use is unaffected, since feof() only becomes true once a read actually hits end of file: an invalid answer at a terminal still re-prompts, while Ctrl-D at such a prompt exits with the error instead of looping. bool and tristate symbols and choices already accept the default on an empty line, so they still take their defaults in a non-interactive build.
Tested with int and hex symbols carrying such defaults: with empty stdin, the code without this change produces around 190MB of repeated prompts within two seconds, while with the change it exits 1 naming the symbol. Piped and interactive (pty) sessions still re-prompt on an invalid answer and then accept a valid one. A new string symbol with no default still takes the empty string at end of file, since any text is valid for a string.
--- scripts/kconfig/conf.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+)
scripts/kconfig/conf.c +17 -0
@@ -377,6 +377,23 @@ static int conf_string(struct menu *menu) }if (def &&sym_set_string_value (sym, def))return 0 ; + +/* +* A new int or hex symbol whose default fails validation +* cannot be set from an empty answer. When standard input is +* exhausted, as it is for a non-interactive oldconfig or +* syncconfig, re-asking would loop forever and grow the output +* until it exhausts memory. Stop with an error that names the +* symbol instead. String symbols accept any text, and bool and +* tristate symbols (conf_sym()) and choices (conf_choice()) +* accept the default on an empty line, so they are unaffected. +*/ +if (feof (stdin)) { +fprintf (stderr, +"\nerror: no value for new symbol '%s' at end of input\n" , + sym->name); +exit (1 ); + } } }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 174/2214 s390/dasd: Snapshot intrc before freeing the request block
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Stefan Haberland <[email protected]>
[ Upstream commit dc3e3f7306cb74066f231251602b1be5aaec7bd8 ]
__dasd_cleanup_cqr() maps the completion result to a block status by reading cqr->intrc, but only after discipline->free_cp() has returned the request block to its memory pool (dasd_eckd_free_cp() ends in dasd_sfree_request()). On SMP another CPU can reallocate that block and overwrite cqr->intrc before it is read, completing the request with the wrong error. proc_bytes is already snapshotted before free_cp() for the same reason; do the same for intrc.
--- drivers/s390/block/dasd.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
drivers/s390/block/dasd.c +8 -2
@@ -2745,17 +2745,23 @@ static void __dasd_cleanup_cqr(struct dasd_ccw_req *cqr)struct request *req;blk_status_t error =BLK_STS_OK ;unsigned int proc_bytes; -int status; +int status, intrc; req = (struct request *) cqr->callback_data;dasd_profile_end (cqr->block, cqr, req); +/* +* free_cp() returns the request block to its memory pool, so snapshot +* everything still needed from cqr before calling it - another CPU can +* reallocate and overwrite the block right after. +*/ proc_bytes = cqr->proc_bytes; + intrc = cqr->intrc; status = cqr->block->base->discipline->free_cp (cqr, req);if (status <0 ) error =errno_to_blk_status (status);else if (status ==0 ) { -switch (cqr->intrc) { +switch (intrc) {case -EPERM : error =BLK_STS_NEXUS ;break ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 175/2214 net: stmmac: raise TX completion interrupt at the end of an xmit burst
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Johan Alvarado <[email protected]>
[ Upstream commit d21a374995df9d7cfd193427748a19dcc87956a9 ]
The TX mitigation logic only sets the Interrupt on Completion bit once every tx_coal_frames descriptors (STMMAC_TX_FRAMES = 25), with the tx_coal_timer hrtimer (STMMAC_COAL_TX_TIMER = 5000 us) as the only fallback. TX skbs are freed exclusively from the TX completion path, so any flow that keeps fewer than 25 frames in flight has all of its skbs held for up to 5 ms after transmission.
Paced flows never queue enough frames to reach the frame threshold:
TCP Small Queues caps the amount of unfreed data at roughly two pacing intervals worth, which at moderate pacing rates is only a couple of packets. Every small burst then stalls until the coalesce timer fires, and throughput collapses to approximately tsq_limit / tx_coal_timer regardless of link capacity.
This is easily reproducible with BBR, which paces its output and thus keeps only a few frames in flight at a time. On a YT6801 (dwmac-motorcomm) equipped Orange Pi 5 Pro, a BBR upload over a ~23 ms RTT path is capped at 5.24 Mbit/s, while CUBIC reaches 207 Mbit/s on the same path. BBR measures the stalled send rate as the path bandwidth and locks its estimate near the floor, so the connection never recovers. Lowering the coalesce settings with ethtool -C (tx-usecs 100 tx-frames 1) lifts the same transfer to 447 Mbit/s, confirming the mechanism.
Fix this by setting the IC bit on the last descriptor of every xmit burst, i.e. whenever netdev_xmit_more() reports that no further frames are pending in the current dequeue batch. Frame-based coalescing still applies within a burst, bulk traffic keeps batching through qdisc bulk dequeue and NAPI polling, and the coalesce timer becomes a pure fallback instead of the primary completion mechanism for lightly queued flows.
tx-frames 0 keeps its meaning of timer-based mitigation only.
--- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +4 -0
@@ -4188,6 +4188,8 @@ static netdev_tx_t stmmac_tso_xmit(struct sk_buff *skb, struct net_device *dev) set_ic = true; else if (!priv->tx_coal_frames[queue]) set_ic = false; + else if (!netdev_xmit_more()) + set_ic = true; else if (tx_packets > priv->tx_coal_frames[queue]) set_ic = true; else if ((tx_q->tx_count_frames %
@@ -4408,6 +4410,8 @@ static netdev_tx_t stmmac_xmit(struct sk_buff *skb, struct net_device *dev) set_ic = true; else if (!priv->tx_coal_frames[queue]) set_ic = false; + else if (!netdev_xmit_more()) + set_ic = true; else if (tx_packets > priv->tx_coal_frames[queue]) set_ic = true; else if ((tx_q->tx_count_frames %
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 176/2214 net: usb: cdc_ether: add quirk for AMI BMC stale link events
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jinhui Guo <[email protected]>
[ Upstream commit 089ca284afb0f3b2870a5ce41524cbc91ed350d4 ]
On AMD Genoa/Turin platforms the BMC-provided USB-Ethernet gadget (American Megatrends, VID 0x046b PID 0xffb0) intermittently fails to respond to ARP after AC cold boot. usbmon captures a stale NETWORK_CONNECTION(off) immediately followed by NETWORK_CONNECTION(on) on the interrupt endpoint (~130us apart) after enumeration. Because alloc_netdev() leaves __LINK_STATE_NOCARRIER cleared, netif_carrier_ok() returns true when the spurious OFF arrives, so usbnet_cdc_status() cannot recognise it as redundant and schedules EVENT_LINK_CHANGE. __handle_link_change() then calls unlink_urbs(), killing ~60 rx URBs whose payload has already been DMA'd into memory — xHCI trace confirms them completing as -ECONNRESET with non-zero residual length. rx_complete() drops these unconditionally. The following ON restores the carrier and re-submits URBs, but the ARP reply is already lost; the interface looks "up but silent" until ifdown/ifup.
Fix this by adding a device-specific quirk with FLAG_LINK_INTR set, which makes usbnet_probe() call netif_carrier_off() after bind. With initial carrier == OFF, usbnet_cdc_status() recognises the spurious OFF as matching the current state and drops it; the subsequent ON is the first real event and brings the link up cleanly without ever tearing down the rx queue. The scheduled link-change kevent is harmless because EVENT_DEV_OPEN is not yet set at probe time.
This is applied as a device-specific quirk rather than a change to the shared cdc_info driver_info because some CDC devices never send NETWORK_CONNECTION notifications; forcing carrier off for them would leave the link permanently DOWN. Restricting the change to this VID/PID keeps that class of device untouched.
Tested on Genoa and Turin across 100+ AC cold boot cycles; ping first-packet success rate went from intermittent to 100%.
--- drivers/net/usb/cdc_ether.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+)
drivers/net/usb/cdc_ether.c +16 -0
@@ -530,6 +530,16 @@ static const struct driver_info cdc_info = { .manage_power = usbnet_manage_power, }; +static const struct driver_info ami_bmc_info = { + .description ="AMI BMC USB Ethernet" , + .flags =FLAG_ETHER |FLAG_POINTTOPOINT |FLAG_LINK_INTR , + .bind = usbnet_cdc_bind, + .unbind = usbnet_cdc_unbind, + .status = usbnet_cdc_status, + .set_rx_mode = usbnet_cdc_update_filter, + .manage_power = usbnet_manage_power, +}; +static const struct driver_info zte_cdc_info = { .description ="ZTE CDC Ethernet Device" , .flags =FLAG_ETHER |FLAG_POINTTOPOINT ,
@@ -1033,6 +1043,12 @@ static const struct usb_device_id products[] = { USB_CDC_SUBCLASS_ETHERNET, USB_CDC_PROTO_NONE), .driver_info = (unsigned long)&wwan_info, +}, { +/* AMI BMC gadget */ +USB_DEVICE_AND_INTERFACE_INFO (0x046b ,0xffb0 ,USB_CLASS_COMM , +USB_CDC_SUBCLASS_ETHERNET , + USB_CDC_PROTO_NONE), + .driver_info = (unsigned long )&ami_bmc_info, }, {USB_INTERFACE_INFO (USB_CLASS_COMM ,USB_CDC_SUBCLASS_ETHERNET , USB_CDC_PROTO_NONE),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 177/2214 ALSA: hda/realtek: Enable mute LED on HP Laptop 15-dy0xxx
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Carl Quist <[email protected]>
[ Upstream commit eb2b516900f2cff6c931a0d664a625ee93855779 ]
The mute LED on the HP Laptop 15-dy0xxx (PCI SSID 103c:864f, Realtek ALC236) does not work, because the machine has no entry in the quirk table. No fixup is applied, so no mute LED classdev is registered and nothing ever drives the LED.
The LED is controlled by COEF index 0x07, bit 0. This was verified on the hardware with hda-verb: setting the bit lights the mute LED and clearing it turns the LED off.
hda-verb /dev/snd/hwC0D0 0x20 SET_COEF_INDEX 0x07
hda-verb /dev/snd/hwC0D0 0x20 SET_PROC_COEF 0x1 # LED on
hda-verb /dev/snd/hwC0D0 0x20 SET_PROC_COEF 0x200 # LED off
That is exactly what ALC236_FIXUP_HP_MUTE_LED_COEFBIT2 configures, and the closely related HP Laptop 15-dw0xxx (103c:85f0) already uses it. Bit 9 (0x200) is set by default on this board and is preserved by the fixup's read-modify-write.
Tested on an HP Laptop 15-dy0xxx (SKU 7FU54UA#ABA, board 864F, BIOS F.40).
--- sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+)
sound/pci/hda/patch_realtek.c +1 -0
@@ -9332,6 +9332,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {SND_PCI_QUIRK (0x103c ,0x85de ,"HP Envy x360 13-ar0xxx" ,ALC285_FIXUP_HP_ENVY_X360 ),SND_PCI_QUIRK (0x103c ,0x860f ,"HP ZBook 15 G6" ,ALC285_FIXUP_HP_GPIO_AMP_INIT ),SND_PCI_QUIRK (0x103c ,0x861f ,"HP Elite Dragonfly G1" ,ALC285_FIXUP_HP_GPIO_AMP_INIT ), +SND_PCI_QUIRK (0x103c ,0x864f ,"HP Laptop 15-dy0xxx" ,ALC236_FIXUP_HP_MUTE_LED_COEFBIT2 ),SND_PCI_QUIRK (0x103c ,0x869d ,"HP" ,ALC236_FIXUP_HP_MUTE_LED ),SND_PCI_QUIRK (0x103c ,0x86c1 ,"HP Laptop 15-da3001TU" ,ALC236_FIXUP_HP_MUTE_LED_COEFBIT2 ), SND_PCI_QUIRK(0x103c, 0x86c7, "HP Envy AiO 32", ALC274_FIXUP_HP_ENVY_GPIO),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 178/2214 arm64: mm: fix accidental linear mapping of no-map reserved memory
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: liulhong617 <[email protected]>
[ Upstream commit 7ace06a01efaba1ec585630aa4c98ac39b38452a ]
When reserved-memory regions with the "no-map" property are not page-aligned, the kernel may accidentally map them into the linear mapping, contradicting the no-map semantics.
The root cause is a mismatch between /proc/iomem's address boundaries and the actual page table mapping boundaries:
1. /proc/iomem derives its ranges from memblock via memblock_region_reserved_base_pfn/memblock_region_reserved_end_pfn, which perform PFN rounding so the displayed boundaries are page-aligned. This gives the impression that the no-map region occupies whole pages.
2. However, memblock_mark_nomap() splits memblock.memory regions at exact byte boundaries (memblock_isolate_range preserves raw DT base/size with no alignment). When for_each_mem_range iterates the non-NOMAP regions adjacent to a no-map region, it returns start/end values that are NOT page-aligned — they are the precise byte boundaries from the memblock split.
3. These sub-page-aligned values are passed to
__create_pgd_mapping_locked(), which does:
phys &= PAGE_MASK;
addr = virt & PAGE_MASK;
end = PAGE_ALIGN(virt + size); The downward rounding of phys via PAGE_MASK extends the mapped range backward into the adjacent no-map region, effectively including no-map memory in the linear mapping.
For example, with 64K pages, reserved_region@A2000000 (base=0xA2000000, size=0x8000, no-map) causes for_each_mem_range to return start=0xA2008000 for the next mappable region. After phys &= PAGE_MASK, the actual mapping starts at 0xA2000000 — the entire no-map region is incorrectly mapped.
Fix this by rounding the mappable range inward to PAGE_SIZE boundaries before passing it to __map_memblock: start is rounded UP and end is rounded DOWN. This ensures the mapped area never overlaps with adjacent no-map regions. The cost is at most one page of unmapped gap at each boundary, which is preferable to violating no-map semantics.
--- arch/arm64/mm/mmu.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
arch/arm64/mm/mmu.c +14 -0
@@ -551,6 +551,20 @@ static void __init map_mem(pgd_t *pgdp)for_each_mem_range (i, &start, &end) {if (start >= end)break ; +/* +* for_each_mem_range may return sub-page-aligned boundaries +* after memblock_mark_nomap() splits regions at byte precision. +* __create_pgd_mapping_locked aligns phys down to PAGE_MASK, +* which could accidentally map no-map memory on the boundary. +* Round the mappable range inward: start UP, end DOWN, so +* that the mapped area never overlaps with adjacent no-map +* regions. The cost is at most one page of unmapped gap at +* each boundary. +*/ + start =PAGE_ALIGN (start); + end = end &PAGE_MASK ; +if (start >= end) +continue ;/* * The linear map must allow allocation tags reading/writing * if MTE is present. Otherwise, it has the same attributes as
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 179/2214 HID: rmi: check report length before trimming sentinel bytes
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 28a3e326fad2451bdb66b747dd1f7ccbb900eed6 ]
rmi_check_sanity() trims trailing 0xff sentinel bytes, but its loop reads data[valid_size - 1] before checking that valid_size is non-zero.
Reverse the condition so the length is proved before the last byte is inspected.
--- drivers/hid/hid-rmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/hid/hid-rmi.c +1 -1
@@ -386,7 +386,7 @@ static int rmi_check_sanity(struct hid_device *hdev, u8 *data, int size)* such reports here. */ -while ((data[valid_size -1 ] ==0xff ) && valid_size >0 ) +while (valid_size >0 && data[valid_size -1 ] ==0xff ) valid_size--;return valid_size;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 180/2214 ext4: guard against NULL s_group_info in ext4_get_group_info
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Junzhe Yu <[email protected]>
[ Upstream commit 8f3901fbb40745046e513226ad84e8b84492632d ]
Resend: previous attempt was rejected by vger for containing HTML.
==================================================================
ext4_mark_group_bitmap_corrupted() already treats a NULL return from ext4_get_group_info() as "nothing to do", but ext4_get_group_info() indexes s_group_info without checking whether the array exists.
During mount, fast-commit replay runs inside jbd2_journal_load() from ext4_load_and_init_journal(), which is before ext4_mb_init() allocates s_group_info. Replaying an FC UNLINK for an inode whose bitmap bit is already clear takes:
ext4_fc_replay_unlink -> iput -> ext4_evict_inode -> ext4_free_inode -> ext4_mark_group_bitmap_corrupted -> ext4_get_group_info
and faults on the NULL s_group_info base. Userspace only mounts a dirty ext4 image; this is a supported recovery path.
Return NULL when s_group_info (or the per-block grp_info row) is unset so the existing caller check is effective during early mount.
Tested on Linux v6.6.145 KASAN: crafted FC-unlink image previously triggered KASAN null-ptr-deref / panic in ext4_get_group_info; with this patch, mount succeeds (EXT4 "bit already cleared" may still log). Also observed on v6.6.144; still present on torvalds/linux as of f5098b6bae76 (2026-07-26).
A self-contained Docker/QEMU reproducer (craft + mount + patch verify) is available on request.
--- fs/ext4/balloc.c | 4 ++++ 1 file changed, 4 insertions(+)
fs/ext4/balloc.c +4 -0
@@ -327,9 +327,13 @@ struct ext4_group_info *ext4_get_group_info(struct super_block *sb,if (unlikely (group >=EXT4_SB (sb)->s_groups_count))return NULL ; +if (unlikely (!EXT4_SB (sb)->s_group_info)) +return NULL ; indexv = group >> (EXT4_DESC_PER_BLOCK_BITS (sb)); indexh = group & ((EXT4_DESC_PER_BLOCK (sb)) -1 ); grp_info =sbi_array_rcu_deref (EXT4_SB (sb), s_group_info, indexv); +if (unlikely (!grp_info)) +return NULL ;return grp_info[indexh]; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 181/2214 md/raid5: reject zero-sector reshape chunks
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yu Kuai <[email protected]>
[ Upstream commit a41bb2ee1aca486853e84920565e50c15f86fa5d ]
Sashiko reported that RAID5 can accept a reshape chunk size that becomes zero sectors. chunk_size_store() stores the sysfs byte value as n >> 9, so writing a value below 512 bytes sets mddev->new_chunk_sectors to zero. RAID5 then accepted that pending reshape geometry and raid5_start_reshape() installed it into conf->chunk_sectors, letting reshape code divide by zero.
Reject zero-sector chunks both in check_reshape(), where normal sysfs requests are validated, and in raid5_start_reshape(), so assembly/resume paths also cannot install zero chunk geometry.
Test script: in QEMU, create a plain three-disk RAID5 array with 64K chunks, write/read back a small pattern, write 1 to /sys/block/md0/md/chunk_size, add a fourth disk, and run mdadm --grow --raid-devices=4 --backup-file=... . The script scans dmesg for divide error/Oops/KASAN signatures.
Bad kernel, eb29914412c3:
echo 1 > /sys/block/md0/md/chunk_size mdadm --grow /dev/md0 --raid-devices=4 --backup-file=/root/md0-grow.bak
Oops: divide error: 0000 [#1] SMP KASAN NOPTI RIP: raid5_get_active_stripe+0x863/0xc10 Call Trace: raid5_sync_request md_do_sync md_thread Kernel panic - not syncing: Fatal exception
Fixed kernel: echo 1 > /sys/block/md0/md/chunk_size bash: echo: write
error: Invalid argument chunk_write_rc=1 grow_rc=skipped RESULT:REJECTED_ZERO_CHUNK_NO_OOPS
--- drivers/md/raid5.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/md/raid5.c +5 -0
@@ -8143,6 +8143,8 @@ static int check_reshape(struct mddev *mddev)return 0 ;/* nothing to do */ if (has_failed (conf))return -EINVAL ; +if (!mddev->new_chunk_sectors) +return -EINVAL ;if (mddev->delta_disks <0 && mddev->reshape_position == MaxSector) {/* We might be able to shrink, but the devices must * be made bigger first.
@@ -8185,6 +8187,9 @@ static int raid5_start_reshape(struct mddev *mddev)if (test_bit (MD_RECOVERY_RUNNING , &mddev->recovery))return -EBUSY ; +if (!mddev->new_chunk_sectors) +return -EINVAL ; +if (!check_stripe_cache (mddev))return -ENOSPC ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 182/2214 md: add cond_resched() to md_do_sync()s skip path
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yunye Zhao <[email protected]>
[ Upstream commit 162eb5ba791f6260fdaabae75fa2df20134f67d8 ]
When sync_request() reports a skipped region (*skipped == 1), md_do_sync()'s main loop advances the cursor and takes an early continue:
j += sectors; ... if (last_check + window > io_sectors || j == max_sectors) continue;
If the personality returns a small span per call (raid10 recovery returns only 128 sectors), syncing a large, mostly clean array iterates this branch an enormous number of times without ever yielding the CPU. On a non-preemptive kernel the resync thread then trips the soft-lockup watchdog:
watchdog: BUG: soft lockup - CPU#149 stuck for 313s! [mdX_resync] md_bitmap_start_sync+0x6f/0xe0 raid10_sync_request+0x2c9/0x1530 [raid10] md_do_sync+0x810/0x1030 md_thread+0xa7/0x150
Add a cond_resched(). This does not reduce the wasted iterations; the excessive iteration count is a raid10 problem addressed separately.
--- drivers/md/md.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/md/md.c +3 -1
@@ -9038,8 +9038,10 @@ void md_do_sync(struct md_thread *thread)*/ md_new_event (mddev); -if (last_check + window > io_sectors || j == max_sectors) +if (last_check + window > io_sectors || j == max_sectors) { +cond_resched ();continue ; + } last_check = io_sectors; repeat:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 183/2214 selftests/ftrace: Force C locale in ftracetest
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Rui Qi <[email protected]>
[ Upstream commit c13fcd3951dcc19524ce0b3e852844b16cd32b22 ]
Some ftracetest test cases parse command output by matching English field names. Tools such as readelf may localize their output via gettext, while ftracetest currently inherits the user locale from the environment.
If a translated field name is printed, parsing can fail even though the tested kernel behavior is unchanged. For example, add_remove_uprobe can fail to find the ELF entry point and then write a uprobe event with a missing offset.
Export LC_ALL=C in the top-level ftracetest runner so every test case gets stable command output by default.
--- tools/testing/selftests/ftrace/ftracetest | 3 +++ 1 file changed, 3 insertions(+)
tools/testing/selftests/ftrace/ftracetest +3 -0
@@ -7,6 +7,9 @@ # Written by Masami Hiramatsu <[email protected]> # +# Keep command output parsing stable regardless of the user's locale. +export LC_ALL=C + usage() { # errno [message] [ ! -z "$2" ] && echo $2 echo "Usage: ftracetest [options] [testcase(s)] [testcase-directory(s)]"
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 184/2214 Bluetooth: btusb: Add support for 1357:c123 Realtek 8852BE device
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pavel Zverev <[email protected]>
[ Upstream commit 335d7bd554a20f33acf762655cafe1089f7f5822 ]
Wiko Hi MateBook 14 Ryzen 200 laptops (DMI system-product-name "MNCA-XX", board "M1060") are equipped with an RTL8852BE Wi-Fi/BT combo chip (rtw89_8852be), whose Bluetooth radio enumerates as 1357:c123 instead of one of the already-supported 1358:c123 / 0bda:c123 identifiers, presumably due to OEM rebranding. Without a matching entry it only matches the generic USB Bluetooth class fallback, so the Realtek firmware/config (rtl8852btu_fw.bin / rtl8852btu_config.bin) is never loaded and the adapter cannot discover or connect to any device, even though hciconfig reports it as powered and scanning.
Device descriptor:
idVendor 0x1357
idProduct 0xc123
bcdDevice 0.00
iManufacturer 1 Realtek
iProduct 2 Bluetooth Radio
bDeviceClass 224 Wireless
bDeviceSubClass 1 Radio Frequency
bDeviceProtocol 1 Bluetooth
Adding the same BTUSB_REALTEK | BTUSB_WIDEBAND_SPEECH quirk already used for 1358:c123 and 0bda:c123 fixes firmware loading and normal operation.
--- drivers/bluetooth/btusb.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/bluetooth/btusb.c +2 -0
@@ -579,6 +579,8 @@ static const struct usb_device_id blacklist_table[] = { BTUSB_WIDEBAND_SPEECH }, { USB_DEVICE(0x0bda, 0xc123), .driver_info = BTUSB_REALTEK | BTUSB_WIDEBAND_SPEECH }, + { USB_DEVICE(0x1357, 0xc123), .driver_info = BTUSB_REALTEK | + BTUSB_WIDEBAND_SPEECH }, { USB_DEVICE(0x0cb5, 0xc547), .driver_info = BTUSB_REALTEK | BTUSB_WIDEBAND_SPEECH }, { USB_DEVICE(0x13d3, 0x3591), .driver_info = BTUSB_REALTEK |
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 185/2214 Bluetooth: hci_nokia: validate firmware packet bounds
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 45640627e3ddc5f4d3a0d08618a596a8c65d48a5 ]
nokia_setup_fw() walks a length-prefixed firmware stream and decodes HCI command packets from each record.
Check that each record fits in the remaining firmware image, that command records contain the HCI command header, and that the payload length is covered before submitting the command.
--- drivers/bluetooth/hci_nokia.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+)
drivers/bluetooth/hci_nokia.c +20 -0
@@ -359,9 +359,29 @@ static int nokia_setup_fw(struct hci_uart *hu)u16 opcode;struct sk_buff *skb; +if (pkt_size > fw_size -2 ) { + err = -EINVAL ; +dev_err (dev,"%s: Malformed firmware packet\n" , + hu->hdev->name); + goto done; + } +switch (pkt_type) {case HCI_COMMAND_PKT : +if (pkt_size <1 +HCI_COMMAND_HDR_SIZE ) { + err = -EINVAL ; +dev_err (dev,"%s: Malformed firmware command\n" , + hu->hdev->name); + goto done; + } + cmd = (struct hci_command_hdr *)(fw_ptr +3 ); +if (cmd->plen > pkt_size -1 -HCI_COMMAND_HDR_SIZE ) { + err = -EINVAL ; +dev_err (dev,"%s: Truncated firmware command\n" , + hu->hdev->name); + goto done; + } opcode =le16_to_cpu (cmd->opcode); skb = __hci_cmd_sync(hu->hdev, opcode, cmd->plen,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 186/2214 btrfs: fix memory barrier order in reloc_root_is_dead()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Filipe Manana <[email protected]>
[ Upstream commit 6f1c97695a6e230ee15c9e052e1933bdccfd5fa3 ]
When we set a root's reloc_root to NULL, we do it like this:
static void clear_reloc_root(struct btrfs_root *root)
{
root->reloc_root = NULL;
/*
* Need barrier to ensure clear_bit() only happens after
* root->reloc_root = NULL. Pairs with have_reloc_root().
*/
smp_wmb();
clear_bit(BTRFS_ROOT_DEAD_RELOC_TREE, &root->state);
}So that a NULL reloc_root is always seen before seeing that the bit BTRFS_ROOT_DEAD_RELOC_TREE was cleared.
But on the read side we have:
static bool reloc_root_is_dead(const struct btrfs_root *root)
{
smp_rmb();
if (test_bit(BTRFS_ROOT_DEAD_RELOC_TREE, &root->state))
return true;
return false;
}And then callers of reloc_root_is_dead() access root->reloc_root.
Because the read memory barrier is placed before testing the bit, the CPU is completely free to speculatively reorder those two loads. It can read root->reloc_root before it actually checks the dead tree bit.
Sashiko reported this as an existing problem in another patch review, see the link in the Link tag below.
Fix this by moving the read memory barrier to happen after testing the bit and update the comment to reflect current reality.
--- fs/btrfs/relocation.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
fs/btrfs/relocation.c +6 -5
@@ -290,14 +290,15 @@ static int update_backref_cache(struct btrfs_trans_handle *trans,static bool reloc_root_is_dead (struct btrfs_root *root) { +if (test_bit (BTRFS_ROOT_DEAD_RELOC_TREE , &root->state)) +return true;/* -* Pair with set_bit/clear_bit in clean_dirty_subvols and -* btrfs_update_reloc_root. We need to see the updated bit before -* trying to access reloc_root +* Pairs with set_bit/clear_bit in clear_reloc_root() and +* btrfs_update_reloc_root(). We need to see the updated bit before +* trying to access root->reloc_root in our callers. */ smp_rmb (); -if (test_bit (BTRFS_ROOT_DEAD_RELOC_TREE , &root->state)) -return true; +return false; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 187/2214 drm/amd: Add DCN6 register headers
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Aurabindo Pillai <[email protected]>
[ Upstream commit fe219bd7d9783a6cb9249bc333546cb58d2c2723 ]
Add new headers for:
- dcn 6.0.0
- dpcs 6.0.0
- mmhub 5.0.1
--- .../include/asic_reg/dcn/dcn_6_0_0_offset.h | 15799 +++++ .../include/asic_reg/dcn/dcn_6_0_0_sh_mask.h | 58556 ++++++++++++++++ .../include/asic_reg/dpcs/dpcs_6_0_0_offset.h | 47 + .../asic_reg/dpcs/dpcs_6_0_0_sh_mask.h | 55 + .../asic_reg/mmhub/mmhub_5_0_1_offset.h | 17 + .../asic_reg/mmhub/mmhub_5_0_1_sh_mask.h | 17 + 6 files changed, 74491 insertions(+) create mode 100644 drivers/gpu/drm/amd/include/asic_reg/dcn/dcn_6_0_0_offset.h create mode 100644 drivers/gpu/drm/amd/include/asic_reg/dcn/dcn_6_0_0_sh_mask.h create mode 100644 drivers/gpu/drm/amd/include/asic_reg/dpcs/dpcs_6_0_0_offset.h create mode 100644 drivers/gpu/drm/amd/include/asic_reg/dpcs/dpcs_6_0_0_sh_mask.h create mode 100644 drivers/gpu/drm/amd/include/asic_reg/mmhub/mmhub_5_0_1_offset.h create mode 100644 drivers/gpu/drm/amd/include/asic_reg/mmhub/mmhub_5_0_1_sh_mask.h
drivers/gpu/drm/amd/include/asic_reg/dcn/dcn_6_0_0_offset.h new file +15799 -0
@@ -0,0 +1,15799 @@ +// SPDX-License-Identifier: MIT +// +// Copyright 2026 Advanced Micro Devices, Inc. + +#ifndef _dcn_6_0_0_OFFSET_HEADER +#define _dcn_6_0_0_OFFSET_HEADER + + + +// addressBlock: dce_dc_hda_azcontroller_azdec +// base address: 0x1300000 +#define regGLOBAL_CAPABILITIES 0x4acc00 +#define regGLOBAL_CAPABILITIES_BASE_IDX 4 +#define regMINOR_VERSION 0x4acc00 +#define regMINOR_VERSION_BASE_IDX 4 +#define regMAJOR_VERSION 0x4acc00 +#define regMAJOR_VERSION_BASE_IDX 4 +#define regOUTPUT_PAYLOAD_CAPABILITY 0x4acc01 +#define regOUTPUT_PAYLOAD_CAPABILITY_BASE_IDX 4 +#define regINPUT_PAYLOAD_CAPABILITY 0x4acc01 +#define regINPUT_PAYLOAD_CAPABILITY_BASE_IDX 4 +#define regGLOBAL_CONTROL 0x4acc02 +#define regGLOBAL_CONTROL_BASE_IDX 4 +#define regWAKE_ENABLE 0x4acc03 +#define regWAKE_ENABLE_BASE_IDX 4 +#define regSTATE_CHANGE_STATUS 0x4acc03 +#define regSTATE_CHANGE_STATUS_BASE_IDX 4 +#define regGLOBAL_STATUS 0x4acc04 +#define regGLOBAL_STATUS_BASE_IDX 4 +#define regOUTPUT_STREAM_PAYLOAD_CAPABILITY 0x4acc06 +#define regOUTPUT_STREAM_PAYLOAD_CAPABILITY_BASE_IDX 4 +#define regINPUT_STREAM_PAYLOAD_CAPABILITY 0x4acc06 +#define regINPUT_STREAM_PAYLOAD_CAPABILITY_BASE_IDX 4 +#define regINTERRUPT_CONTROL 0x4acc08 +#define regINTERRUPT_CONTROL_BASE_IDX 4 +#define regINTERRUPT_STATUS 0x4acc09 +#define regINTERRUPT_STATUS_BASE_IDX 4 +#define regWALL_CLOCK_COUNTER 0x4acc0c +#define regWALL_CLOCK_COUNTER_BASE_IDX 4 +#define regSTREAM_SYNCHRONIZATION 0x4acc0e +#define regSTREAM_SYNCHRONIZATION_BASE_IDX 4 +#define regCORB_LOWER_BASE_ADDRESS 0x4acc10 +#define regCORB_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regCORB_UPPER_BASE_ADDRESS 0x4acc11 +#define regCORB_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZCONTROLLER0_CORB_WRITE_POINTER 0x4acc12 +#define regAZCONTROLLER0_CORB_WRITE_POINTER_BASE_IDX 4 +#define regAZCONTROLLER0_CORB_READ_POINTER 0x4acc12 +#define regAZCONTROLLER0_CORB_READ_POINTER_BASE_IDX 4 +#define regAZCONTROLLER0_CORB_CONTROL 0x4acc13 +#define regAZCONTROLLER0_CORB_CONTROL_BASE_IDX 4 +#define regAZCONTROLLER0_CORB_STATUS 0x4acc13 +#define regAZCONTROLLER0_CORB_STATUS_BASE_IDX 4 +#define regAZCONTROLLER0_CORB_SIZE 0x4acc13 +#define regAZCONTROLLER0_CORB_SIZE_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_LOWER_BASE_ADDRESS 0x4acc14 +#define regAZCONTROLLER0_RIRB_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_UPPER_BASE_ADDRESS 0x4acc15 +#define regAZCONTROLLER0_RIRB_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_WRITE_POINTER 0x4acc16 +#define regAZCONTROLLER0_RIRB_WRITE_POINTER_BASE_IDX 4 +#define regAZCONTROLLER0_RESPONSE_INTERRUPT_COUNT 0x4acc16 +#define regAZCONTROLLER0_RESPONSE_INTERRUPT_COUNT_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_CONTROL 0x4acc17 +#define regAZCONTROLLER0_RIRB_CONTROL_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_STATUS 0x4acc17 +#define regAZCONTROLLER0_RIRB_STATUS_BASE_IDX 4 +#define regAZCONTROLLER0_RIRB_SIZE 0x4acc17 +#define regAZCONTROLLER0_RIRB_SIZE_BASE_IDX 4 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE 0x4acc18 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_BASE_IDX 4 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x4acc18 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 4 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x4acc18 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 4 +#define regAZCONTROLLER0_IMMEDIATE_RESPONSE_INPUT_INTERFACE 0x4acc19 +#define regAZCONTROLLER0_IMMEDIATE_RESPONSE_INPUT_INTERFACE_BASE_IDX 4 +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_STATUS 0x4acc1a +#define regAZCONTROLLER0_IMMEDIATE_COMMAND_STATUS_BASE_IDX 4 +#define regAZCONTROLLER0_DMA_POSITION_LOWER_BASE_ADDRESS 0x4acc1c +#define regAZCONTROLLER0_DMA_POSITION_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZCONTROLLER0_DMA_POSITION_UPPER_BASE_ADDRESS 0x4acc1d +#define regAZCONTROLLER0_DMA_POSITION_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZCONTROLLER0_WALL_CLOCK_COUNTER_ALIAS 0x4ad40c +#define regAZCONTROLLER0_WALL_CLOCK_COUNTER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azendpoint_azdec +// base address: 0x1300000 +#define regAZENDPOINT0_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x4acc18 +#define regAZENDPOINT0_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 4 +#define regAZENDPOINT0_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x4acc18 +#define regAZENDPOINT0_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azroot_azdec +// base address: 0x1300000 +#define regAZROOT0_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x4acc18 +#define regAZROOT0_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 4 +#define regAZROOT0_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x4acc18 +#define regAZROOT0_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream0_azdec +// base address: 0x1300000 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc20 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc21 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc22 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc23 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc24 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc24 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc26 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc27 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad421 +#define regAZSTREAM0_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream1_azdec +// base address: 0x1300020 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc28 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc29 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc2a +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc2b +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc2c +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc2c +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc2e +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc2f +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad429 +#define regAZSTREAM1_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream2_azdec +// base address: 0x1300040 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc30 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc31 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc32 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc33 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc34 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc34 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc36 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc37 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad431 +#define regAZSTREAM2_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream3_azdec +// base address: 0x1300060 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc38 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc39 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc3a +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc3b +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc3c +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc3c +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc3e +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc3f +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad439 +#define regAZSTREAM3_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream4_azdec +// base address: 0x1300080 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc40 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc41 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc42 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc43 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc44 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc44 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc46 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc47 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad441 +#define regAZSTREAM4_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream5_azdec +// base address: 0x13000a0 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc48 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc49 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc4a +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc4b +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc4c +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc4c +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc4e +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc4f +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad449 +#define regAZSTREAM5_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream6_azdec +// base address: 0x13000c0 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc50 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc51 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc52 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc53 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc54 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc54 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc56 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc57 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad451 +#define regAZSTREAM6_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_dc_hda_azstream7_azdec +// base address: 0x13000e0 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x4acc58 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x4acc59 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x4acc5a +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x4acc5b +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x4acc5c +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x4acc5c +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x4acc5e +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x4acc5f +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 4 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x4ad459 +#define regAZSTREAM7_0_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 4 + + +// addressBlock: dce_rsmu_dmu_rsmu_dmu_RsmuMmiopubDmuDec +// base address: 0x900f000 +#define regRSMU_MEM_POWER_CTRL2_DMU 0x0000 +#define regRSMU_MEM_POWER_CTRL2_DMU_BASE_IDX 5 +#define regRSMU_HARD_RESETB_DMU 0x0002 +#define regRSMU_HARD_RESETB_DMU_BASE_IDX 5 +#define regRSMU_MEM_POWER_CTRL_DMU 0x0006 +#define regRSMU_MEM_POWER_CTRL_DMU_BASE_IDX 5 +#define regRSMU_STRAP_CONTROL_DMU 0x000d +#define regRSMU_STRAP_CONTROL_DMU_BASE_IDX 5 +#define regRSMU_COUNTER_0_DMU 0x0077 +#define regRSMU_COUNTER_0_DMU_BASE_IDX 5 +#define regRSMU_COUNTER_1_DMU 0x0078 +#define regRSMU_COUNTER_1_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_ENABLE_P0_DMU 0x0079 +#define regRSMU_PWRMGT_INTR_ENABLE_P0_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_ENABLE_P1_DMU 0x007a +#define regRSMU_PWRMGT_INTR_ENABLE_P1_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_ENABLE_P2_DMU 0x007b +#define regRSMU_PWRMGT_INTR_ENABLE_P2_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P0_DMU 0x007c +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P0_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P1_DMU 0x007d +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P1_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P2_DMU 0x007e +#define regRSMU_PWRMGT_INTR_TARGET_ADDR_P2_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_CONFIG_P0_DMU 0x007f +#define regRSMU_PWRMGT_INTR_CONFIG_P0_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_CONFIG_P1_DMU 0x0080 +#define regRSMU_PWRMGT_INTR_CONFIG_P1_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_CONFIG_P2_DMU 0x0081 +#define regRSMU_PWRMGT_INTR_CONFIG_P2_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_STATUS_DMU 0x0082 +#define regRSMU_PWRMGT_INTR_STATUS_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_PENDING_P0_DMU 0x0083 +#define regRSMU_PWRMGT_INTR_PENDING_P0_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_PENDING_P1_DMU 0x0084 +#define regRSMU_PWRMGT_INTR_PENDING_P1_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_PENDING_P2_DMU 0x0085 +#define regRSMU_PWRMGT_INTR_PENDING_P2_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_TYPE_DMU 0x0086 +#define regRSMU_PWRMGT_INTR_TYPE_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_INTERCEPT_DMU 0x0087 +#define regRSMU_PWRMGT_INTR_INTERCEPT_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_CLEAR_DMU 0x0088 +#define regRSMU_PWRMGT_INTR_CLEAR_DMU_BASE_IDX 5 +#define regRSMU_MMIOPUB_SCRATCH_REG_0_DMU 0x008a +#define regRSMU_MMIOPUB_SCRATCH_REG_0_DMU_BASE_IDX 5 +#define regRSMU_VF_ENABLE_DMU 0x008b +#define regRSMU_VF_ENABLE_DMU_BASE_IDX 5 +#define regRSMU_MGCG_CONTROL_DMU 0x008c +#define regRSMU_MGCG_CONTROL_DMU_BASE_IDX 5 +#define regRSMU_AXI_MASTER_QOS_CNTL_DMU 0x008e +#define regRSMU_AXI_MASTER_QOS_CNTL_DMU_BASE_IDX 5 +#define regRSMU_MASTER_ERROR_COUNTER_DMU 0x008f +#define regRSMU_MASTER_ERROR_COUNTER_DMU_BASE_IDX 5 +#define regRSMU_SLAVE_TIMEOUT_VALUE_DMU 0x0090 +#define regRSMU_SLAVE_TIMEOUT_VALUE_DMU_BASE_IDX 5 +#define regRSMU_RESET_TIMEOUT_CONTROL_DMU 0x0091 +#define regRSMU_RESET_TIMEOUT_CONTROL_DMU_BASE_IDX 5 +#define regRSMU_SLAVE_ERROR_COUNTER_DMU 0x0092 +#define regRSMU_SLAVE_ERROR_COUNTER_DMU_BASE_IDX 5 +#define regRSMU_DBG_MUX_CONTROL_DMU 0x0093 +#define regRSMU_DBG_MUX_CONTROL_DMU_BASE_IDX 5 +#define regRSMU_IH_RESET_CNTL_DMU 0x00ba +#define regRSMU_IH_RESET_CNTL_DMU_BASE_IDX 5 +#define regRSMU_GOLDEN_COUNTER_0_DMU 0x00bc +#define regRSMU_GOLDEN_COUNTER_0_DMU_BASE_IDX 5 +#define regRSMU_GOLDEN_COUNTER_1_DMU 0x00bd +#define regRSMU_GOLDEN_COUNTER_1_DMU_BASE_IDX 5 +#define regRSMU_IP_CLOCK_GATE_CNTL_DMU 0x00be +#define regRSMU_IP_CLOCK_GATE_CNTL_DMU_BASE_IDX 5 +#define regRSMU_MSMU_FETCH_FUSE_DMU 0x00ef +#define regRSMU_MSMU_FETCH_FUSE_DMU_BASE_IDX 5 +#define regRSMU_STRAP_STATUS_DMU 0x00f1 +#define regRSMU_STRAP_STATUS_DMU_BASE_IDX 5 +#define regRSMU_SMS_FUSE_CLEAR_SET0_DMU 0x00f2 +#define regRSMU_SMS_FUSE_CLEAR_SET0_DMU_BASE_IDX 5 +#define regRSMU_PWRMGT_INTR_MCM_ADDR_DMU 0x0118 +#define regRSMU_PWRMGT_INTR_MCM_ADDR_DMU_BASE_IDX 5 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_DMU 0x0119 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_DMU_BASE_IDX 5 +#define regRSMU_XBAR_CG_MISC_DMU 0x011b +#define regRSMU_XBAR_CG_MISC_DMU_BASE_IDX 5 +#define regRSMU_XBAR_CG_CTRL_DMU 0x011c +#define regRSMU_XBAR_CG_CTRL_DMU_BASE_IDX 5 +#define regRSMU_IH_MCM_ADDR_DMU 0x011d +#define regRSMU_IH_MCM_ADDR_DMU_BASE_IDX 5 + + +// addressBlock: dce_rsmu_dmu_rsmu_dmu_RsmuMmioextDmuDec +// base address: 0x900f780 +#define regRSMU_SOFT_RESETB_DMU 0x01e0 +#define regRSMU_SOFT_RESETB_DMU_BASE_IDX 5 +#define regRSMU_IH_CREDIT_DMU 0x01e5 +#define regRSMU_IH_CREDIT_DMU_BASE_IDX 5 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_DMU 0x01e7 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_DMU_BASE_IDX 5 +#define regRSMU_TIMEOUT_ERROR_LOG_REG_DMU 0x01ee +#define regRSMU_TIMEOUT_ERROR_LOG_REG_DMU_BASE_IDX 5 +#define regRSMU_IP_MASTER_STATUS_DMU 0x01ef +#define regRSMU_IP_MASTER_STATUS_DMU_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_DMU 0x01f0 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_DMU_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_DMU 0x01f1 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_DMU_BASE_IDX 5 +#define regRSMU_VERSION_DMU 0x01f5 +#define regRSMU_VERSION_DMU_BASE_IDX 5 +#define regRSMU_IH_COOKIE_WRITE_ADDR_DMU 0x01ff +#define regRSMU_IH_COOKIE_WRITE_ADDR_DMU_BASE_IDX 5 + + +// addressBlock: dce_rsmu_dmu_rsmu_dmu_RsmuMmiosecDmuDec +// base address: 0x900f800 +#define regRSMU_AEB_OVERRIDE_0_DMU 0x0202 +#define regRSMU_AEB_OVERRIDE_0_DMU_BASE_IDX 5 +#define regRSMU_AEB_OVERRIDE_1_DMU 0x0203 +#define regRSMU_AEB_OVERRIDE_1_DMU_BASE_IDX 5 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_DMU 0x0371 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_DMU_BASE_IDX 5 +#define regRSMU_AEB_VALUE_0_DMU 0x0373 +#define regRSMU_AEB_VALUE_0_DMU_BASE_IDX 5 +#define regRSMU_AEB_VALUE_1_DMU 0x0374 +#define regRSMU_AEB_VALUE_1_DMU_BASE_IDX 5 + + +// addressBlock: dce_rsmu_dio_rsmu_dio_RsmuMmiopubDioDec +// base address: 0x9010000 +#define regRSMU_MEM_POWER_CTRL2_DIO 0x0400 +#define regRSMU_MEM_POWER_CTRL2_DIO_BASE_IDX 5 +#define regRSMU_HARD_RESETB_DIO 0x0402 +#define regRSMU_HARD_RESETB_DIO_BASE_IDX 5 +#define regRSMU_PUB_FUSE_ADDR_DIO 0x0403 +#define regRSMU_PUB_FUSE_ADDR_DIO_BASE_IDX 5 +#define regRSMU_ROM_ADDR_DIO 0x0405 +#define regRSMU_ROM_ADDR_DIO_BASE_IDX 5 +#define regRSMU_MEM_POWER_CTRL_DIO 0x0406 +#define regRSMU_MEM_POWER_CTRL_DIO_BASE_IDX 5 +#define regRSMU_MP0_STRAPRX_ADDR_DIO 0x0407 +#define regRSMU_MP0_STRAPRX_ADDR_DIO_BASE_IDX 5 +#define regRSMU_MP0_STRAPRX_DATA_DIO 0x0408 +#define regRSMU_MP0_STRAPRX_DATA_DIO_BASE_IDX 5 +#define regRSMU_PIN_STRAP_DATA_DIO 0x0409 +#define regRSMU_PIN_STRAP_DATA_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_CFG_DIO 0x040a +#define regRSMU_SMS_FUSE_CFG_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_BASE_DIO 0x040b +#define regRSMU_SMS_FUSE_ADDR_BASE_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_DIO 0x040c +#define regRSMU_SMS_FUSE_ADDR_OFFSET_DIO_BASE_IDX 5 +#define regRSMU_STRAP_CONTROL_DIO 0x040d +#define regRSMU_STRAP_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET1_DIO 0x040e +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET1_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET2_DIO 0x040f +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET2_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET3_DIO 0x0410 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET3_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_CNTL_SET_NONE_DEFAULT_DIO 0x0411 +#define regRSMU_SMS_FUSE_CNTL_SET_NONE_DEFAULT_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_STATUS_SET_NONE_DEFAULT_DIO 0x0412 +#define regRSMU_SMS_FUSE_STATUS_SET_NONE_DEFAULT_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET4_DIO 0x0413 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET4_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET5_DIO 0x0414 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET5_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET6_DIO 0x0415 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET6_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET7_DIO 0x0416 +#define regRSMU_SMS_FUSE_ADDR_OFFSET_GRP_SET7_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_STATUS_SET_NONE_DEFAULT1_DIO 0x0417 +#define regRSMU_SMS_FUSE_STATUS_SET_NONE_DEFAULT1_DIO_BASE_IDX 5 +#define regRSMU_CAC_CONTROL_DIO 0x0450 +#define regRSMU_CAC_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_MASK_LO_DIO 0x0451 +#define regRSMU_CAC_ACC_MASK_LO_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_0_DIO 0x0452 +#define regRSMU_CAC_WEIGHT_0_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_1_DIO 0x0453 +#define regRSMU_CAC_WEIGHT_1_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_2_DIO 0x0454 +#define regRSMU_CAC_WEIGHT_2_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_3_DIO 0x0455 +#define regRSMU_CAC_WEIGHT_3_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_4_DIO 0x0456 +#define regRSMU_CAC_WEIGHT_4_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_5_DIO 0x0457 +#define regRSMU_CAC_WEIGHT_5_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_6_DIO 0x0458 +#define regRSMU_CAC_WEIGHT_6_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_7_DIO 0x0459 +#define regRSMU_CAC_WEIGHT_7_DIO_BASE_IDX 5 +#define regRSMU_CAC_WEIGHT_8_DIO 0x045a +#define regRSMU_CAC_WEIGHT_8_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_MASK_HI_DIO 0x046c +#define regRSMU_CAC_ACC_MASK_HI_DIO_BASE_IDX 5 +#define regRSMU_MMIOPUB_SCRATCH_REG_0_DIO 0x048a +#define regRSMU_MMIOPUB_SCRATCH_REG_0_DIO_BASE_IDX 5 +#define regRSMU_VF_ENABLE_DIO 0x048b +#define regRSMU_VF_ENABLE_DIO_BASE_IDX 5 +#define regRSMU_MGCG_CONTROL_DIO 0x048c +#define regRSMU_MGCG_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_AXI_MASTER_QOS_CNTL_DIO 0x048e +#define regRSMU_AXI_MASTER_QOS_CNTL_DIO_BASE_IDX 5 +#define regRSMU_MASTER_ERROR_COUNTER_DIO 0x048f +#define regRSMU_MASTER_ERROR_COUNTER_DIO_BASE_IDX 5 +#define regRSMU_SLAVE_TIMEOUT_VALUE_DIO 0x0490 +#define regRSMU_SLAVE_TIMEOUT_VALUE_DIO_BASE_IDX 5 +#define regRSMU_RESET_TIMEOUT_CONTROL_DIO 0x0491 +#define regRSMU_RESET_TIMEOUT_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_SLAVE_ERROR_COUNTER_DIO 0x0492 +#define regRSMU_SLAVE_ERROR_COUNTER_DIO_BASE_IDX 5 +#define regRSMU_DBG_MUX_CONTROL_DIO 0x0493 +#define regRSMU_DBG_MUX_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_IP_CLOCK_GATE_CNTL_DIO 0x04be +#define regRSMU_IP_CLOCK_GATE_CNTL_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_0_DIO 0x04bf +#define regRSMU_CAC_ACC_0_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_1_DIO 0x04c0 +#define regRSMU_CAC_ACC_1_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_2_DIO 0x04c1 +#define regRSMU_CAC_ACC_2_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_3_DIO 0x04c2 +#define regRSMU_CAC_ACC_3_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_4_DIO 0x04c3 +#define regRSMU_CAC_ACC_4_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_5_DIO 0x04c4 +#define regRSMU_CAC_ACC_5_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_6_DIO 0x04c5 +#define regRSMU_CAC_ACC_6_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_7_DIO 0x04c6 +#define regRSMU_CAC_ACC_7_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_8_DIO 0x04c7 +#define regRSMU_CAC_ACC_8_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_9_DIO 0x04c8 +#define regRSMU_CAC_ACC_9_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_10_DIO 0x04c9 +#define regRSMU_CAC_ACC_10_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_11_DIO 0x04ca +#define regRSMU_CAC_ACC_11_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_12_DIO 0x04cb +#define regRSMU_CAC_ACC_12_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_13_DIO 0x04cc +#define regRSMU_CAC_ACC_13_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_14_DIO 0x04cd +#define regRSMU_CAC_ACC_14_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_15_DIO 0x04ce +#define regRSMU_CAC_ACC_15_DIO_BASE_IDX 5 +#define regRSMU_CAC_ACC_16_DIO 0x04cf +#define regRSMU_CAC_ACC_16_DIO_BASE_IDX 5 +#define regRSMU_MSMU_FETCH_FUSE_DIO 0x04ef +#define regRSMU_MSMU_FETCH_FUSE_DIO_BASE_IDX 5 +#define regRSMU_MSMU_FETCH_ROM_DIO 0x04f0 +#define regRSMU_MSMU_FETCH_ROM_DIO_BASE_IDX 5 +#define regRSMU_STRAP_STATUS_DIO 0x04f1 +#define regRSMU_STRAP_STATUS_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_CLEAR_SET0_DIO 0x04f2 +#define regRSMU_SMS_FUSE_CLEAR_SET0_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_0_DIO 0x04f3 +#define regRSMU_SMS_FUSE_DATA_GRP_0_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_1_DIO 0x04f4 +#define regRSMU_SMS_FUSE_DATA_GRP_1_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_2_DIO 0x04f5 +#define regRSMU_SMS_FUSE_DATA_GRP_2_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_3_DIO 0x04f6 +#define regRSMU_SMS_FUSE_DATA_GRP_3_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_4_DIO 0x04f7 +#define regRSMU_SMS_FUSE_DATA_GRP_4_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_5_DIO 0x04f8 +#define regRSMU_SMS_FUSE_DATA_GRP_5_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_6_DIO 0x04f9 +#define regRSMU_SMS_FUSE_DATA_GRP_6_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_7_DIO 0x04fa +#define regRSMU_SMS_FUSE_DATA_GRP_7_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_8_DIO 0x04fb +#define regRSMU_SMS_FUSE_DATA_GRP_8_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_9_DIO 0x04fc +#define regRSMU_SMS_FUSE_DATA_GRP_9_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_DATA_GRP_10_DIO 0x04fd +#define regRSMU_SMS_FUSE_DATA_GRP_10_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_FIFO_EMPTY_DIO 0x0513 +#define regRSMU_SMS_FUSE_FIFO_EMPTY_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_FIFO_FULL_DIO 0x0514 +#define regRSMU_SMS_FUSE_FIFO_FULL_DIO_BASE_IDX 5 +#define regRSMU_ASP_FUSE_ADDR_DIO 0x0515 +#define regRSMU_ASP_FUSE_ADDR_DIO_BASE_IDX 5 +#define regRSMU_ASP_FUSE_DATA_DIO 0x0516 +#define regRSMU_ASP_FUSE_DATA_DIO_BASE_IDX 5 +#define regRSMU_ASP_STRAP_CONTROL_DIO 0x0517 +#define regRSMU_ASP_STRAP_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_DIO 0x0519 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_DIO_BASE_IDX 5 +#define regRSMU_XBAR_CG_MISC_DIO 0x051b +#define regRSMU_XBAR_CG_MISC_DIO_BASE_IDX 5 +#define regRSMU_XBAR_CG_CTRL_DIO 0x051c +#define regRSMU_XBAR_CG_CTRL_DIO_BASE_IDX 5 + + +// addressBlock: dce_rsmu_dio_rsmu_dio_RsmuMmioextDioDec +// base address: 0x9010780 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_DIO 0x05e7 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_DIO_BASE_IDX 5 +#define regRSMU_SW_STRAPRX_ADDR_DIO 0x05eb +#define regRSMU_SW_STRAPRX_ADDR_DIO_BASE_IDX 5 +#define regRSMU_SW_STRAPRX_DATA_DIO 0x05ec +#define regRSMU_SW_STRAPRX_DATA_DIO_BASE_IDX 5 +#define regRSMU_SW_STRAP_CONTROL_DIO 0x05ed +#define regRSMU_SW_STRAP_CONTROL_DIO_BASE_IDX 5 +#define regRSMU_TIMEOUT_ERROR_LOG_REG_DIO 0x05ee +#define regRSMU_TIMEOUT_ERROR_LOG_REG_DIO_BASE_IDX 5 +#define regRSMU_IP_MASTER_STATUS_DIO 0x05ef +#define regRSMU_IP_MASTER_STATUS_DIO_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_DIO 0x05f0 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_DIO_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_DIO 0x05f1 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_DIO_BASE_IDX 5 +#define regRSMU_VERSION_DIO 0x05f5 +#define regRSMU_VERSION_DIO_BASE_IDX 5 + + +// addressBlock: dce_rsmu_dio_rsmu_dio_RsmuMmiosecDioDec +// base address: 0x9010800 +#define regRSMU_AEB_OVERRIDE_0_DIO 0x0602 +#define regRSMU_AEB_OVERRIDE_0_DIO_BASE_IDX 5 +#define regRSMU_AEB_OVERRIDE_1_DIO 0x0603 +#define regRSMU_AEB_OVERRIDE_1_DIO_BASE_IDX 5 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_DIO 0x0771 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_DIO_BASE_IDX 5 +#define regRSMU_AEB_VALUE_0_DIO 0x0773 +#define regRSMU_AEB_VALUE_0_DIO_BASE_IDX 5 +#define regRSMU_AEB_VALUE_1_DIO 0x0774 +#define regRSMU_AEB_VALUE_1_DIO_BASE_IDX 5 + + +// addressBlock: dce_rsmu_hda_rsmu_hda_RsmuMmiopubHdaDec +// base address: 0x9012000 +#define regRSMU_MEM_POWER_CTRL2_HDA 0x0c00 +#define regRSMU_MEM_POWER_CTRL2_HDA_BASE_IDX 5 +#define regRSMU_HARD_RESETB_HDA 0x0c02 +#define regRSMU_HARD_RESETB_HDA_BASE_IDX 5 +#define regRSMU_MEM_POWER_CTRL_HDA 0x0c06 +#define regRSMU_MEM_POWER_CTRL_HDA_BASE_IDX 5 +#define regRSMU_STRAP_CONTROL_HDA 0x0c0d +#define regRSMU_STRAP_CONTROL_HDA_BASE_IDX 5 +#define regRSMU_MMIOPUB_SCRATCH_REG_0_HDA 0x0c8a +#define regRSMU_MMIOPUB_SCRATCH_REG_0_HDA_BASE_IDX 5 +#define regRSMU_VF_ENABLE_HDA 0x0c8b +#define regRSMU_VF_ENABLE_HDA_BASE_IDX 5 +#define regRSMU_MGCG_CONTROL_HDA 0x0c8c +#define regRSMU_MGCG_CONTROL_HDA_BASE_IDX 5 +#define regRSMU_AXI_MASTER_QOS_CNTL_HDA 0x0c8e +#define regRSMU_AXI_MASTER_QOS_CNTL_HDA_BASE_IDX 5 +#define regRSMU_MASTER_ERROR_COUNTER_HDA 0x0c8f +#define regRSMU_MASTER_ERROR_COUNTER_HDA_BASE_IDX 5 +#define regRSMU_SLAVE_TIMEOUT_VALUE_HDA 0x0c90 +#define regRSMU_SLAVE_TIMEOUT_VALUE_HDA_BASE_IDX 5 +#define regRSMU_RESET_TIMEOUT_CONTROL_HDA 0x0c91 +#define regRSMU_RESET_TIMEOUT_CONTROL_HDA_BASE_IDX 5 +#define regRSMU_SLAVE_ERROR_COUNTER_HDA 0x0c92 +#define regRSMU_SLAVE_ERROR_COUNTER_HDA_BASE_IDX 5 +#define regRSMU_DBG_MUX_CONTROL_HDA 0x0c93 +#define regRSMU_DBG_MUX_CONTROL_HDA_BASE_IDX 5 +#define regRSMU_IP_CLOCK_GATE_CNTL_HDA 0x0cbe +#define regRSMU_IP_CLOCK_GATE_CNTL_HDA_BASE_IDX 5 +#define regRSMU_MSMU_FETCH_FUSE_HDA 0x0cef +#define regRSMU_MSMU_FETCH_FUSE_HDA_BASE_IDX 5 +#define regRSMU_STRAP_STATUS_HDA 0x0cf1 +#define regRSMU_STRAP_STATUS_HDA_BASE_IDX 5 +#define regRSMU_SMS_FUSE_CLEAR_SET0_HDA 0x0cf2 +#define regRSMU_SMS_FUSE_CLEAR_SET0_HDA_BASE_IDX 5 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_HDA 0x0d19 +#define regRSMU_SMS_FUSE_RETRIGGER_SET0_HDA_BASE_IDX 5 +#define regRSMU_XBAR_CG_MISC_HDA 0x0d1b +#define regRSMU_XBAR_CG_MISC_HDA_BASE_IDX 5 +#define regRSMU_XBAR_CG_CTRL_HDA 0x0d1c +#define regRSMU_XBAR_CG_CTRL_HDA_BASE_IDX 5 + + +// addressBlock: dce_rsmu_hda_rsmu_hda_RsmuMmioextHdaDec +// base address: 0x9012780 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_HDA 0x0de7 +#define regRSMU_TIMEOUT_ERROR_LOG_REG1_HDA_BASE_IDX 5 +#define regRSMU_TIMEOUT_ERROR_LOG_REG_HDA 0x0dee +#define regRSMU_TIMEOUT_ERROR_LOG_REG_HDA_BASE_IDX 5 +#define regRSMU_IP_MASTER_STATUS_HDA 0x0def +#define regRSMU_IP_MASTER_STATUS_HDA_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_HDA 0x0df0 +#define regRSMU_MMIOEXT_SCRATCH_REG_0_HDA_BASE_IDX 5 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_HDA 0x0df1 +#define regRSMU_MMIOEXT_SCRATCH_REG_1_HDA_BASE_IDX 5 +#define regRSMU_VERSION_HDA 0x0df5 +#define regRSMU_VERSION_HDA_BASE_IDX 5 + + +// addressBlock: dce_rsmu_hda_rsmu_hda_RsmuMmiosecHdaDec +// base address: 0x9012800 +#define regRSMU_AEB_OVERRIDE_0_HDA 0x0e02 +#define regRSMU_AEB_OVERRIDE_0_HDA_BASE_IDX 5 +#define regRSMU_AEB_OVERRIDE_1_HDA 0x0e03 +#define regRSMU_AEB_OVERRIDE_1_HDA_BASE_IDX 5 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_HDA 0x0f71 +#define regRSMU_MMIOSEC_SCRATCH_REG_0_HDA_BASE_IDX 5 +#define regRSMU_AEB_VALUE_0_HDA 0x0f73 +#define regRSMU_AEB_VALUE_0_HDA_BASE_IDX 5 +#define regRSMU_AEB_VALUE_1_HDA 0x0f74 +#define regRSMU_AEB_VALUE_1_HDA_BASE_IDX 5 + + +// addressBlock: dce_dc_hda_azcontroller_azdec +// base address: 0x0 +#define regAZCONTROLLER1_CORB_WRITE_POINTER 0x0000 +#define regAZCONTROLLER1_CORB_WRITE_POINTER_BASE_IDX 0 +#define regAZCONTROLLER1_CORB_READ_POINTER 0x0000 +#define regAZCONTROLLER1_CORB_READ_POINTER_BASE_IDX 0 +#define regAZCONTROLLER1_CORB_CONTROL 0x0001 +#define regAZCONTROLLER1_CORB_CONTROL_BASE_IDX 0 +#define regAZCONTROLLER1_CORB_STATUS 0x0001 +#define regAZCONTROLLER1_CORB_STATUS_BASE_IDX 0 +#define regAZCONTROLLER1_CORB_SIZE 0x0001 +#define regAZCONTROLLER1_CORB_SIZE_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_LOWER_BASE_ADDRESS 0x0002 +#define regAZCONTROLLER1_RIRB_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_UPPER_BASE_ADDRESS 0x0003 +#define regAZCONTROLLER1_RIRB_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_WRITE_POINTER 0x0004 +#define regAZCONTROLLER1_RIRB_WRITE_POINTER_BASE_IDX 0 +#define regAZCONTROLLER1_RESPONSE_INTERRUPT_COUNT 0x0004 +#define regAZCONTROLLER1_RESPONSE_INTERRUPT_COUNT_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_CONTROL 0x0005 +#define regAZCONTROLLER1_RIRB_CONTROL_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_STATUS 0x0005 +#define regAZCONTROLLER1_RIRB_STATUS_BASE_IDX 0 +#define regAZCONTROLLER1_RIRB_SIZE 0x0005 +#define regAZCONTROLLER1_RIRB_SIZE_BASE_IDX 0 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE 0x0006 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_BASE_IDX 0 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x0006 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 0 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x0006 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 0 +#define regAZCONTROLLER1_IMMEDIATE_RESPONSE_INPUT_INTERFACE 0x0007 +#define regAZCONTROLLER1_IMMEDIATE_RESPONSE_INPUT_INTERFACE_BASE_IDX 0 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_STATUS 0x0008 +#define regAZCONTROLLER1_IMMEDIATE_COMMAND_STATUS_BASE_IDX 0 +#define regAZCONTROLLER1_DMA_POSITION_LOWER_BASE_ADDRESS 0x000a +#define regAZCONTROLLER1_DMA_POSITION_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZCONTROLLER1_DMA_POSITION_UPPER_BASE_ADDRESS 0x000b +#define regAZCONTROLLER1_DMA_POSITION_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZCONTROLLER1_WALL_CLOCK_COUNTER_ALIAS 0x074c +#define regAZCONTROLLER1_WALL_CLOCK_COUNTER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azendpoint_azdec +// base address: 0x0 +#define regAZENDPOINT1_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x0006 +#define regAZENDPOINT1_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 0 +#define regAZENDPOINT1_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x0006 +#define regAZENDPOINT1_AZENDPOINT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 0 + + +// addressBlock: dce_dc_hda_azroot_azdec +// base address: 0x0 +#define regAZROOT1_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA 0x0006 +#define regAZROOT1_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_DATA_BASE_IDX 0 +#define regAZROOT1_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX 0x0006 +#define regAZROOT1_AZROOT_IMMEDIATE_COMMAND_OUTPUT_INTERFACE_INDEX_BASE_IDX 0 + + +// addressBlock: dce_dc_hda_azstream0_azdec +// base address: 0x0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x000e +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x000f +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0010 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0011 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x0012 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x0012 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x0014 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x0015 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0761 +#define regAZSTREAM0_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream1_azdec +// base address: 0x20 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x0016 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x0017 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0018 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0019 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x001a +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x001a +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x001c +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x001d +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0769 +#define regAZSTREAM1_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream2_azdec +// base address: 0x40 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x001e +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x001f +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0020 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0021 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x0022 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x0022 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x0024 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x0025 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0771 +#define regAZSTREAM2_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream3_azdec +// base address: 0x60 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x0026 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x0027 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0028 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0029 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x002a +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x002a +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x002c +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x002d +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0779 +#define regAZSTREAM3_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream4_azdec +// base address: 0x80 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x002e +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x002f +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0030 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0031 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x0032 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x0032 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x0034 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x0035 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0781 +#define regAZSTREAM4_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream5_azdec +// base address: 0xa0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x0036 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x0037 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0038 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0039 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x003a +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x003a +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x003c +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x003d +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0789 +#define regAZSTREAM5_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream6_azdec +// base address: 0xc0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x003e +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x003f +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0040 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0041 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x0042 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x0042 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x0044 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x0045 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0791 +#define regAZSTREAM6_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_hda_azstream7_azdec +// base address: 0xe0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS 0x0046 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_CONTROL_AND_STATUS_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER 0x0047 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH 0x0048 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_CYCLIC_BUFFER_LENGTH_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX 0x0049 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LAST_VALID_INDEX_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE 0x004a +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_FIFO_SIZE_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT 0x004a +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_FORMAT_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS 0x004c +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_LOWER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS 0x004d +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_BDL_POINTER_UPPER_BASE_ADDRESS_BASE_IDX 0 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS 0x0799 +#define regAZSTREAM7_1_OUTPUT_STREAM_DESCRIPTOR_LINK_POSITION_IN_CURRENT_BUFFER_ALIAS_BASE_IDX 1 + + +// addressBlock: dce_dc_dccg_dccg_dispdec +// base address: 0x0 +#define regPHYPLLA_PIXCLK_RESYNC_CNTL 0x0040 +#define regPHYPLLA_PIXCLK_RESYNC_CNTL_BASE_IDX 1 +#define regPHYPLLB_PIXCLK_RESYNC_CNTL 0x0041 +#define regPHYPLLB_PIXCLK_RESYNC_CNTL_BASE_IDX 1 +#define regPHYPLLC_PIXCLK_RESYNC_CNTL 0x0042 +#define regPHYPLLC_PIXCLK_RESYNC_CNTL_BASE_IDX 1 +#define regPHYPLLD_PIXCLK_RESYNC_CNTL 0x0043 +#define regPHYPLLD_PIXCLK_RESYNC_CNTL_BASE_IDX 1 +#define regDP_DTO_DBUF_EN 0x0044 +#define regDP_DTO_DBUF_EN_BASE_IDX 1 +#define regDSCCLK3_DTO_PARAM 0x0045 +#define regDSCCLK3_DTO_PARAM_BASE_IDX 1 +#define regDPREFCLK_CGTT_BLK_CTRL_REG 0x0048 +#define regDPREFCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL4 0x0049 +#define regDCCG_GATE_DISABLE_CNTL4_BASE_IDX 1 +#define regDPSTREAMCLK_CNTL 0x004a +#define regDPSTREAMCLK_CNTL_BASE_IDX 1 +#define regREFCLK_CGTT_BLK_CTRL_REG 0x004b +#define regREFCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regDCCG_GLOBAL_FGCG_REP_CNTL 0x0050 +#define regDCCG_GLOBAL_FGCG_REP_CNTL_BASE_IDX 1 +#define regOTG_ADD_DROP_PIXEL_CNTL 0x0056 +#define regOTG_ADD_DROP_PIXEL_CNTL_BASE_IDX 1 +#define regDIO_DME_MEM_RCLK_CNTL 0x0061 +#define regDIO_DME_MEM_RCLK_CNTL_BASE_IDX 1 +#define regHPO_DME_MEM_RCLK_CNTL 0x0062 +#define regHPO_DME_MEM_RCLK_CNTL_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL7 0x0063 +#define regDCCG_GATE_DISABLE_CNTL7_BASE_IDX 1 +#define regSYMCLK32_SE_CNTL 0x0065 +#define regSYMCLK32_SE_CNTL_BASE_IDX 1 +#define regSYMCLK32_LE_CNTL 0x0066 +#define regSYMCLK32_LE_CNTL_BASE_IDX 1 +#define regDTBCLK_P_CNTL 0x0068 +#define regDTBCLK_P_CNTL_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL5 0x0069 +#define regDCCG_GATE_DISABLE_CNTL5_BASE_IDX 1 +#define regDSCCLK0_DTO_PARAM 0x006c +#define regDSCCLK0_DTO_PARAM_BASE_IDX 1 +#define regDSCCLK1_DTO_PARAM 0x006d +#define regDSCCLK1_DTO_PARAM_BASE_IDX 1 +#define regDSCCLK2_DTO_PARAM 0x006e +#define regDSCCLK2_DTO_PARAM_BASE_IDX 1 +#define regOTG_PIXEL_RATE_DIV 0x006f +#define regOTG_PIXEL_RATE_DIV_BASE_IDX 1 +#define regMILLISECOND_TIME_BASE_DIV 0x0070 +#define regMILLISECOND_TIME_BASE_DIV_BASE_IDX 1 +#define regDISPCLK_FREQ_CHANGE_CNTL 0x0071 +#define regDISPCLK_FREQ_CHANGE_CNTL_BASE_IDX 1 +#define regDC_MEM_GLOBAL_PWR_REQ_CNTL 0x0072 +#define regDC_MEM_GLOBAL_PWR_REQ_CNTL_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL 0x0074 +#define regDCCG_GATE_DISABLE_CNTL_BASE_IDX 1 +#define regDISPCLK_CGTT_BLK_CTRL_REG 0x0075 +#define regDISPCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regSOCCLK_CGTT_BLK_CTRL_REG 0x0076 +#define regSOCCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regMICROSECOND_TIME_BASE_DIV 0x007b +#define regMICROSECOND_TIME_BASE_DIV_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL2 0x007c +#define regDCCG_GATE_DISABLE_CNTL2_BASE_IDX 1 +#define regSYMCLK_CGTT_BLK_CTRL_REG 0x007d +#define regSYMCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regOTG0_PIXEL_RATE_CNTL 0x0080 +#define regOTG0_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regDP_DTO0_PHASE 0x0081 +#define regDP_DTO0_PHASE_BASE_IDX 1 +#define regDP_DTO0_MODULO 0x0082 +#define regDP_DTO0_MODULO_BASE_IDX 1 +#define regOTG0_PHYPLL_PIXEL_RATE_CNTL 0x0083 +#define regOTG0_PHYPLL_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regOTG1_PIXEL_RATE_CNTL 0x0084 +#define regOTG1_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regDP_DTO1_PHASE 0x0085 +#define regDP_DTO1_PHASE_BASE_IDX 1 +#define regDP_DTO1_MODULO 0x0086 +#define regDP_DTO1_MODULO_BASE_IDX 1 +#define regOTG1_PHYPLL_PIXEL_RATE_CNTL 0x0087 +#define regOTG1_PHYPLL_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regOTG2_PIXEL_RATE_CNTL 0x0088 +#define regOTG2_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regDP_DTO2_PHASE 0x0089 +#define regDP_DTO2_PHASE_BASE_IDX 1 +#define regDP_DTO2_MODULO 0x008a +#define regDP_DTO2_MODULO_BASE_IDX 1 +#define regOTG2_PHYPLL_PIXEL_RATE_CNTL 0x008b +#define regOTG2_PHYPLL_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regOTG3_PIXEL_RATE_CNTL 0x008c +#define regOTG3_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regDP_DTO3_PHASE 0x008d +#define regDP_DTO3_PHASE_BASE_IDX 1 +#define regDP_DTO3_MODULO 0x008e +#define regDP_DTO3_MODULO_BASE_IDX 1 +#define regOTG3_PHYPLL_PIXEL_RATE_CNTL 0x008f +#define regOTG3_PHYPLL_PIXEL_RATE_CNTL_BASE_IDX 1 +#define regDPPCLK_CGTT_BLK_CTRL_REG 0x0098 +#define regDPPCLK_CGTT_BLK_CTRL_REG_BASE_IDX 1 +#define regDPPCLK0_DTO_PARAM 0x0099 +#define regDPPCLK0_DTO_PARAM_BASE_IDX 1 +#define regDPPCLK1_DTO_PARAM 0x009a +#define regDPPCLK1_DTO_PARAM_BASE_IDX 1 +#define regDPPCLK2_DTO_PARAM 0x009b +#define regDPPCLK2_DTO_PARAM_BASE_IDX 1 +#define regDPPCLK3_DTO_PARAM 0x009c +#define regDPPCLK3_DTO_PARAM_BASE_IDX 1 +#define regSYMCLKA_CLOCK_ENABLE 0x00a0 +#define regSYMCLKA_CLOCK_ENABLE_BASE_IDX 1 +#define regSYMCLKB_CLOCK_ENABLE 0x00a1 +#define regSYMCLKB_CLOCK_ENABLE_BASE_IDX 1 +#define regSYMCLKC_CLOCK_ENABLE 0x00a2 +#define regSYMCLKC_CLOCK_ENABLE_BASE_IDX 1 +#define regSYMCLKD_CLOCK_ENABLE 0x00a3 +#define regSYMCLKD_CLOCK_ENABLE_BASE_IDX 1 +#define regDCCG_SOFT_RESET 0x00a6 +#define regDCCG_SOFT_RESET_BASE_IDX 1 +#define regDSCCLK_DTO_CTRL 0x00a7 +#define regDSCCLK_DTO_CTRL_BASE_IDX 1 +#define regDPPCLK_CTRL 0x00a8 +#define regDPPCLK_CTRL_BASE_IDX 1 +#define regDCCG_GATE_DISABLE_CNTL6 0x00a9 +#define regDCCG_GATE_DISABLE_CNTL6_BASE_IDX 1 +#define regSYMCLK_PSP_CNTL 0x00aa +#define regSYMCLK_PSP_CNTL_BASE_IDX 1 +#define regDCCG_AUDIO_DTO_SOURCE 0x00ab +#define regDCCG_AUDIO_DTO_SOURCE_BASE_IDX 1 +#define regDCCG_AUDIO_DTO0_PHASE 0x00ac +#define regDCCG_AUDIO_DTO0_PHASE_BASE_IDX 1 +#define regDCCG_AUDIO_DTO0_MODULE 0x00ad +#define regDCCG_AUDIO_DTO0_MODULE_BASE_IDX 1 +#define regDCCG_AUDIO_DTO1_PHASE 0x00ae +#define regDCCG_AUDIO_DTO1_PHASE_BASE_IDX 1 +#define regDCCG_AUDIO_DTO1_MODULE 0x00af +#define regDCCG_AUDIO_DTO1_MODULE_BASE_IDX 1 +#define regDPPCLK_DTO_CTRL 0x00b6 +#define regDPPCLK_DTO_CTRL_BASE_IDX 1 +#define regDCCG_TEST_DEBUG_INDEX 0x00bc +#define regDCCG_TEST_DEBUG_INDEX_BASE_IDX 1 +#define regDCCG_TEST_DEBUG_DATA 0x00bd +#define regDCCG_TEST_DEBUG_DATA_BASE_IDX 1 +#define regHDMICHARCLK0_CLOCK_CNTL 0x004a +#define regHDMICHARCLK0_CLOCK_CNTL_BASE_IDX 2 +#define regPHYASYMCLK_CLOCK_CNTL 0x0052 +#define regPHYASYMCLK_CLOCK_CNTL_BASE_IDX 2 +#define regPHYBSYMCLK_CLOCK_CNTL 0x0053 +#define regPHYBSYMCLK_CLOCK_CNTL_BASE_IDX 2 +#define regPHYCSYMCLK_CLOCK_CNTL 0x0054 +#define regPHYCSYMCLK_CLOCK_CNTL_BASE_IDX 2 +#define regPHYDSYMCLK_CLOCK_CNTL 0x0055 +#define regPHYDSYMCLK_CLOCK_CNTL_BASE_IDX 2 +#define regHDMISTREAMCLK_CNTL 0x0059 +#define regHDMISTREAMCLK_CNTL_BASE_IDX 2 +#define regDCCG_GATE_DISABLE_CNTL3 0x005a +#define regDCCG_GATE_DISABLE_CNTL3_BASE_IDX 2 +#define regHDMISTREAMCLK0_DTO_PARAM 0x005b +#define regHDMISTREAMCLK0_DTO_PARAM_BASE_IDX 2 +#define regDSCCLK_SRC_SEL 0x0060 +#define regDSCCLK_SRC_SEL_BASE_IDX 2 + + +// addressBlock: dce_dc_dccg_dccg_dcperfmon0_dc_perfmon_dispdec +// base address: 0x0 +#define regDC_PERFMON0_PERFCOUNTER_CNTL 0x0000 +#define regDC_PERFMON0_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON0_PERFCOUNTER_CNTL2 0x0001 +#define regDC_PERFMON0_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON0_PERFCOUNTER_STATE 0x0002 +#define regDC_PERFMON0_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_CNTL 0x0003 +#define regDC_PERFMON0_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_CNTL2 0x0004 +#define regDC_PERFMON0_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_CVALUE_INT_MISC 0x0005 +#define regDC_PERFMON0_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_CVALUE_LOW 0x0006 +#define regDC_PERFMON0_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_HI 0x0007 +#define regDC_PERFMON0_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_LOW 0x0008 +#define regDC_PERFMON0_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_TEST_DEBUG_INDEX 0x0009 +#define regDC_PERFMON0_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON0_PERFMON_TEST_DEBUG_DATA 0x000a +#define regDC_PERFMON0_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dccg_dccg_dcperfmon1_dc_perfmon_dispdec +// base address: 0x30 +#define regDC_PERFMON1_PERFCOUNTER_CNTL 0x000c +#define regDC_PERFMON1_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON1_PERFCOUNTER_CNTL2 0x000d +#define regDC_PERFMON1_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON1_PERFCOUNTER_STATE 0x000e +#define regDC_PERFMON1_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_CNTL 0x000f +#define regDC_PERFMON1_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_CNTL2 0x0010 +#define regDC_PERFMON1_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_CVALUE_INT_MISC 0x0011 +#define regDC_PERFMON1_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_CVALUE_LOW 0x0012 +#define regDC_PERFMON1_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_HI 0x0013 +#define regDC_PERFMON1_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_LOW 0x0014 +#define regDC_PERFMON1_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_TEST_DEBUG_INDEX 0x0015 +#define regDC_PERFMON1_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON1_PERFMON_TEST_DEBUG_DATA 0x0016 +#define regDC_PERFMON1_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_fgsec_dispdec +// base address: 0x0 +#define regSECURE_CHECK_CONFIG 0x016e +#define regSECURE_CHECK_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP0_CONFIG 0x016f +#define regSECURE_GROUP0_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP1_CONFIG 0x0170 +#define regSECURE_GROUP1_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP2_CONFIG 0x0171 +#define regSECURE_GROUP2_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP3_CONFIG 0x0172 +#define regSECURE_GROUP3_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP4_CONFIG 0x0173 +#define regSECURE_GROUP4_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP5_CONFIG 0x0174 +#define regSECURE_GROUP5_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP6_CONFIG 0x0175 +#define regSECURE_GROUP6_CONFIG_BASE_IDX 2 +#define regSECURE_GROUP7_CONFIG 0x0176 +#define regSECURE_GROUP7_CONFIG_BASE_IDX 2 +#define regSECURE_INTERRUPT0_INFO0 0x0177 +#define regSECURE_INTERRUPT0_INFO0_BASE_IDX 2 +#define regSECURE_INTERRUPT0_INFO1 0x0178 +#define regSECURE_INTERRUPT0_INFO1_BASE_IDX 2 +#define regDMCUB_RBBMIF_SEC_CNTL 0x017a +#define regDMCUB_RBBMIF_SEC_CNTL_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_rbbmif_dispdec +// base address: 0x0 +#define regRBBMIF_TIMEOUT 0x017f +#define regRBBMIF_TIMEOUT_BASE_IDX 2 +#define regRBBMIF_STATUS 0x0180 +#define regRBBMIF_STATUS_BASE_IDX 2 +#define regRBBMIF_STATUS_2 0x0181 +#define regRBBMIF_STATUS_2_BASE_IDX 2 +#define regRBBMIF_INT_STATUS 0x0182 +#define regRBBMIF_INT_STATUS_BASE_IDX 2 +#define regRBBMIF_TIMEOUT_DIS 0x0183 +#define regRBBMIF_TIMEOUT_DIS_BASE_IDX 2 +#define regRBBMIF_TIMEOUT_DIS_2 0x0184 +#define regRBBMIF_TIMEOUT_DIS_2_BASE_IDX 2 +#define regRBBMIF_STATUS_FLAG 0x0185 +#define regRBBMIF_STATUS_FLAG_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_dmu_dcperfmon_dc_perfmon_dispdec +// base address: 0x2f8 +#define regDC_PERFMON2_PERFCOUNTER_CNTL 0x00be +#define regDC_PERFMON2_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON2_PERFCOUNTER_CNTL2 0x00bf +#define regDC_PERFMON2_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON2_PERFCOUNTER_STATE 0x00c0 +#define regDC_PERFMON2_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_CNTL 0x00c1 +#define regDC_PERFMON2_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_CNTL2 0x00c2 +#define regDC_PERFMON2_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_CVALUE_INT_MISC 0x00c3 +#define regDC_PERFMON2_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_CVALUE_LOW 0x00c4 +#define regDC_PERFMON2_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_HI 0x00c5 +#define regDC_PERFMON2_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_LOW 0x00c6 +#define regDC_PERFMON2_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_TEST_DEBUG_INDEX 0x00c7 +#define regDC_PERFMON2_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON2_PERFMON_TEST_DEBUG_DATA 0x00c8 +#define regDC_PERFMON2_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_ihc_dispdec +// base address: 0x0 +#define regDC_GPU_TIMER_START_POSITION_V_UPDATE 0x0126 +#define regDC_GPU_TIMER_START_POSITION_V_UPDATE_BASE_IDX 2 +#define regDC_GPU_TIMER_START_POSITION_VSTARTUP 0x0127 +#define regDC_GPU_TIMER_START_POSITION_VSTARTUP_BASE_IDX 2 +#define regDC_GPU_TIMER_READ 0x0128 +#define regDC_GPU_TIMER_READ_BASE_IDX 2 +#define regDC_GPU_TIMER_READ_CNTL 0x0129 +#define regDC_GPU_TIMER_READ_CNTL_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS 0x012a +#define regDISP_INTERRUPT_STATUS_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE 0x012b +#define regDISP_INTERRUPT_STATUS_CONTINUE_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE2 0x012c +#define regDISP_INTERRUPT_STATUS_CONTINUE2_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE3 0x012d +#define regDISP_INTERRUPT_STATUS_CONTINUE3_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE4 0x012e +#define regDISP_INTERRUPT_STATUS_CONTINUE4_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE5 0x012f +#define regDISP_INTERRUPT_STATUS_CONTINUE5_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE6 0x0130 +#define regDISP_INTERRUPT_STATUS_CONTINUE6_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE7 0x0131 +#define regDISP_INTERRUPT_STATUS_CONTINUE7_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE8 0x0132 +#define regDISP_INTERRUPT_STATUS_CONTINUE8_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE9 0x0133 +#define regDISP_INTERRUPT_STATUS_CONTINUE9_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE10 0x0134 +#define regDISP_INTERRUPT_STATUS_CONTINUE10_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE11 0x0135 +#define regDISP_INTERRUPT_STATUS_CONTINUE11_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE12 0x0136 +#define regDISP_INTERRUPT_STATUS_CONTINUE12_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE13 0x0137 +#define regDISP_INTERRUPT_STATUS_CONTINUE13_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE14 0x0138 +#define regDISP_INTERRUPT_STATUS_CONTINUE14_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE15 0x0139 +#define regDISP_INTERRUPT_STATUS_CONTINUE15_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE16 0x013a +#define regDISP_INTERRUPT_STATUS_CONTINUE16_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE17 0x013b +#define regDISP_INTERRUPT_STATUS_CONTINUE17_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE18 0x013c +#define regDISP_INTERRUPT_STATUS_CONTINUE18_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE19 0x013d +#define regDISP_INTERRUPT_STATUS_CONTINUE19_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE20 0x013e +#define regDISP_INTERRUPT_STATUS_CONTINUE20_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE21 0x013f +#define regDISP_INTERRUPT_STATUS_CONTINUE21_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE22 0x0140 +#define regDISP_INTERRUPT_STATUS_CONTINUE22_BASE_IDX 2 +#define regDC_GPU_TIMER_START_POSITION_VREADY 0x0141 +#define regDC_GPU_TIMER_START_POSITION_VREADY_BASE_IDX 2 +#define regDC_GPU_TIMER_START_POSITION_FLIP 0x0142 +#define regDC_GPU_TIMER_START_POSITION_FLIP_BASE_IDX 2 +#define regDC_GPU_TIMER_START_POSITION_V_UPDATE_NO_LOCK 0x0143 +#define regDC_GPU_TIMER_START_POSITION_V_UPDATE_NO_LOCK_BASE_IDX 2 +#define regDC_GPU_TIMER_START_POSITION_FLIP_AWAY 0x0144 +#define regDC_GPU_TIMER_START_POSITION_FLIP_AWAY_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE23 0x0145 +#define regDISP_INTERRUPT_STATUS_CONTINUE23_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE24 0x0146 +#define regDISP_INTERRUPT_STATUS_CONTINUE24_BASE_IDX 2 +#define regDISP_INTERRUPT_STATUS_CONTINUE25 0x0147 +#define regDISP_INTERRUPT_STATUS_CONTINUE25_BASE_IDX 2 +#define regDCCG_INTERRUPT_DEST 0x0148 +#define regDCCG_INTERRUPT_DEST_BASE_IDX 2 +#define regDMU_INTERRUPT_DEST 0x0149 +#define regDMU_INTERRUPT_DEST_BASE_IDX 2 +#define regDMU_INTERRUPT_DEST2 0x014a +#define regDMU_INTERRUPT_DEST2_BASE_IDX 2 +#define regDCPG_INTERRUPT_DEST 0x014b +#define regDCPG_INTERRUPT_DEST_BASE_IDX 2 +#define regDCPG_INTERRUPT_DEST2 0x014c +#define regDCPG_INTERRUPT_DEST2_BASE_IDX 2 +#define regMMHUBBUB_INTERRUPT_DEST 0x014d +#define regMMHUBBUB_INTERRUPT_DEST_BASE_IDX 2 +#define regWB_INTERRUPT_DEST 0x014e +#define regWB_INTERRUPT_DEST_BASE_IDX 2 +#define regDCHUB_INTERRUPT_DEST 0x014f +#define regDCHUB_INTERRUPT_DEST_BASE_IDX 2 +#define regDCHUB_PERFCOUNTER_INTERRUPT_DEST 0x0150 +#define regDCHUB_PERFCOUNTER_INTERRUPT_DEST_BASE_IDX 2 +#define regDCHUB_INTERRUPT_DEST2 0x0151 +#define regDCHUB_INTERRUPT_DEST2_BASE_IDX 2 +#define regDPP_PERFCOUNTER_INTERRUPT_DEST 0x0152 +#define regDPP_PERFCOUNTER_INTERRUPT_DEST_BASE_IDX 2 +#define regMPC_INTERRUPT_DEST 0x0153 +#define regMPC_INTERRUPT_DEST_BASE_IDX 2 +#define regOPP_INTERRUPT_DEST 0x0154 +#define regOPP_INTERRUPT_DEST_BASE_IDX 2 +#define regOPTC_INTERRUPT_DEST 0x0155 +#define regOPTC_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG0_INTERRUPT_DEST 0x0156 +#define regOTG0_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG1_INTERRUPT_DEST 0x0157 +#define regOTG1_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG2_INTERRUPT_DEST 0x0158 +#define regOTG2_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG3_INTERRUPT_DEST 0x0159 +#define regOTG3_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG4_INTERRUPT_DEST 0x015a +#define regOTG4_INTERRUPT_DEST_BASE_IDX 2 +#define regOTG5_INTERRUPT_DEST 0x015b +#define regOTG5_INTERRUPT_DEST_BASE_IDX 2 +#define regDIG_INTERRUPT_DEST 0x015c +#define regDIG_INTERRUPT_DEST_BASE_IDX 2 +#define regI2C_DDC_HPD_INTERRUPT_DEST 0x015d +#define regI2C_DDC_HPD_INTERRUPT_DEST_BASE_IDX 2 +#define regHDCP_INTERRUPT_DEST 0x015e +#define regHDCP_INTERRUPT_DEST_BASE_IDX 2 +#define regDIO_INTERRUPT_DEST 0x015f +#define regDIO_INTERRUPT_DEST_BASE_IDX 2 +#define regDCIO_INTERRUPT_DEST 0x0160 +#define regDCIO_INTERRUPT_DEST_BASE_IDX 2 +#define regHPD_INTERRUPT_DEST 0x0161 +#define regHPD_INTERRUPT_DEST_BASE_IDX 2 +#define regAZ_INTERRUPT_DEST 0x0162 +#define regAZ_INTERRUPT_DEST_BASE_IDX 2 +#define regAUX_INTERRUPT_DEST 0x0163 +#define regAUX_INTERRUPT_DEST_BASE_IDX 2 +#define regDSC_INTERRUPT_DEST 0x0164 +#define regDSC_INTERRUPT_DEST_BASE_IDX 2 +#define regHPO_INTERRUPT_DEST 0x0165 +#define regHPO_INTERRUPT_DEST_BASE_IDX 2 +#define regDPP_INTERRUPT_DEST 0x0166 +#define regDPP_INTERRUPT_DEST_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_dmu_misc_dispdec +// base address: 0x0 +#define regCC_DC_PIPE_DIS 0x00ca +#define regCC_DC_PIPE_DIS_BASE_IDX 2 +#define regDMU_CLK_CNTL 0x00cb +#define regDMU_CLK_CNTL_BASE_IDX 2 +#define regDMCUB_SMU_INTERRUPT_CNTL 0x00cd +#define regDMCUB_SMU_INTERRUPT_CNTL_BASE_IDX 2 +#define regSMU_INTERRUPT_CONTROL 0x00ce +#define regSMU_INTERRUPT_CONTROL_BASE_IDX 2 +#define regDMU_MISC_ALLOW_DS_FORCE 0x00d6 +#define regDMU_MISC_ALLOW_DS_FORCE_BASE_IDX 2 +#define regDMU_DISPCLK_CGTT_BLK_CTRL_REG 0x00d8 +#define regDMU_DISPCLK_CGTT_BLK_CTRL_REG_BASE_IDX 2 +#define regDMU_SOCCLK_CGTT_BLK_CTRL_REG 0x00d9 +#define regDMU_SOCCLK_CGTT_BLK_CTRL_REG_BASE_IDX 2 +#define regDMU_MEM_PWR_REQ_CNTL 0x00db +#define regDMU_MEM_PWR_REQ_CNTL_BASE_IDX 2 + + +// addressBlock: dce_dc_dmu_dmcub_dispdec +// base address: 0x0 +#define regDMCUB_REGION0_OFFSET 0x018e +#define regDMCUB_REGION0_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION0_OFFSET_HIGH 0x018f +#define regDMCUB_REGION0_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION1_OFFSET 0x0190 +#define regDMCUB_REGION1_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION1_OFFSET_HIGH 0x0191 +#define regDMCUB_REGION1_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION2_OFFSET 0x0192 +#define regDMCUB_REGION2_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION2_OFFSET_HIGH 0x0193 +#define regDMCUB_REGION2_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION2_ITCM_OFFSET 0x0194 +#define regDMCUB_REGION2_ITCM_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION2_ITCM_OFFSET_HIGH 0x0195 +#define regDMCUB_REGION2_ITCM_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION4_OFFSET 0x0196 +#define regDMCUB_REGION4_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION4_OFFSET_HIGH 0x0197 +#define regDMCUB_REGION4_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION5_OFFSET 0x0198 +#define regDMCUB_REGION5_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION5_OFFSET_HIGH 0x0199 +#define regDMCUB_REGION5_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION6_OFFSET 0x019a +#define regDMCUB_REGION6_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION6_OFFSET_HIGH 0x019b +#define regDMCUB_REGION6_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION7_OFFSET 0x019c +#define regDMCUB_REGION7_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION7_OFFSET_HIGH 0x019d +#define regDMCUB_REGION7_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION0_TOP_ADDRESS 0x019e +#define regDMCUB_REGION0_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION1_TOP_ADDRESS 0x019f +#define regDMCUB_REGION1_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION2_TOP_ADDRESS 0x01a0 +#define regDMCUB_REGION2_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION4_TOP_ADDRESS 0x01a1 +#define regDMCUB_REGION4_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION5_TOP_ADDRESS 0x01a2 +#define regDMCUB_REGION5_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION6_TOP_ADDRESS 0x01a3 +#define regDMCUB_REGION6_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION7_TOP_ADDRESS 0x01a4 +#define regDMCUB_REGION7_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW0_BASE_ADDRESS 0x01a5 +#define regDMCUB_REGION3_CW0_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW1_BASE_ADDRESS 0x01a6 +#define regDMCUB_REGION3_CW1_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW2_BASE_ADDRESS 0x01a7 +#define regDMCUB_REGION3_CW2_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW3_BASE_ADDRESS 0x01a8 +#define regDMCUB_REGION3_CW3_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW4_BASE_ADDRESS 0x01a9 +#define regDMCUB_REGION3_CW4_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW5_BASE_ADDRESS 0x01aa +#define regDMCUB_REGION3_CW5_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW6_BASE_ADDRESS 0x01ab +#define regDMCUB_REGION3_CW6_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW7_BASE_ADDRESS 0x01ac +#define regDMCUB_REGION3_CW7_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW0_TOP_ADDRESS 0x01ad +#define regDMCUB_REGION3_CW0_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW1_TOP_ADDRESS 0x01ae +#define regDMCUB_REGION3_CW1_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW2_TOP_ADDRESS 0x01af +#define regDMCUB_REGION3_CW2_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW3_TOP_ADDRESS 0x01b0 +#define regDMCUB_REGION3_CW3_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW4_TOP_ADDRESS 0x01b1 +#define regDMCUB_REGION3_CW4_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW5_TOP_ADDRESS 0x01b2 +#define regDMCUB_REGION3_CW5_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW6_TOP_ADDRESS 0x01b3 +#define regDMCUB_REGION3_CW6_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW7_TOP_ADDRESS 0x01b4 +#define regDMCUB_REGION3_CW7_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_CW0_OFFSET 0x01b5 +#define regDMCUB_REGION3_CW0_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW0_OFFSET_HIGH 0x01b6 +#define regDMCUB_REGION3_CW0_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW1_OFFSET 0x01b7 +#define regDMCUB_REGION3_CW1_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW1_OFFSET_HIGH 0x01b8 +#define regDMCUB_REGION3_CW1_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW2_OFFSET 0x01b9 +#define regDMCUB_REGION3_CW2_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW2_OFFSET_HIGH 0x01ba +#define regDMCUB_REGION3_CW2_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW3_OFFSET 0x01bb +#define regDMCUB_REGION3_CW3_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW3_OFFSET_HIGH 0x01bc +#define regDMCUB_REGION3_CW3_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW4_OFFSET 0x01bd +#define regDMCUB_REGION3_CW4_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW4_OFFSET_HIGH 0x01be +#define regDMCUB_REGION3_CW4_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW5_OFFSET 0x01bf +#define regDMCUB_REGION3_CW5_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW5_OFFSET_HIGH 0x01c0 +#define regDMCUB_REGION3_CW5_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW6_OFFSET 0x01c1 +#define regDMCUB_REGION3_CW6_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW6_OFFSET_HIGH 0x01c2 +#define regDMCUB_REGION3_CW6_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_REGION3_CW7_OFFSET 0x01c3 +#define regDMCUB_REGION3_CW7_OFFSET_BASE_IDX 2 +#define regDMCUB_REGION3_CW7_OFFSET_HIGH 0x01c4 +#define regDMCUB_REGION3_CW7_OFFSET_HIGH_BASE_IDX 2 +#define regDMCUB_INTERRUPT_ENABLE 0x01c5 +#define regDMCUB_INTERRUPT_ENABLE_BASE_IDX 2 +#define regDMCUB_INTERRUPT_ACK 0x01c6 +#define regDMCUB_INTERRUPT_ACK_BASE_IDX 2 +#define regDMCUB_INTERRUPT_STATUS 0x01c7 +#define regDMCUB_INTERRUPT_STATUS_BASE_IDX 2 +#define regDMCUB_INTERRUPT_TYPE 0x01c8 +#define regDMCUB_INTERRUPT_TYPE_BASE_IDX 2 +#define regDMCUB_EXT_INTERRUPT_STATUS 0x01c9 +#define regDMCUB_EXT_INTERRUPT_STATUS_BASE_IDX 2 +#define regDMCUB_EXT_INTERRUPT_CTXID 0x01ca +#define regDMCUB_EXT_INTERRUPT_CTXID_BASE_IDX 2 +#define regDMCUB_EXT_INTERRUPT_ACK 0x01cb +#define regDMCUB_EXT_INTERRUPT_ACK_BASE_IDX 2 +#define regDMCUB_INST_FETCH_FAULT_ADDR 0x01cc +#define regDMCUB_INST_FETCH_FAULT_ADDR_BASE_IDX 2 +#define regDMCUB_DATA_WRITE_FAULT_ADDR 0x01cd +#define regDMCUB_DATA_WRITE_FAULT_ADDR_BASE_IDX 2 +#define regDMCUB_SEC_CNTL 0x01ce +#define regDMCUB_SEC_CNTL_BASE_IDX 2 +#define regDMCUB_MEM_CNTL 0x01cf +#define regDMCUB_MEM_CNTL_BASE_IDX 2 +#define regDMCUB_INBOX0_BASE_ADDRESS 0x01d0 +#define regDMCUB_INBOX0_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_INBOX0_SIZE 0x01d1 +#define regDMCUB_INBOX0_SIZE_BASE_IDX 2 +#define regDMCUB_INBOX0_WPTR 0x01d2 +#define regDMCUB_INBOX0_WPTR_BASE_IDX 2 +#define regDMCUB_INBOX0_RPTR 0x01d3 +#define regDMCUB_INBOX0_RPTR_BASE_IDX 2 +#define regDMCUB_INBOX1_BASE_ADDRESS 0x01d4 +#define regDMCUB_INBOX1_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_INBOX1_SIZE 0x01d5 +#define regDMCUB_INBOX1_SIZE_BASE_IDX 2 +#define regDMCUB_INBOX1_WPTR 0x01d6 +#define regDMCUB_INBOX1_WPTR_BASE_IDX 2 +#define regDMCUB_INBOX1_RPTR 0x01d7 +#define regDMCUB_INBOX1_RPTR_BASE_IDX 2 +#define regDMCUB_OUTBOX0_BASE_ADDRESS 0x01d8 +#define regDMCUB_OUTBOX0_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_OUTBOX0_SIZE 0x01d9 +#define regDMCUB_OUTBOX0_SIZE_BASE_IDX 2 +#define regDMCUB_OUTBOX0_WPTR 0x01da +#define regDMCUB_OUTBOX0_WPTR_BASE_IDX 2 +#define regDMCUB_OUTBOX0_RPTR 0x01db +#define regDMCUB_OUTBOX0_RPTR_BASE_IDX 2 +#define regDMCUB_OUTBOX1_BASE_ADDRESS 0x01dc +#define regDMCUB_OUTBOX1_BASE_ADDRESS_BASE_IDX 2 +#define regDMCUB_OUTBOX1_SIZE 0x01dd +#define regDMCUB_OUTBOX1_SIZE_BASE_IDX 2 +#define regDMCUB_OUTBOX1_WPTR 0x01de +#define regDMCUB_OUTBOX1_WPTR_BASE_IDX 2 +#define regDMCUB_OUTBOX1_RPTR 0x01df +#define regDMCUB_OUTBOX1_RPTR_BASE_IDX 2 +#define regDMCUB_TIMER_TRIGGER0 0x01e0 +#define regDMCUB_TIMER_TRIGGER0_BASE_IDX 2 +#define regDMCUB_TIMER_TRIGGER1 0x01e1 +#define regDMCUB_TIMER_TRIGGER1_BASE_IDX 2 +#define regDMCUB_TIMER_WINDOW 0x01e2 +#define regDMCUB_TIMER_WINDOW_BASE_IDX 2 +#define regDMCUB_SCRATCH0 0x01e3 +#define regDMCUB_SCRATCH0_BASE_IDX 2 +#define regDMCUB_SCRATCH1 0x01e4 +#define regDMCUB_SCRATCH1_BASE_IDX 2 +#define regDMCUB_SCRATCH2 0x01e5 +#define regDMCUB_SCRATCH2_BASE_IDX 2 +#define regDMCUB_SCRATCH3 0x01e6 +#define regDMCUB_SCRATCH3_BASE_IDX 2 +#define regDMCUB_SCRATCH4 0x01e7 +#define regDMCUB_SCRATCH4_BASE_IDX 2 +#define regDMCUB_SCRATCH5 0x01e8 +#define regDMCUB_SCRATCH5_BASE_IDX 2 +#define regDMCUB_SCRATCH6 0x01e9 +#define regDMCUB_SCRATCH6_BASE_IDX 2 +#define regDMCUB_SCRATCH7 0x01ea +#define regDMCUB_SCRATCH7_BASE_IDX 2 +#define regDMCUB_SCRATCH8 0x01eb +#define regDMCUB_SCRATCH8_BASE_IDX 2 +#define regDMCUB_SCRATCH9 0x01ec +#define regDMCUB_SCRATCH9_BASE_IDX 2 +#define regDMCUB_SCRATCH10 0x01ed +#define regDMCUB_SCRATCH10_BASE_IDX 2 +#define regDMCUB_SCRATCH11 0x01ee +#define regDMCUB_SCRATCH11_BASE_IDX 2 +#define regDMCUB_SCRATCH12 0x01ef +#define regDMCUB_SCRATCH12_BASE_IDX 2 +#define regDMCUB_SCRATCH13 0x01f0 +#define regDMCUB_SCRATCH13_BASE_IDX 2 +#define regDMCUB_SCRATCH14 0x01f1 +#define regDMCUB_SCRATCH14_BASE_IDX 2 +#define regDMCUB_SCRATCH15 0x01f2 +#define regDMCUB_SCRATCH15_BASE_IDX 2 +#define regDMCUB_SCRATCH16 0x01f3 +#define regDMCUB_SCRATCH16_BASE_IDX 2 +#define regDMCUB_SCRATCH17 0x01f4 +#define regDMCUB_SCRATCH17_BASE_IDX 2 +#define regDMCUB_SCRATCH18 0x01f5 +#define regDMCUB_SCRATCH18_BASE_IDX 2 +#define regDMCUB_CNTL 0x01f6 +#define regDMCUB_CNTL_BASE_IDX 2 +#define regDMCUB_GPINT_DATAIN0 0x01f7 +#define regDMCUB_GPINT_DATAIN0_BASE_IDX 2 +#define regDMCUB_GPINT_DATAIN1 0x01f8 +#define regDMCUB_GPINT_DATAIN1_BASE_IDX 2 +#define regDMCUB_GPINT_DATAOUT 0x01f9 +#define regDMCUB_GPINT_DATAOUT_BASE_IDX 2 +#define regDMCUB_UNDEFINED_ADDRESS_FAULT_ADDR 0x01fa +#define regDMCUB_UNDEFINED_ADDRESS_FAULT_ADDR_BASE_IDX 2 +#define regDMCUB_LS_WAKE_INT_ENABLE 0x01fb +#define regDMCUB_LS_WAKE_INT_ENABLE_BASE_IDX 2 +#define regDMCUB_MEM_PWR_CNTL 0x01fc +#define regDMCUB_MEM_PWR_CNTL_BASE_IDX 2 +#define regDMCUB_TIMER_CURRENT 0x01fd +#define regDMCUB_TIMER_CURRENT_BASE_IDX 2 +#define regDMCUB_DBG_BUS_SELECT 0x01fe +#define regDMCUB_DBG_BUS_SELECT_BASE_IDX 2 +#define regDMCUB_PROC_ID 0x01ff +#define regDMCUB_PROC_ID_BASE_IDX 2 +#define regDMCUB_CNTL2 0x0200 +#define regDMCUB_CNTL2_BASE_IDX 2 +#define regDMCUB_RSMU_WHITELIST_STATUS 0x0201 +#define regDMCUB_RSMU_WHITELIST_STATUS_BASE_IDX 2 +#define regDMCUB_RSMU_REG_STATUS 0x0202 +#define regDMCUB_RSMU_REG_STATUS_BASE_IDX 2 +#define regDMCUB_RSMU_REG_APER_ID 0x0203 +#define regDMCUB_RSMU_REG_APER_ID_BASE_IDX 2 +#define regDMCUB_RSMU_MASTER_A_REG_SEC_FLAG 0x0204 +#define regDMCUB_RSMU_MASTER_A_REG_SEC_FLAG_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST0_BASE 0x0205 +#define regRSMU_MASTER_A_WHITELIST0_BASE_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST0_TOP 0x0206 +#define regRSMU_MASTER_A_WHITELIST0_TOP_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST1_BASE 0x0207 +#define regRSMU_MASTER_A_WHITELIST1_BASE_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST1_TOP 0x0208 +#define regRSMU_MASTER_A_WHITELIST1_TOP_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST2_BASE 0x0209 +#define regRSMU_MASTER_A_WHITELIST2_BASE_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST2_TOP 0x020a +#define regRSMU_MASTER_A_WHITELIST2_TOP_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST3_BASE 0x020b +#define regRSMU_MASTER_A_WHITELIST3_BASE_BASE_IDX 2 +#define regRSMU_MASTER_A_WHITELIST3_TOP 0x020c +#define regRSMU_MASTER_A_WHITELIST3_TOP_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST0_BASE 0x020d +#define regRSMU_MASTER_B_WHITELIST0_BASE_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST0_TOP 0x020e +#define regRSMU_MASTER_B_WHITELIST0_TOP_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST1_BASE 0x020f +#define regRSMU_MASTER_B_WHITELIST1_BASE_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST1_TOP 0x0210 +#define regRSMU_MASTER_B_WHITELIST1_TOP_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST2_BASE 0x0211 +#define regRSMU_MASTER_B_WHITELIST2_BASE_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST2_TOP 0x0212 +#define regRSMU_MASTER_B_WHITELIST2_TOP_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST3_BASE 0x0213 +#define regRSMU_MASTER_B_WHITELIST3_BASE_BASE_IDX 2 +#define regRSMU_MASTER_B_WHITELIST3_TOP 0x0214 +#define regRSMU_MASTER_B_WHITELIST3_TOP_BASE_IDX 2 +#define regDMCUB_GPINT_DATAIN2 0x0215 +#define regDMCUB_GPINT_DATAIN2_BASE_IDX 2 +#define regDMCUB_GPINT_DATAIN3 0x0216 +#define regDMCUB_GPINT_DATAIN3_BASE_IDX 2 +#define regDMCUB_GPINT_DATAIN4 0x0217 +#define regDMCUB_GPINT_DATAIN4_BASE_IDX 2 +#define regDMCUB_REGION2_ITCM_SRC_TOP_ADDRESS 0x0218 +#define regDMCUB_REGION2_ITCM_SRC_TOP_ADDRESS_BASE_IDX 2 +#define regDMCUB_REGION3_TMR_AXI_SPACE 0x021a +#define regDMCUB_REGION3_TMR_AXI_SPACE_BASE_IDX 2 +#define regDMCUB_SCRATCH19 0x021b +#define regDMCUB_SCRATCH19_BASE_IDX 2 +#define regDMCUB_SCRATCH20 0x021c +#define regDMCUB_SCRATCH20_BASE_IDX 2 +#define regDMCUB_SCRATCH21 0x021d +#define regDMCUB_SCRATCH21_BASE_IDX 2 +#define regDMCUB_SCRATCH22 0x021e +#define regDMCUB_SCRATCH22_BASE_IDX 2 +#define regDMCUB_SCRATCH23 0x021f +#define regDMCUB_SCRATCH23_BASE_IDX 2 +#define regDMCUB_TEST_DEBUG_INDEX 0x0220 +#define regDMCUB_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDMCUB_TEST_DEBUG_DATA 0x0221 +#define regDMCUB_TEST_DEBUG_DATA_BASE_IDX 2 +#define regHOST_INTERRUPT_CSR 0x0222 +#define regHOST_INTERRUPT_CSR_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_RDY 0x0223 +#define regDMCUB_REG_INBOX0_RDY_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG0 0x0224 +#define regDMCUB_REG_INBOX0_MSG0_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG1 0x0225 +#define regDMCUB_REG_INBOX0_MSG1_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG2 0x0226 +#define regDMCUB_REG_INBOX0_MSG2_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG3 0x0227 +#define regDMCUB_REG_INBOX0_MSG3_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG4 0x0228 +#define regDMCUB_REG_INBOX0_MSG4_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG5 0x0229 +#define regDMCUB_REG_INBOX0_MSG5_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG6 0x022a +#define regDMCUB_REG_INBOX0_MSG6_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG7 0x022b +#define regDMCUB_REG_INBOX0_MSG7_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG8 0x022c +#define regDMCUB_REG_INBOX0_MSG8_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG9 0x022d +#define regDMCUB_REG_INBOX0_MSG9_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG10 0x022e +#define regDMCUB_REG_INBOX0_MSG10_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG11 0x022f +#define regDMCUB_REG_INBOX0_MSG11_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG12 0x0230 +#define regDMCUB_REG_INBOX0_MSG12_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG13 0x0231 +#define regDMCUB_REG_INBOX0_MSG13_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_MSG14 0x0232 +#define regDMCUB_REG_INBOX0_MSG14_BASE_IDX 2 +#define regDMCUB_REG_INBOX0_RSP 0x0233 +#define regDMCUB_REG_INBOX0_RSP_BASE_IDX 2 +#define regDMCUB_REG_OUTBOX0_RDY 0x0234 +#define regDMCUB_REG_OUTBOX0_RDY_BASE_IDX 2 +#define regDMCUB_REG_OUTBOX0_MSG0 0x0235 +#define regDMCUB_REG_OUTBOX0_MSG0_BASE_IDX 2 +#define regDMCUB_REG_OUTBOX0_RSP 0x0236 +#define regDMCUB_REG_OUTBOX0_RSP_BASE_IDX 2 +#define regDMCUB_REG_INBOX1_RDY 0x0237 +#define regDMCUB_REG_INBOX1_RDY_BASE_IDX 2 +#define regDMCUB_REG_INBOX1_MSG0 0x0238 +#define regDMCUB_REG_INBOX1_MSG0_BASE_IDX 2 +#define regDMCUB_REG_INBOX1_MSG1 0x0239 +#define regDMCUB_REG_INBOX1_MSG1_BASE_IDX 2 +#define regDMCUB_REG_INBOX1_RSP 0x023a +#define regDMCUB_REG_INBOX1_RSP_BASE_IDX 2 +#define regDMCUB_REG_INBOX1_INTERRUPT_CSR 0x023b +#define regDMCUB_REG_INBOX1_INTERRUPT_CSR_BASE_IDX 2 +#define regDMCUB_REG_INBOX2_RDY 0x023c +#define regDMCUB_REG_INBOX2_RDY_BASE_IDX 2 +#define regDMCUB_REG_INBOX2_MSG0 0x023d +#define regDMCUB_REG_INBOX2_MSG0_BASE_IDX 2 +#define regDMCUB_REG_INBOX2_MSG1 0x023e +#define regDMCUB_REG_INBOX2_MSG1_BASE_IDX 2 +#define regDMCUB_REG_INBOX2_RSP 0x023f +#define regDMCUB_REG_INBOX2_RSP_BASE_IDX 2 +#define regDMCUB_REG_INBOX3_RDY 0x0240 +#define regDMCUB_REG_INBOX3_RDY_BASE_IDX 2 +#define regDMCUB_REG_INBOX3_MSG0 0x0241 +#define regDMCUB_REG_INBOX3_MSG0_BASE_IDX 2 +#define regDMCUB_REG_INBOX3_MSG1 0x0242 +#define regDMCUB_REG_INBOX3_MSG1_BASE_IDX 2 +#define regDMCUB_REG_INBOX3_RSP 0x0243 +#define regDMCUB_REG_INBOX3_RSP_BASE_IDX 2 +#define regDMCUB_REG_INBOX4_RDY 0x0244 +#define regDMCUB_REG_INBOX4_RDY_BASE_IDX 2 +#define regDMCUB_REG_INBOX4_MSG0 0x0245 +#define regDMCUB_REG_INBOX4_MSG0_BASE_IDX 2 +#define regDMCUB_REG_INBOX4_MSG1 0x0246 +#define regDMCUB_REG_INBOX4_MSG1_BASE_IDX 2 +#define regDMCUB_REG_INBOX4_RSP 0x0247 +#define regDMCUB_REG_INBOX4_RSP_BASE_IDX 2 +#define regDMCUB_RSMU_MASTER_B_REG_SEC_FLAG 0x0248 +#define regDMCUB_RSMU_MASTER_B_REG_SEC_FLAG_BASE_IDX 2 +#define regDMCUB_IDLE_HYSTERESIS_CSR 0x0249 +#define regDMCUB_IDLE_HYSTERESIS_CSR_BASE_IDX 2 + + +// addressBlock: dce_dc_mmhubbub_mmhubbub_dcperfmon_dc_perfmon_dispdec +// base address: 0xd48 +#define regDC_PERFMON3_PERFCOUNTER_CNTL 0x0352 +#define regDC_PERFMON3_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON3_PERFCOUNTER_CNTL2 0x0353 +#define regDC_PERFMON3_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON3_PERFCOUNTER_STATE 0x0354 +#define regDC_PERFMON3_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_CNTL 0x0355 +#define regDC_PERFMON3_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_CNTL2 0x0356 +#define regDC_PERFMON3_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_CVALUE_INT_MISC 0x0357 +#define regDC_PERFMON3_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_CVALUE_LOW 0x0358 +#define regDC_PERFMON3_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_HI 0x0359 +#define regDC_PERFMON3_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_LOW 0x035a +#define regDC_PERFMON3_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_TEST_DEBUG_INDEX 0x035b +#define regDC_PERFMON3_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON3_PERFMON_TEST_DEBUG_DATA 0x035c +#define regDC_PERFMON3_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_mmhubbub_mmhubbub_dispdec +// base address: 0x0 +#define regMCIF_WB_NB_PSTATE_LATENCY_WATERMARK 0x0262 +#define regMCIF_WB_NB_PSTATE_LATENCY_WATERMARK_BASE_IDX 2 +#define regMCIF_WB_WATERMARK 0x0263 +#define regMCIF_WB_WATERMARK_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_CONFIG 0x0264 +#define regMMHUBBUB_WARMUP_CONFIG_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_CONTROL_STATUS 0x0265 +#define regMMHUBBUB_WARMUP_CONTROL_STATUS_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_BASE_ADDR_LOW 0x0266 +#define regMMHUBBUB_WARMUP_BASE_ADDR_LOW_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_BASE_ADDR_HIGH 0x0267 +#define regMMHUBBUB_WARMUP_BASE_ADDR_HIGH_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_ADDR_REGION 0x0268 +#define regMMHUBBUB_WARMUP_ADDR_REGION_BASE_IDX 2 +#define regMMHUBBUB_MIN_TTO 0x0269 +#define regMMHUBBUB_MIN_TTO_BASE_IDX 2 +#define regMMHUBBUB_CTRL 0x0333 +#define regMMHUBBUB_CTRL_BASE_IDX 2 +#define regWBIF_SMU_WM_CONTROL 0x0334 +#define regWBIF_SMU_WM_CONTROL_BASE_IDX 2 +#define regMMHUBBUB_MEM_PWR_STATUS 0x033e +#define regMMHUBBUB_MEM_PWR_STATUS_BASE_IDX 2 +#define regMMHUBBUB_MEM_PWR_CNTL 0x033f +#define regMMHUBBUB_MEM_PWR_CNTL_BASE_IDX 2 +#define regMMHUBBUB_CLOCK_CNTL 0x0340 +#define regMMHUBBUB_CLOCK_CNTL_BASE_IDX 2 +#define regMMHUBBUB_SOFT_RESET 0x0341 +#define regMMHUBBUB_SOFT_RESET_BASE_IDX 2 +#define regDMU_IF_ERR_STATUS 0x0345 +#define regDMU_IF_ERR_STATUS_BASE_IDX 2 +#define regMMHUBBUB_CLIENT_UNIT_ID 0x0346 +#define regMMHUBBUB_CLIENT_UNIT_ID_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_SECURITY_CFG 0x0347 +#define regMMHUBBUB_WARMUP_SECURITY_CFG_BASE_IDX 2 +#define regMMHUBBUB_WARMUP_VMID_CONTROL 0x0348 +#define regMMHUBBUB_WARMUP_VMID_CONTROL_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0controller_dispdec +// base address: 0x0 +#define regAZALIA_CONTROLLER_CLOCK_GATING 0x03c2 +#define regAZALIA_CONTROLLER_CLOCK_GATING_BASE_IDX 2 +#define regAZALIA_AUDIO_DTO 0x03c3 +#define regAZALIA_AUDIO_DTO_BASE_IDX 2 +#define regAZALIA_AUDIO_DTO_CONTROL 0x03c4 +#define regAZALIA_AUDIO_DTO_CONTROL_BASE_IDX 2 +#define regAZALIA_SOCCLK_CONTROL 0x03c5 +#define regAZALIA_SOCCLK_CONTROL_BASE_IDX 2 +#define regAZALIA_UNDERFLOW_FILLER_SAMPLE 0x03c6 +#define regAZALIA_UNDERFLOW_FILLER_SAMPLE_BASE_IDX 2 +#define regAZALIA_DATA_DMA_CONTROL 0x03c7 +#define regAZALIA_DATA_DMA_CONTROL_BASE_IDX 2 +#define regAZALIA_BDL_DMA_CONTROL 0x03c8 +#define regAZALIA_BDL_DMA_CONTROL_BASE_IDX 2 +#define regAZALIA_RIRB_AND_DP_CONTROL 0x03c9 +#define regAZALIA_RIRB_AND_DP_CONTROL_BASE_IDX 2 +#define regAZALIA_CORB_DMA_CONTROL 0x03ca +#define regAZALIA_CORB_DMA_CONTROL_BASE_IDX 2 +#define regAZALIA_GLOBAL_CAPABILITIES 0x03d3 +#define regAZALIA_GLOBAL_CAPABILITIES_BASE_IDX 2 +#define regAZALIA_OUTPUT_PAYLOAD_CAPABILITY 0x03d4 +#define regAZALIA_OUTPUT_PAYLOAD_CAPABILITY_BASE_IDX 2 +#define regAZALIA_OUTPUT_STREAM_ARBITER_CONTROL 0x03d5 +#define regAZALIA_OUTPUT_STREAM_ARBITER_CONTROL_BASE_IDX 2 +#define regAZALIA_INPUT_PAYLOAD_CAPABILITY 0x03d6 +#define regAZALIA_INPUT_PAYLOAD_CAPABILITY_BASE_IDX 2 +#define regAZALIA_CONTROLLER_DEBUG 0x03d7 +#define regAZALIA_CONTROLLER_DEBUG_BASE_IDX 2 +#define regAZALIA_MEM_PWR_CTRL 0x03ee +#define regAZALIA_MEM_PWR_CTRL_BASE_IDX 2 +#define regAZALIA_MEM_PWR_STATUS 0x03ef +#define regAZALIA_MEM_PWR_STATUS_BASE_IDX 2 +#define regDCI_PG_DEBUG_CONFIG 0x03f0 +#define regDCI_PG_DEBUG_CONFIG_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0root_dispdec +// base address: 0x0 +#define regAZALIA_F0_CODEC_ROOT_PARAMETER_VENDOR_AND_DEVICE_ID 0x0406 +#define regAZALIA_F0_CODEC_ROOT_PARAMETER_VENDOR_AND_DEVICE_ID_BASE_IDX 2 +#define regAZALIA_F0_CODEC_ROOT_PARAMETER_REVISION_ID 0x0407 +#define regAZALIA_F0_CODEC_ROOT_PARAMETER_REVISION_ID_BASE_IDX 2 +#define regAZALIA_F0_CODEC_CHANNEL_COUNT_CONTROL 0x0408 +#define regAZALIA_F0_CODEC_CHANNEL_COUNT_CONTROL_BASE_IDX 2 +#define regAZALIA_F0_CODEC_RESYNC_FIFO_CONTROL 0x0409 +#define regAZALIA_F0_CODEC_RESYNC_FIFO_CONTROL_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_GROUP_TYPE 0x040a +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_GROUP_TYPE_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_SUPPORTED_SIZE_RATES 0x040b +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_SUPPORTED_SIZE_RATES_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_STREAM_FORMATS 0x040c +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_STREAM_FORMATS_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_POWER_STATES 0x040d +#define regAZALIA_F0_CODEC_FUNCTION_PARAMETER_POWER_STATES_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_POWER_STATE 0x040e +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_POWER_STATE_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_RESET 0x040f +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_RESET_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_RESPONSE_SUBSYSTEM_ID 0x0410 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_RESPONSE_SUBSYSTEM_ID_BASE_IDX 2 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_CONVERTER_SYNCHRONIZATION 0x0411 +#define regAZALIA_F0_CODEC_FUNCTION_CONTROL_CONVERTER_SYNCHRONIZATION_BASE_IDX 2 +#define regCC_RCU_DC_AUDIO_PORT_CONNECTIVITY 0x0412 +#define regCC_RCU_DC_AUDIO_PORT_CONNECTIVITY_BASE_IDX 2 +#define regCC_RCU_DC_AUDIO_INPUT_PORT_CONNECTIVITY 0x0413 +#define regCC_RCU_DC_AUDIO_INPUT_PORT_CONNECTIVITY_BASE_IDX 2 +#define regAZALIA_F0_CODEC_DEBUG 0x0414 +#define regAZALIA_F0_CODEC_DEBUG_BASE_IDX 2 +#define regREG_DC_AUDIO_PORT_CONNECTIVITY 0x041c +#define regREG_DC_AUDIO_PORT_CONNECTIVITY_BASE_IDX 2 +#define regREG_DC_AUDIO_INPUT_PORT_CONNECTIVITY 0x041d +#define regREG_DC_AUDIO_INPUT_PORT_CONNECTIVITY_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_az_misc_dispdec +// base address: 0x0 +#define regAZ_CLOCK_CNTL 0x0372 +#define regAZ_CLOCK_CNTL_BASE_IDX 2 +#define regAZ_MEM_GLOBAL_PWR_REQ_CNTL 0x0373 +#define regAZ_MEM_GLOBAL_PWR_REQ_CNTL_BASE_IDX 2 +#define regAZ_STRAPS 0x0374 +#define regAZ_STRAPS_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_az_dcperfmon_dc_perfmon_dispdec +// base address: 0xde8 +#define regDC_PERFMON4_PERFCOUNTER_CNTL 0x037a +#define regDC_PERFMON4_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON4_PERFCOUNTER_CNTL2 0x037b +#define regDC_PERFMON4_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON4_PERFCOUNTER_STATE 0x037c +#define regDC_PERFMON4_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_CNTL 0x037d +#define regDC_PERFMON4_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_CNTL2 0x037e +#define regDC_PERFMON4_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_CVALUE_INT_MISC 0x037f +#define regDC_PERFMON4_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_CVALUE_LOW 0x0380 +#define regDC_PERFMON4_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_HI 0x0381 +#define regDC_PERFMON4_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_LOW 0x0382 +#define regDC_PERFMON4_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_TEST_DEBUG_INDEX 0x0383 +#define regDC_PERFMON4_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON4_PERFMON_TEST_DEBUG_DATA 0x0384 +#define regDC_PERFMON4_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream0_dispdec +// base address: 0x0 +#define regAZF0STREAM0_AZALIA_STREAM_INDEX 0x035e +#define regAZF0STREAM0_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM0_AZALIA_STREAM_DATA 0x035f +#define regAZF0STREAM0_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream1_dispdec +// base address: 0x8 +#define regAZF0STREAM1_AZALIA_STREAM_INDEX 0x0360 +#define regAZF0STREAM1_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM1_AZALIA_STREAM_DATA 0x0361 +#define regAZF0STREAM1_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream2_dispdec +// base address: 0x10 +#define regAZF0STREAM2_AZALIA_STREAM_INDEX 0x0362 +#define regAZF0STREAM2_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM2_AZALIA_STREAM_DATA 0x0363 +#define regAZF0STREAM2_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream3_dispdec +// base address: 0x18 +#define regAZF0STREAM3_AZALIA_STREAM_INDEX 0x0364 +#define regAZF0STREAM3_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM3_AZALIA_STREAM_DATA 0x0365 +#define regAZF0STREAM3_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream4_dispdec +// base address: 0x20 +#define regAZF0STREAM4_AZALIA_STREAM_INDEX 0x0366 +#define regAZF0STREAM4_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM4_AZALIA_STREAM_DATA 0x0367 +#define regAZF0STREAM4_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream5_dispdec +// base address: 0x28 +#define regAZF0STREAM5_AZALIA_STREAM_INDEX 0x0368 +#define regAZF0STREAM5_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM5_AZALIA_STREAM_DATA 0x0369 +#define regAZF0STREAM5_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream6_dispdec +// base address: 0x30 +#define regAZF0STREAM6_AZALIA_STREAM_INDEX 0x036a +#define regAZF0STREAM6_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM6_AZALIA_STREAM_DATA 0x036b +#define regAZF0STREAM6_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream7_dispdec +// base address: 0x38 +#define regAZF0STREAM7_AZALIA_STREAM_INDEX 0x036c +#define regAZF0STREAM7_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM7_AZALIA_STREAM_DATA 0x036d +#define regAZF0STREAM7_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream8_dispdec +// base address: 0x320 +#define regAZF0STREAM8_AZALIA_STREAM_INDEX 0x0426 +#define regAZF0STREAM8_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM8_AZALIA_STREAM_DATA 0x0427 +#define regAZF0STREAM8_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream9_dispdec +// base address: 0x328 +#define regAZF0STREAM9_AZALIA_STREAM_INDEX 0x0428 +#define regAZF0STREAM9_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM9_AZALIA_STREAM_DATA 0x0429 +#define regAZF0STREAM9_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream10_dispdec +// base address: 0x330 +#define regAZF0STREAM10_AZALIA_STREAM_INDEX 0x042a +#define regAZF0STREAM10_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM10_AZALIA_STREAM_DATA 0x042b +#define regAZF0STREAM10_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream11_dispdec +// base address: 0x338 +#define regAZF0STREAM11_AZALIA_STREAM_INDEX 0x042c +#define regAZF0STREAM11_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM11_AZALIA_STREAM_DATA 0x042d +#define regAZF0STREAM11_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream12_dispdec +// base address: 0x340 +#define regAZF0STREAM12_AZALIA_STREAM_INDEX 0x042e +#define regAZF0STREAM12_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM12_AZALIA_STREAM_DATA 0x042f +#define regAZF0STREAM12_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream13_dispdec +// base address: 0x348 +#define regAZF0STREAM13_AZALIA_STREAM_INDEX 0x0430 +#define regAZF0STREAM13_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM13_AZALIA_STREAM_DATA 0x0431 +#define regAZF0STREAM13_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream14_dispdec +// base address: 0x350 +#define regAZF0STREAM14_AZALIA_STREAM_INDEX 0x0432 +#define regAZF0STREAM14_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM14_AZALIA_STREAM_DATA 0x0433 +#define regAZF0STREAM14_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0stream15_dispdec +// base address: 0x358 +#define regAZF0STREAM15_AZALIA_STREAM_INDEX 0x0434 +#define regAZF0STREAM15_AZALIA_STREAM_INDEX_BASE_IDX 2 +#define regAZF0STREAM15_AZALIA_STREAM_DATA 0x0435 +#define regAZF0STREAM15_AZALIA_STREAM_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint0_dispdec +// base address: 0x0 +#define regAZF0ENDPOINT0_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x0386 +#define regAZF0ENDPOINT0_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT0_AZALIA_F0_CODEC_ENDPOINT_DATA 0x0387 +#define regAZF0ENDPOINT0_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint1_dispdec +// base address: 0x18 +#define regAZF0ENDPOINT1_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x038c +#define regAZF0ENDPOINT1_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT1_AZALIA_F0_CODEC_ENDPOINT_DATA 0x038d +#define regAZF0ENDPOINT1_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint2_dispdec +// base address: 0x30 +#define regAZF0ENDPOINT2_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x0392 +#define regAZF0ENDPOINT2_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT2_AZALIA_F0_CODEC_ENDPOINT_DATA 0x0393 +#define regAZF0ENDPOINT2_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint3_dispdec +// base address: 0x48 +#define regAZF0ENDPOINT3_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x0398 +#define regAZF0ENDPOINT3_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT3_AZALIA_F0_CODEC_ENDPOINT_DATA 0x0399 +#define regAZF0ENDPOINT3_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint4_dispdec +// base address: 0x60 +#define regAZF0ENDPOINT4_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x039e +#define regAZF0ENDPOINT4_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT4_AZALIA_F0_CODEC_ENDPOINT_DATA 0x039f +#define regAZF0ENDPOINT4_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint5_dispdec +// base address: 0x78 +#define regAZF0ENDPOINT5_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x03a4 +#define regAZF0ENDPOINT5_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT5_AZALIA_F0_CODEC_ENDPOINT_DATA 0x03a5 +#define regAZF0ENDPOINT5_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint6_dispdec +// base address: 0x90 +#define regAZF0ENDPOINT6_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x03aa +#define regAZF0ENDPOINT6_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT6_AZALIA_F0_CODEC_ENDPOINT_DATA 0x03ab +#define regAZF0ENDPOINT6_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_hda_azf0endpoint7_dispdec +// base address: 0xa8 +#define regAZF0ENDPOINT7_AZALIA_F0_CODEC_ENDPOINT_INDEX 0x03b0 +#define regAZF0ENDPOINT7_AZALIA_F0_CODEC_ENDPOINT_INDEX_BASE_IDX 2 +#define regAZF0ENDPOINT7_AZALIA_F0_CODEC_ENDPOINT_DATA 0x03b1 +#define regAZF0ENDPOINT7_AZALIA_F0_CODEC_ENDPOINT_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dchubbubl_hubbub_dispdec +// base address: 0x0 +#define regDCHUBBUB_ARB_DF_REQ_OUTSTAND 0x04f9 +#define regDCHUBBUB_ARB_DF_REQ_OUTSTAND_BASE_IDX 2 +#define regDCHUBBUB_ARB_SAT_LEVEL 0x04fa +#define regDCHUBBUB_ARB_SAT_LEVEL_BASE_IDX 2 +#define regDCHUBBUB_ARB_QOS_FORCE 0x04fb +#define regDCHUBBUB_ARB_QOS_FORCE_BASE_IDX 2 +#define regDCHUBBUB_ARB_DRAM_STATE_CNTL 0x04fc +#define regDCHUBBUB_ARB_DRAM_STATE_CNTL_BASE_IDX 2 +#define regDCHUBBUB_ARB_DRAM_HVM_STATE_CNTL 0x04fd +#define regDCHUBBUB_ARB_DRAM_HVM_STATE_CNTL_BASE_IDX 2 +#define regDCHUBBUB_ARB_DATA_URGENCY_WATERMARK_A 0x04fe +#define regDCHUBBUB_ARB_DATA_URGENCY_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_REFCYC_PER_TRIP_TO_MEMORY_A 0x04ff +#define regDCHUBBUB_ARB_REFCYC_PER_TRIP_TO_MEMORY_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_REFCYC_PER_META_TRIP_A 0x0500 +#define regDCHUBBUB_ARB_REFCYC_PER_META_TRIP_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK_A 0x0501 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK_A 0x0502 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK1_A 0x0503 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK1_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK1_A 0x0504 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK1_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK2_A 0x0505 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK2_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK2_A 0x0506 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK2_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK3_A 0x0507 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK3_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK3_A 0x0508 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK3_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK_A 0x0509 +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK1_A 0x050a +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK1_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK_A 0x050b +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK1_A 0x050c +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK1_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_BUFFER_FULLNESS_WATERMARK_A 0x050d +#define regDCHUBBUB_ARB_BUFFER_FULLNESS_WATERMARK_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_FRAC_URG_BW_NOM_A 0x050e +#define regDCHUBBUB_ARB_FRAC_URG_BW_NOM_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_FRAC_URG_BW_FLIP_A 0x050f +#define regDCHUBBUB_ARB_FRAC_URG_BW_FLIP_A_BASE_IDX 2 +#define regDCHUBBUB_ARB_DATA_URGENCY_WATERMARK_B 0x0510 +#define regDCHUBBUB_ARB_DATA_URGENCY_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_REFCYC_PER_TRIP_TO_MEMORY_B 0x0511 +#define regDCHUBBUB_ARB_REFCYC_PER_TRIP_TO_MEMORY_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_REFCYC_PER_META_TRIP_B 0x0512 +#define regDCHUBBUB_ARB_REFCYC_PER_META_TRIP_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK_B 0x0513 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK_B 0x0514 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK1_B 0x0515 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK1_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK1_B 0x0516 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK1_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK2_B 0x0517 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK2_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK2_B 0x0518 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK2_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK3_B 0x0519 +#define regDCHUBBUB_ARB_ALLOW_SR_ENTER_WATERMARK3_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK3_B 0x051a +#define regDCHUBBUB_ARB_ALLOW_SR_EXIT_WATERMARK3_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK_B 0x051b +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK1_B 0x051c +#define regDCHUBBUB_ARB_UCLK_PSTATE_CHANGE_WATERMARK1_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK_B 0x051d +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK1_B 0x051e +#define regDCHUBBUB_ARB_FCLK_PSTATE_CHANGE_WATERMARK1_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_BUFFER_FULLNESS_WATERMARK_B 0x051f +#define regDCHUBBUB_ARB_BUFFER_FULLNESS_WATERMARK_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_FRAC_URG_BW_NOM_B 0x0520 +#define regDCHUBBUB_ARB_FRAC_URG_BW_NOM_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_FRAC_URG_BW_FLIP_B 0x0521 +#define regDCHUBBUB_ARB_FRAC_URG_BW_FLIP_B_BASE_IDX 2 +#define regDCHUBBUB_ARB_HOSTVM_CNTL 0x0522 +#define regDCHUBBUB_ARB_HOSTVM_CNTL_BASE_IDX 2 +#define regDCHUBBUB_ARB_WATERMARK_CHANGE_CNTL 0x0523 +#define regDCHUBBUB_ARB_WATERMARK_CHANGE_CNTL_BASE_IDX 2 +#define regDCHUBBUB_ARB_ALT_CH_CNTL 0x0524 +#define regDCHUBBUB_ARB_ALT_CH_CNTL_BASE_IDX 2 +#define regDCHUBBUB_ARB_TIMEOUT_ENABLE 0x0525 +#define regDCHUBBUB_ARB_TIMEOUT_ENABLE_BASE_IDX 2 +#define regDCHUBBUB_GLOBAL_TIMER_CNTL 0x0526 +#define regDCHUBBUB_GLOBAL_TIMER_CNTL_BASE_IDX 2 +#define regSURFACE_CHECK0_ADDRESS_LSB 0x0527 +#define regSURFACE_CHECK0_ADDRESS_LSB_BASE_IDX 2 +#define regSURFACE_CHECK0_ADDRESS_MSB 0x0528 +#define regSURFACE_CHECK0_ADDRESS_MSB_BASE_IDX 2 +#define regSURFACE_CHECK1_ADDRESS_LSB 0x0529 +#define regSURFACE_CHECK1_ADDRESS_LSB_BASE_IDX 2 +#define regSURFACE_CHECK1_ADDRESS_MSB 0x052a +#define regSURFACE_CHECK1_ADDRESS_MSB_BASE_IDX 2 +#define regSURFACE_CHECK2_ADDRESS_LSB 0x052b +#define regSURFACE_CHECK2_ADDRESS_LSB_BASE_IDX 2 +#define regSURFACE_CHECK2_ADDRESS_MSB 0x052c +#define regSURFACE_CHECK2_ADDRESS_MSB_BASE_IDX 2 +#define regSURFACE_CHECK3_ADDRESS_LSB 0x052d +#define regSURFACE_CHECK3_ADDRESS_LSB_BASE_IDX 2 +#define regSURFACE_CHECK3_ADDRESS_MSB 0x052e +#define regSURFACE_CHECK3_ADDRESS_MSB_BASE_IDX 2 +#define regVTG0_CONTROL 0x052f +#define regVTG0_CONTROL_BASE_IDX 2 +#define regVTG1_CONTROL 0x0530 +#define regVTG1_CONTROL_BASE_IDX 2 +#define regVTG2_CONTROL 0x0531 +#define regVTG2_CONTROL_BASE_IDX 2 +#define regVTG3_CONTROL 0x0532 +#define regVTG3_CONTROL_BASE_IDX 2 +#define regDCHUBBUB_SOFT_RESET 0x0533 +#define regDCHUBBUB_SOFT_RESET_BASE_IDX 2 +#define regDCHUBBUB_CLOCK_CNTL 0x0534 +#define regDCHUBBUB_CLOCK_CNTL_BASE_IDX 2 +#define regDCFCLK_CNTL 0x0535 +#define regDCFCLK_CNTL_BASE_IDX 2 +#define regDCHUBBUB_PERFORMANCE_MEASUREMENT_CNTL 0x0536 +#define regDCHUBBUB_PERFORMANCE_MEASUREMENT_CNTL_BASE_IDX 2 +#define regDCHUBBUB_PERFORMANCE_MEASUREMENT_CNTL2 0x0537 +#define regDCHUBBUB_PERFORMANCE_MEASUREMENT_CNTL2_BASE_IDX 2 +#define regDCHUBBUB_VLINE_SNAPSHOT 0x0538 +#define regDCHUBBUB_VLINE_SNAPSHOT_BASE_IDX 2 +#define regDCHUBBUB_CTRL_STATUS 0x0539 +#define regDCHUBBUB_CTRL_STATUS_BASE_IDX 2 +#define regDCHUBBUB_TIMEOUT_DETECTION_CTRL1 0x053f +#define regDCHUBBUB_TIMEOUT_DETECTION_CTRL1_BASE_IDX 2 +#define regDCHUBBUB_TIMEOUT_DETECTION_CTRL2 0x0540 +#define regDCHUBBUB_TIMEOUT_DETECTION_CTRL2_BASE_IDX 2 +#define regDCHUBBUB_TIMEOUT_INTERRUPT_STATUS 0x0541 +#define regDCHUBBUB_TIMEOUT_INTERRUPT_STATUS_BASE_IDX 2 +#define regFMON_CTRL 0x0542 +#define regFMON_CTRL_BASE_IDX 2 +#define regDCHUBBUB_TEST_DEBUG_INDEX 0x0543 +#define regDCHUBBUB_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDCHUBBUB_TEST_DEBUG_DATA 0x0544 +#define regDCHUBBUB_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dchubbubl_hubbub_sdpif_dispdec +// base address: 0x0 +#define regDCHUBBUB_SDPIF_CFG0 0x046f +#define regDCHUBBUB_SDPIF_CFG0_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_CFG1 0x0470 +#define regDCHUBBUB_SDPIF_CFG1_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_CFG2 0x0471 +#define regDCHUBBUB_SDPIF_CFG2_BASE_IDX 2 +#define regVM_REQUEST_PHYSICAL 0x0472 +#define regVM_REQUEST_PHYSICAL_BASE_IDX 2 +#define regDCHUBBUB_FORCE_IO_STATUS_0 0x0473 +#define regDCHUBBUB_FORCE_IO_STATUS_0_BASE_IDX 2 +#define regDCHUBBUB_FORCE_IO_STATUS_1 0x0474 +#define regDCHUBBUB_FORCE_IO_STATUS_1_BASE_IDX 2 +#define regDCN_VM_FB_LOCATION_BASE 0x0475 +#define regDCN_VM_FB_LOCATION_BASE_BASE_IDX 2 +#define regDCN_VM_FB_LOCATION_TOP 0x0476 +#define regDCN_VM_FB_LOCATION_TOP_BASE_IDX 2 +#define regDCN_VM_FB_OFFSET 0x0477 +#define regDCN_VM_FB_OFFSET_BASE_IDX 2 +#define regDCN_VM_AGP_BOT 0x0478 +#define regDCN_VM_AGP_BOT_BASE_IDX 2 +#define regDCN_VM_AGP_TOP 0x0479 +#define regDCN_VM_AGP_TOP_BASE_IDX 2 +#define regDCN_VM_AGP_BASE 0x047a +#define regDCN_VM_AGP_BASE_BASE_IDX 2 +#define regDCN_VM_LOCAL_HBM_ADDRESS_START 0x047b +#define regDCN_VM_LOCAL_HBM_ADDRESS_START_BASE_IDX 2 +#define regDCN_VM_LOCAL_HBM_ADDRESS_END 0x047c +#define regDCN_VM_LOCAL_HBM_ADDRESS_END_BASE_IDX 2 +#define regDCN_VM_LOCAL_HBM_ADDRESS_LOCK_CNTL 0x047d +#define regDCN_VM_LOCAL_HBM_ADDRESS_LOCK_CNTL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_SEC_LVL 0x047e +#define regDCHUBBUB_SDPIF_PIPE_SEC_LVL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_NOALLOC 0x047f +#define regDCHUBBUB_SDPIF_PIPE_NOALLOC_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_DMDATA_SEC_LVL 0x0480 +#define regDCHUBBUB_SDPIF_PIPE_DMDATA_SEC_LVL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_CURSOR0_SEC_LVL 0x0481 +#define regDCHUBBUB_SDPIF_PIPE_CURSOR0_SEC_LVL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_3DLUT_SEC_LVL 0x0482 +#define regDCHUBBUB_SDPIF_PIPE_3DLUT_SEC_LVL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_GPUVM_SEC_LVL 0x0483 +#define regDCHUBBUB_SDPIF_PIPE_GPUVM_SEC_LVL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_PIPE_DATAFETCH 0x0484 +#define regDCHUBBUB_SDPIF_PIPE_DATAFETCH_BASE_IDX 2 +#define regSDPIF_REQUEST_RATE_LIMIT 0x0485 +#define regSDPIF_REQUEST_RATE_LIMIT_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_MEM_PWR_CTRL 0x0486 +#define regDCHUBBUB_SDPIF_MEM_PWR_CTRL_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_MEM_PWR_STATUS 0x0487 +#define regDCHUBBUB_SDPIF_MEM_PWR_STATUS_BASE_IDX 2 +#define regDCHUBBUB_SDPIF_MCACHE_INVALIDATION_CTL 0x0488 +#define regDCHUBBUB_SDPIF_MCACHE_INVALIDATION_CTL_BASE_IDX 2 +#define regUTM_CAPABILITIES_0 0x0489 +#define regUTM_CAPABILITIES_0_BASE_IDX 2 +#define regUTM_CONFIGURATION_0 0x048a +#define regUTM_CONFIGURATION_0_BASE_IDX 2 +#define regUTM_CLIENT_TO_SYSTEM_PROFILE_MAPPING_0 0x048b +#define regUTM_CLIENT_TO_SYSTEM_PROFILE_MAPPING_0_BASE_IDX 2 + + +// addressBlock: dce_dc_dchubbubl_hubbub_ret_path_dispdec +// base address: 0x0 +#define regDCHUBBUB_RET_PATH_MEM_PWR_CTRL 0x04af +#define regDCHUBBUB_RET_PATH_MEM_PWR_CTRL_BASE_IDX 2 +#define regDCHUBBUB_RET_PATH_MEM_PWR_STATUS 0x04b0 +#define regDCHUBBUB_RET_PATH_MEM_PWR_STATUS_BASE_IDX 2 +#define regDCHUBBUB_CRC_CTRL 0x04b1 +#define regDCHUBBUB_CRC_CTRL_BASE_IDX 2 +#define regDCHUBBUB_CRC0_VAL_R 0x04b2 +#define regDCHUBBUB_CRC0_VAL_R_BASE_IDX 2 +#define regDCHUBBUB_CRC0_VAL_G 0x04b3 +#define regDCHUBBUB_CRC0_VAL_G_BASE_IDX 2 +#define regDCHUBBUB_CRC0_VAL_B 0x04b4 +#define regDCHUBBUB_CRC0_VAL_B_BASE_IDX 2 +#define regDCHUBBUB_CRC0_VAL_A 0x04b5 +#define regDCHUBBUB_CRC0_VAL_A_BASE_IDX 2 +#define regDCHUBBUB_CRC1_VAL_R 0x04b6 +#define regDCHUBBUB_CRC1_VAL_R_BASE_IDX 2 +#define regDCHUBBUB_CRC1_VAL_G 0x04b7 +#define regDCHUBBUB_CRC1_VAL_G_BASE_IDX 2 +#define regDCHUBBUB_CRC1_VAL_B 0x04b8 +#define regDCHUBBUB_CRC1_VAL_B_BASE_IDX 2 +#define regDCHUBBUB_CRC1_VAL_A 0x04b9 +#define regDCHUBBUB_CRC1_VAL_A_BASE_IDX 2 +#define regDCHUBBUB_DCC_STAT_CNTL 0x04ba +#define regDCHUBBUB_DCC_STAT_CNTL_BASE_IDX 2 +#define regDCHUBBUB_DCC_STAT0 0x04bb +#define regDCHUBBUB_DCC_STAT0_BASE_IDX 2 +#define regDCHUBBUB_DCC_STAT1 0x04bc +#define regDCHUBBUB_DCC_STAT1_BASE_IDX 2 +#define regDCHUBBUB_DCC_STAT2 0x04bd +#define regDCHUBBUB_DCC_STAT2_BASE_IDX 2 +#define regDCHUBBUB_COMPBUF_CTRL 0x04be +#define regDCHUBBUB_COMPBUF_CTRL_BASE_IDX 2 +#define regDCHUBBUB_DET0_CTRL 0x04bf +#define regDCHUBBUB_DET0_CTRL_BASE_IDX 2 +#define regDCHUBBUB_DET1_CTRL 0x04c0 +#define regDCHUBBUB_DET1_CTRL_BASE_IDX 2 +#define regDCHUBBUB_DET2_CTRL 0x04c1 +#define regDCHUBBUB_DET2_CTRL_BASE_IDX 2 +#define regDCHUBBUB_DET3_CTRL 0x04c2 +#define regDCHUBBUB_DET3_CTRL_BASE_IDX 2 +#define regDCHUBBUB_MEM_PWR_MODE_CTRL 0x04c4 +#define regDCHUBBUB_MEM_PWR_MODE_CTRL_BASE_IDX 2 +#define regCOMPBUF_MEM_PWR_CTRL_1 0x04c5 +#define regCOMPBUF_MEM_PWR_CTRL_1_BASE_IDX 2 +#define regCOMPBUF_MEM_PWR_CTRL_2 0x04c6 +#define regCOMPBUF_MEM_PWR_CTRL_2_BASE_IDX 2 +#define regDCHUBBUB_MEM_PWR_STATUS 0x04c7 +#define regDCHUBBUB_MEM_PWR_STATUS_BASE_IDX 2 +#define regCOMPBUF_RESERVED_SPACE 0x04c8 +#define regCOMPBUF_RESERVED_SPACE_BASE_IDX 2 +#define regDCN_DECOMP_STATUS 0x04c9 +#define regDCN_DECOMP_STATUS_BASE_IDX 2 +#define regDCHUBBUB_DEBUG_CTRL_0 0x04ca +#define regDCHUBBUB_DEBUG_CTRL_0_BASE_IDX 2 +#define regDCHUBBUB_RET_PATH_REG_UPDATE_PENDING_TAKEN_STATUS 0x04cd +#define regDCHUBBUB_RET_PATH_REG_UPDATE_PENDING_TAKEN_STATUS_BASE_IDX 2 +#define regDCHUBBUB_RET_PATH_TEST_DEBUG_INDEX 0x04ce +#define regDCHUBBUB_RET_PATH_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDCHUBBUB_RET_PATH_TEST_DEBUG_DATA 0x04cf +#define regDCHUBBUB_RET_PATH_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dchubbubl_hubbub_vmrq_if_dispdec +// base address: 0x0 +#define regDCN_VM_CONTEXT0_CNTL 0x0559 +#define regDCN_VM_CONTEXT0_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR_HI32 0x055a +#define regDCN_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR_LO32 0x055b +#define regDCN_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_START_ADDR_HI32 0x055c +#define regDCN_VM_CONTEXT0_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_START_ADDR_LO32 0x055d +#define regDCN_VM_CONTEXT0_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_END_ADDR_HI32 0x055e +#define regDCN_VM_CONTEXT0_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT0_PAGE_TABLE_END_ADDR_LO32 0x055f +#define regDCN_VM_CONTEXT0_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_CNTL 0x0560 +#define regDCN_VM_CONTEXT1_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_BASE_ADDR_HI32 0x0561 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_BASE_ADDR_LO32 0x0562 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_START_ADDR_HI32 0x0563 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_START_ADDR_LO32 0x0564 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_END_ADDR_HI32 0x0565 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_END_ADDR_LO32 0x0566 +#define regDCN_VM_CONTEXT1_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_CNTL 0x0567 +#define regDCN_VM_CONTEXT2_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_BASE_ADDR_HI32 0x0568 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_BASE_ADDR_LO32 0x0569 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_START_ADDR_HI32 0x056a +#define regDCN_VM_CONTEXT2_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_START_ADDR_LO32 0x056b +#define regDCN_VM_CONTEXT2_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_END_ADDR_HI32 0x056c +#define regDCN_VM_CONTEXT2_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT2_PAGE_TABLE_END_ADDR_LO32 0x056d +#define regDCN_VM_CONTEXT2_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_CNTL 0x056e +#define regDCN_VM_CONTEXT3_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_BASE_ADDR_HI32 0x056f +#define regDCN_VM_CONTEXT3_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_BASE_ADDR_LO32 0x0570 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_START_ADDR_HI32 0x0571 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_START_ADDR_LO32 0x0572 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_END_ADDR_HI32 0x0573 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_END_ADDR_LO32 0x0574 +#define regDCN_VM_CONTEXT3_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_CNTL 0x0575 +#define regDCN_VM_CONTEXT4_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_BASE_ADDR_HI32 0x0576 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_BASE_ADDR_LO32 0x0577 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_START_ADDR_HI32 0x0578 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_START_ADDR_LO32 0x0579 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_END_ADDR_HI32 0x057a +#define regDCN_VM_CONTEXT4_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT4_PAGE_TABLE_END_ADDR_LO32 0x057b +#define regDCN_VM_CONTEXT4_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_CNTL 0x057c +#define regDCN_VM_CONTEXT5_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_BASE_ADDR_HI32 0x057d +#define regDCN_VM_CONTEXT5_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_BASE_ADDR_LO32 0x057e +#define regDCN_VM_CONTEXT5_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_START_ADDR_HI32 0x057f +#define regDCN_VM_CONTEXT5_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_START_ADDR_LO32 0x0580 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_END_ADDR_HI32 0x0581 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_END_ADDR_LO32 0x0582 +#define regDCN_VM_CONTEXT5_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_CNTL 0x0583 +#define regDCN_VM_CONTEXT6_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_BASE_ADDR_HI32 0x0584 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_BASE_ADDR_LO32 0x0585 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_START_ADDR_HI32 0x0586 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_START_ADDR_LO32 0x0587 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_END_ADDR_HI32 0x0588 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_END_ADDR_LO32 0x0589 +#define regDCN_VM_CONTEXT6_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_CNTL 0x058a +#define regDCN_VM_CONTEXT7_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_BASE_ADDR_HI32 0x058b +#define regDCN_VM_CONTEXT7_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_BASE_ADDR_LO32 0x058c +#define regDCN_VM_CONTEXT7_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_START_ADDR_HI32 0x058d +#define regDCN_VM_CONTEXT7_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_START_ADDR_LO32 0x058e +#define regDCN_VM_CONTEXT7_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_END_ADDR_HI32 0x058f +#define regDCN_VM_CONTEXT7_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_END_ADDR_LO32 0x0590 +#define regDCN_VM_CONTEXT7_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_CNTL 0x0591 +#define regDCN_VM_CONTEXT8_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR_HI32 0x0592 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR_LO32 0x0593 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_START_ADDR_HI32 0x0594 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_START_ADDR_LO32 0x0595 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_END_ADDR_HI32 0x0596 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_END_ADDR_LO32 0x0597 +#define regDCN_VM_CONTEXT8_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_CNTL 0x0598 +#define regDCN_VM_CONTEXT9_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_BASE_ADDR_HI32 0x0599 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_BASE_ADDR_LO32 0x059a +#define regDCN_VM_CONTEXT9_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_START_ADDR_HI32 0x059b +#define regDCN_VM_CONTEXT9_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_START_ADDR_LO32 0x059c +#define regDCN_VM_CONTEXT9_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_END_ADDR_HI32 0x059d +#define regDCN_VM_CONTEXT9_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT9_PAGE_TABLE_END_ADDR_LO32 0x059e +#define regDCN_VM_CONTEXT9_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_CNTL 0x059f +#define regDCN_VM_CONTEXT10_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_BASE_ADDR_HI32 0x05a0 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_BASE_ADDR_LO32 0x05a1 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_START_ADDR_HI32 0x05a2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_START_ADDR_LO32 0x05a3 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_END_ADDR_HI32 0x05a4 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_END_ADDR_LO32 0x05a5 +#define regDCN_VM_CONTEXT10_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_CNTL 0x05a6 +#define regDCN_VM_CONTEXT11_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_BASE_ADDR_HI32 0x05a7 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_BASE_ADDR_LO32 0x05a8 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_START_ADDR_HI32 0x05a9 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_START_ADDR_LO32 0x05aa +#define regDCN_VM_CONTEXT11_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_END_ADDR_HI32 0x05ab +#define regDCN_VM_CONTEXT11_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT11_PAGE_TABLE_END_ADDR_LO32 0x05ac +#define regDCN_VM_CONTEXT11_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_CNTL 0x05ad +#define regDCN_VM_CONTEXT12_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_BASE_ADDR_HI32 0x05ae +#define regDCN_VM_CONTEXT12_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_BASE_ADDR_LO32 0x05af +#define regDCN_VM_CONTEXT12_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_START_ADDR_HI32 0x05b0 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_START_ADDR_LO32 0x05b1 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_END_ADDR_HI32 0x05b2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_END_ADDR_LO32 0x05b3 +#define regDCN_VM_CONTEXT12_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_CNTL 0x05b4 +#define regDCN_VM_CONTEXT13_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_BASE_ADDR_HI32 0x05b5 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_BASE_ADDR_LO32 0x05b6 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_START_ADDR_HI32 0x05b7 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_START_ADDR_LO32 0x05b8 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_END_ADDR_HI32 0x05b9 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT13_PAGE_TABLE_END_ADDR_LO32 0x05ba +#define regDCN_VM_CONTEXT13_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_CNTL 0x05bb +#define regDCN_VM_CONTEXT14_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_BASE_ADDR_HI32 0x05bc +#define regDCN_VM_CONTEXT14_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_BASE_ADDR_LO32 0x05bd +#define regDCN_VM_CONTEXT14_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_START_ADDR_HI32 0x05be +#define regDCN_VM_CONTEXT14_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_START_ADDR_LO32 0x05bf +#define regDCN_VM_CONTEXT14_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_END_ADDR_HI32 0x05c0 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_END_ADDR_LO32 0x05c1 +#define regDCN_VM_CONTEXT14_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_CNTL 0x05c2 +#define regDCN_VM_CONTEXT15_CNTL_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_BASE_ADDR_HI32 0x05c3 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_BASE_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_BASE_ADDR_LO32 0x05c4 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_BASE_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_START_ADDR_HI32 0x05c5 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_START_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_START_ADDR_LO32 0x05c6 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_START_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_END_ADDR_HI32 0x05c7 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_END_ADDR_HI32_BASE_IDX 2 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_END_ADDR_LO32 0x05c8 +#define regDCN_VM_CONTEXT15_PAGE_TABLE_END_ADDR_LO32_BASE_IDX 2 +#define regDCN_VM_DEFAULT_ADDR_MSB 0x05c9 +#define regDCN_VM_DEFAULT_ADDR_MSB_BASE_IDX 2 +#define regDCN_VM_DEFAULT_ADDR_LSB 0x05ca +#define regDCN_VM_DEFAULT_ADDR_LSB_BASE_IDX 2 +#define regDCN_VM_FAULT_CNTL 0x05cb +#define regDCN_VM_FAULT_CNTL_BASE_IDX 2 +#define regDCN_VM_FAULT_STATUS 0x05cc +#define regDCN_VM_FAULT_STATUS_BASE_IDX 2 +#define regDCN_VM_FAULT_ADDR_MSB 0x05cd +#define regDCN_VM_FAULT_ADDR_MSB_BASE_IDX 2 +#define regDCN_VM_FAULT_ADDR_LSB 0x05ce +#define regDCN_VM_FAULT_ADDR_LSB_BASE_IDX 2 + + +// addressBlock: dce_dc_dchubbubl_dchubbub_dcperfmon_dc_perfmon_dispdec +// base address: 0x1534 +#define regDC_PERFMON5_PERFCOUNTER_CNTL 0x054d +#define regDC_PERFMON5_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON5_PERFCOUNTER_CNTL2 0x054e +#define regDC_PERFMON5_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON5_PERFCOUNTER_STATE 0x054f +#define regDC_PERFMON5_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_CNTL 0x0550 +#define regDC_PERFMON5_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_CNTL2 0x0551 +#define regDC_PERFMON5_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_CVALUE_INT_MISC 0x0552 +#define regDC_PERFMON5_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_CVALUE_LOW 0x0553 +#define regDC_PERFMON5_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_HI 0x0554 +#define regDC_PERFMON5_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_LOW 0x0555 +#define regDC_PERFMON5_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_TEST_DEBUG_INDEX 0x0556 +#define regDC_PERFMON5_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON5_PERFMON_TEST_DEBUG_DATA 0x0557 +#define regDC_PERFMON5_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp0_dispdec_hubp_dispdec +// base address: 0x0 +#define regHUBP0_DCSURF_SURFACE_CONFIG 0x05e5 +#define regHUBP0_DCSURF_SURFACE_CONFIG_BASE_IDX 2 +#define regHUBP0_DCSURF_ADDR_CONFIG 0x05e6 +#define regHUBP0_DCSURF_ADDR_CONFIG_BASE_IDX 2 +#define regHUBP0_DCSURF_TILING_CONFIG 0x05e7 +#define regHUBP0_DCSURF_TILING_CONFIG_BASE_IDX 2 +#define regHUBP0_DCSURF_LEGACY_ADDR_CONFIG 0x05e8 +#define regHUBP0_DCSURF_LEGACY_ADDR_CONFIG_BASE_IDX 2 +#define regHUBP0_DCSURF_PRI_VIEWPORT_START 0x05e9 +#define regHUBP0_DCSURF_PRI_VIEWPORT_START_BASE_IDX 2 +#define regHUBP0_DCSURF_VIEWPORT_MCACHE_SPLIT_COORDINATE 0x05ea +#define regHUBP0_DCSURF_VIEWPORT_MCACHE_SPLIT_COORDINATE_BASE_IDX 2 +#define regHUBP0_DCSURF_PRI_VIEWPORT_DIMENSION 0x05eb +#define regHUBP0_DCSURF_PRI_VIEWPORT_DIMENSION_BASE_IDX 2 +#define regHUBP0_DCSURF_PRI_VIEWPORT_START_C 0x05ec +#define regHUBP0_DCSURF_PRI_VIEWPORT_START_C_BASE_IDX 2 +#define regHUBP0_DCSURF_PRI_VIEWPORT_DIMENSION_C 0x05ed +#define regHUBP0_DCSURF_PRI_VIEWPORT_DIMENSION_C_BASE_IDX 2 +#define regHUBP0_DCSURF_SEC_VIEWPORT_START 0x05ee +#define regHUBP0_DCSURF_SEC_VIEWPORT_START_BASE_IDX 2 +#define regHUBP0_DCSURF_SEC_VIEWPORT_DIMENSION 0x05ef +#define regHUBP0_DCSURF_SEC_VIEWPORT_DIMENSION_BASE_IDX 2 +#define regHUBP0_DCSURF_SEC_VIEWPORT_START_C 0x05f0 +#define regHUBP0_DCSURF_SEC_VIEWPORT_START_C_BASE_IDX 2 +#define regHUBP0_DCSURF_SEC_VIEWPORT_DIMENSION_C 0x05f1 +#define regHUBP0_DCSURF_SEC_VIEWPORT_DIMENSION_C_BASE_IDX 2 +#define regHUBP0_DCHUBP_REQ_SIZE_CONFIG 0x05f2 +#define regHUBP0_DCHUBP_REQ_SIZE_CONFIG_BASE_IDX 2 +#define regHUBP0_DCHUBP_REQ_SIZE_CONFIG_C 0x05f3 +#define regHUBP0_DCHUBP_REQ_SIZE_CONFIG_C_BASE_IDX 2 +#define regHUBP0_DCHUBP_CNTL 0x05f4 +#define regHUBP0_DCHUBP_CNTL_BASE_IDX 2 +#define regHUBP0_HUBP_CLK_CNTL 0x05f5 +#define regHUBP0_HUBP_CLK_CNTL_BASE_IDX 2 +#define regHUBP0_DCHUBP_VMPG_CONFIG 0x05f6 +#define regHUBP0_DCHUBP_VMPG_CONFIG_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG0 0x05f7 +#define regHUBP0_DCHUBP_SUB_VP_CFG0_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG1 0x05f8 +#define regHUBP0_DCHUBP_SUB_VP_CFG1_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG2 0x05f9 +#define regHUBP0_DCHUBP_SUB_VP_CFG2_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG3 0x05fa +#define regHUBP0_DCHUBP_SUB_VP_CFG3_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG4 0x05fb +#define regHUBP0_DCHUBP_SUB_VP_CFG4_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG5 0x05fc +#define regHUBP0_DCHUBP_SUB_VP_CFG5_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG6 0x05fd +#define regHUBP0_DCHUBP_SUB_VP_CFG6_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG7 0x05fe +#define regHUBP0_DCHUBP_SUB_VP_CFG7_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG8 0x05ff +#define regHUBP0_DCHUBP_SUB_VP_CFG8_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG9 0x0600 +#define regHUBP0_DCHUBP_SUB_VP_CFG9_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG10 0x0601 +#define regHUBP0_DCHUBP_SUB_VP_CFG10_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG11 0x0602 +#define regHUBP0_DCHUBP_SUB_VP_CFG11_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG12 0x0603 +#define regHUBP0_DCHUBP_SUB_VP_CFG12_BASE_IDX 2 +#define regHUBP0_DCHUBP_SUB_VP_CFG13 0x0604 +#define regHUBP0_DCHUBP_SUB_VP_CFG13_BASE_IDX 2 +#define regHUBP0_DCHUBP_MCACHEID_CONFIG 0x0605 +#define regHUBP0_DCHUBP_MCACHEID_CONFIG_BASE_IDX 2 +#define regHUBP0_HUBPREQ_DEBUG_DB 0x0606 +#define regHUBP0_HUBPREQ_DEBUG_DB_BASE_IDX 2 +#define regHUBP0_HUBPREQ_DEBUG 0x0607 +#define regHUBP0_HUBPREQ_DEBUG_BASE_IDX 2 +#define regHUBP0_HUBP_MEASURE_WIN_CTRL_DCFCLK 0x060b +#define regHUBP0_HUBP_MEASURE_WIN_CTRL_DCFCLK_BASE_IDX 2 +#define regHUBP0_HUBP_MEASURE_WIN_CTRL_DPPCLK 0x060c +#define regHUBP0_HUBP_MEASURE_WIN_CTRL_DPPCLK_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp0_dispdec_hubpreq_dispdec +// base address: 0x0 +#define regHUBPREQ0_DCSURF_SURFACE_PITCH 0x0613 +#define regHUBPREQ0_DCSURF_SURFACE_PITCH_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_PITCH_C 0x0614 +#define regHUBPREQ0_DCSURF_SURFACE_PITCH_C_BASE_IDX 2 +#define regHUBPREQ0_VMID_SETTINGS_0 0x0615 +#define regHUBPREQ0_VMID_SETTINGS_0_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS 0x0616 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_HIGH 0x0617 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_HIGH_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_C 0x0618 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_HIGH_C 0x0619 +#define regHUBPREQ0_DCSURF_PRIMARY_SURFACE_ADDRESS_HIGH_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS 0x061a +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_HIGH 0x061b +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_HIGH_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_C 0x061c +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_HIGH_C 0x061d +#define regHUBPREQ0_DCSURF_SECONDARY_SURFACE_ADDRESS_HIGH_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_CONTROL 0x061e +#define regHUBPREQ0_DCSURF_SURFACE_CONTROL_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_FLIP_CONTROL 0x061f +#define regHUBPREQ0_DCSURF_FLIP_CONTROL_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_FLIP_CONTROL2 0x0620 +#define regHUBPREQ0_DCSURF_FLIP_CONTROL2_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_FLIP_INTERRUPT 0x0623 +#define regHUBPREQ0_DCSURF_SURFACE_FLIP_INTERRUPT_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE 0x0624 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_HIGH 0x0625 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_HIGH_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_C 0x0626 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_HIGH_C 0x0627 +#define regHUBPREQ0_DCSURF_SURFACE_INUSE_HIGH_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE 0x0628 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_HIGH 0x0629 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_HIGH_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_C 0x062a +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_C_BASE_IDX 2 +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_HIGH_C 0x062b +#define regHUBPREQ0_DCSURF_SURFACE_EARLIEST_INUSE_HIGH_C_BASE_IDX 2 +#define regHUBPREQ0_DCN_EXPANSION_MODE 0x062c +#define regHUBPREQ0_DCN_EXPANSION_MODE_BASE_IDX 2 +#define regHUBPREQ0_DCN_GLOBAL_TTU_CNTL 0x062d +#define regHUBPREQ0_DCN_GLOBAL_TTU_CNTL_BASE_IDX 2 +#define regHUBPREQ0_DCN_SURF0_TTU_CNTL0 0x062e +#define regHUBPREQ0_DCN_SURF0_TTU_CNTL0_BASE_IDX 2 +#define regHUBPREQ0_DCN_SURF0_TTU_CNTL1 0x062f +#define regHUBPREQ0_DCN_SURF0_TTU_CNTL1_BASE_IDX 2 +#define regHUBPREQ0_DCN_SURF1_TTU_CNTL0 0x0630 +#define regHUBPREQ0_DCN_SURF1_TTU_CNTL0_BASE_IDX 2 +#define regHUBPREQ0_DCN_SURF1_TTU_CNTL1 0x0631 +#define regHUBPREQ0_DCN_SURF1_TTU_CNTL1_BASE_IDX 2 +#define regHUBPREQ0_DCN_CUR0_TTU_CNTL0 0x0632 +#define regHUBPREQ0_DCN_CUR0_TTU_CNTL0_BASE_IDX 2 +#define regHUBPREQ0_DCN_CUR0_TTU_CNTL1 0x0633 +#define regHUBPREQ0_DCN_CUR0_TTU_CNTL1_BASE_IDX 2 +#define regHUBPREQ0_DCN_CUR1_TTU_CNTL0 0x0634 +#define regHUBPREQ0_DCN_CUR1_TTU_CNTL0_BASE_IDX 2 +#define regHUBPREQ0_DCN_CUR1_TTU_CNTL1 0x0635 +#define regHUBPREQ0_DCN_CUR1_TTU_CNTL1_BASE_IDX 2 +#define regHUBPREQ0_DCN_DMDATA_VM_CNTL 0x0636 +#define regHUBPREQ0_DCN_DMDATA_VM_CNTL_BASE_IDX 2 +#define regHUBPREQ0_DCN_VM_SYSTEM_APERTURE_LOW_ADDR 0x0637 +#define regHUBPREQ0_DCN_VM_SYSTEM_APERTURE_LOW_ADDR_BASE_IDX 2 +#define regHUBPREQ0_DCN_VM_SYSTEM_APERTURE_HIGH_ADDR 0x0638 +#define regHUBPREQ0_DCN_VM_SYSTEM_APERTURE_HIGH_ADDR_BASE_IDX 2 +#define regHUBPREQ0_DCN_VM_MX_L1_TLB_CNTL 0x0645 +#define regHUBPREQ0_DCN_VM_MX_L1_TLB_CNTL_BASE_IDX 2 +#define regHUBPREQ0_BLANK_OFFSET_0 0x0646 +#define regHUBPREQ0_BLANK_OFFSET_0_BASE_IDX 2 +#define regHUBPREQ0_BLANK_OFFSET_1 0x0647 +#define regHUBPREQ0_BLANK_OFFSET_1_BASE_IDX 2 +#define regHUBPREQ0_DST_DIMENSIONS 0x0648 +#define regHUBPREQ0_DST_DIMENSIONS_BASE_IDX 2 +#define regHUBPREQ0_DST_AFTER_SCALER 0x0649 +#define regHUBPREQ0_DST_AFTER_SCALER_BASE_IDX 2 +#define regHUBPREQ0_PREFETCH_SETTINGS 0x064a +#define regHUBPREQ0_PREFETCH_SETTINGS_BASE_IDX 2 +#define regHUBPREQ0_PREFETCH_SETTINGS_C 0x064b +#define regHUBPREQ0_PREFETCH_SETTINGS_C_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_0 0x064c +#define regHUBPREQ0_VBLANK_PARAMETERS_0_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_1 0x064d +#define regHUBPREQ0_VBLANK_PARAMETERS_1_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_2 0x064e +#define regHUBPREQ0_VBLANK_PARAMETERS_2_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_3 0x064f +#define regHUBPREQ0_VBLANK_PARAMETERS_3_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_4 0x0650 +#define regHUBPREQ0_VBLANK_PARAMETERS_4_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_0 0x0651 +#define regHUBPREQ0_FLIP_PARAMETERS_0_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_1 0x0652 +#define regHUBPREQ0_FLIP_PARAMETERS_1_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_2 0x0653 +#define regHUBPREQ0_FLIP_PARAMETERS_2_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_0 0x0654 +#define regHUBPREQ0_NOM_PARAMETERS_0_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_1 0x0655 +#define regHUBPREQ0_NOM_PARAMETERS_1_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_2 0x0656 +#define regHUBPREQ0_NOM_PARAMETERS_2_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_3 0x0657 +#define regHUBPREQ0_NOM_PARAMETERS_3_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_4 0x0658 +#define regHUBPREQ0_NOM_PARAMETERS_4_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_5 0x0659 +#define regHUBPREQ0_NOM_PARAMETERS_5_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_6 0x065a +#define regHUBPREQ0_NOM_PARAMETERS_6_BASE_IDX 2 +#define regHUBPREQ0_NOM_PARAMETERS_7 0x065b +#define regHUBPREQ0_NOM_PARAMETERS_7_BASE_IDX 2 +#define regHUBPREQ0_PER_LINE_DELIVERY_PRE 0x065c +#define regHUBPREQ0_PER_LINE_DELIVERY_PRE_BASE_IDX 2 +#define regHUBPREQ0_PER_LINE_DELIVERY 0x065d +#define regHUBPREQ0_PER_LINE_DELIVERY_BASE_IDX 2 +#define regHUBPREQ0_CURSOR_SETTINGS 0x065e +#define regHUBPREQ0_CURSOR_SETTINGS_BASE_IDX 2 +#define regHUBPREQ0_REF_FREQ_TO_PIX_FREQ 0x065f +#define regHUBPREQ0_REF_FREQ_TO_PIX_FREQ_BASE_IDX 2 +#define regHUBPREQ0_DST_Y_DELTA_DRQ_LIMIT 0x0660 +#define regHUBPREQ0_DST_Y_DELTA_DRQ_LIMIT_BASE_IDX 2 +#define regHUBPREQ0_DST_Y_ALT_CH_DRQ_LIMIT 0x0661 +#define regHUBPREQ0_DST_Y_ALT_CH_DRQ_LIMIT_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_MEM_PWR_CTRL 0x0662 +#define regHUBPREQ0_HUBPREQ_MEM_PWR_CTRL_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_MEM_PWR_STATUS 0x0663 +#define regHUBPREQ0_HUBPREQ_MEM_PWR_STATUS_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_5 0x0667 +#define regHUBPREQ0_VBLANK_PARAMETERS_5_BASE_IDX 2 +#define regHUBPREQ0_VBLANK_PARAMETERS_6 0x0668 +#define regHUBPREQ0_VBLANK_PARAMETERS_6_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_3 0x0669 +#define regHUBPREQ0_FLIP_PARAMETERS_3_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_4 0x066a +#define regHUBPREQ0_FLIP_PARAMETERS_4_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_5 0x066b +#define regHUBPREQ0_FLIP_PARAMETERS_5_BASE_IDX 2 +#define regHUBPREQ0_FLIP_PARAMETERS_6 0x066c +#define regHUBPREQ0_FLIP_PARAMETERS_6_BASE_IDX 2 +#define regHUBPREQ0_UCLK_PSTATE_FORCE 0x066d +#define regHUBPREQ0_UCLK_PSTATE_FORCE_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_STATUS_REG0 0x066e +#define regHUBPREQ0_HUBPREQ_STATUS_REG0_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_STATUS_REG1 0x066f +#define regHUBPREQ0_HUBPREQ_STATUS_REG1_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_STATUS_REG2 0x0670 +#define regHUBPREQ0_HUBPREQ_STATUS_REG2_BASE_IDX 2 +#define regHUBPREQ0_HUBPREQ_STATUS_REG3 0x0671 +#define regHUBPREQ0_HUBPREQ_STATUS_REG3_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp0_dispdec_hubpret_dispdec +// base address: 0x0 +#define regHUBPRET0_HUBPRET_CONTROL 0x0679 +#define regHUBPRET0_HUBPRET_CONTROL_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_MEM_PWR_CTRL 0x067a +#define regHUBPRET0_HUBPRET_MEM_PWR_CTRL_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_MEM_PWR_STATUS 0x067b +#define regHUBPRET0_HUBPRET_MEM_PWR_STATUS_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE_CTRL0 0x067c +#define regHUBPRET0_HUBPRET_READ_LINE_CTRL0_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE_CTRL1 0x067d +#define regHUBPRET0_HUBPRET_READ_LINE_CTRL1_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE0 0x067e +#define regHUBPRET0_HUBPRET_READ_LINE0_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE1 0x067f +#define regHUBPRET0_HUBPRET_READ_LINE1_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_INTERRUPT 0x0680 +#define regHUBPRET0_HUBPRET_INTERRUPT_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE_VALUE 0x0681 +#define regHUBPRET0_HUBPRET_READ_LINE_VALUE_BASE_IDX 2 +#define regHUBPRET0_HUBPRET_READ_LINE_STATUS 0x0682 +#define regHUBPRET0_HUBPRET_READ_LINE_STATUS_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp0_dispdec_cursor0_dispdec +// base address: 0x0 +#define regCURSOR0_0_CURSOR_CONTROL 0x0686 +#define regCURSOR0_0_CURSOR_CONTROL_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_SURFACE_ADDRESS 0x0687 +#define regCURSOR0_0_CURSOR_SURFACE_ADDRESS_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_SURFACE_ADDRESS_HIGH 0x0688 +#define regCURSOR0_0_CURSOR_SURFACE_ADDRESS_HIGH_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_SIZE 0x0689 +#define regCURSOR0_0_CURSOR_SIZE_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_POSITION 0x068a +#define regCURSOR0_0_CURSOR_POSITION_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_HOT_SPOT 0x068b +#define regCURSOR0_0_CURSOR_HOT_SPOT_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_STEREO_CONTROL 0x068c +#define regCURSOR0_0_CURSOR_STEREO_CONTROL_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_DST_OFFSET 0x068d +#define regCURSOR0_0_CURSOR_DST_OFFSET_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_MEM_PWR_CTRL 0x068e +#define regCURSOR0_0_CURSOR_MEM_PWR_CTRL_BASE_IDX 2 +#define regCURSOR0_0_CURSOR_MEM_PWR_STATUS 0x068f +#define regCURSOR0_0_CURSOR_MEM_PWR_STATUS_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_ADDRESS_HIGH 0x0690 +#define regCURSOR0_0_DMDATA_ADDRESS_HIGH_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_ADDRESS_LOW 0x0691 +#define regCURSOR0_0_DMDATA_ADDRESS_LOW_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_CNTL 0x0692 +#define regCURSOR0_0_DMDATA_CNTL_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_QOS_CNTL 0x0693 +#define regCURSOR0_0_DMDATA_QOS_CNTL_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_STATUS 0x0694 +#define regCURSOR0_0_DMDATA_STATUS_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_SW_CNTL 0x0695 +#define regCURSOR0_0_DMDATA_SW_CNTL_BASE_IDX 2 +#define regCURSOR0_0_DMDATA_SW_DATA 0x0696 +#define regCURSOR0_0_DMDATA_SW_DATA_BASE_IDX 2 +#define regCURSOR0_0_HUBP_3DLUT_CONTROL 0x0697 +#define regCURSOR0_0_HUBP_3DLUT_CONTROL_BASE_IDX 2 +#define regCURSOR0_0_HUBP_3DLUT_ADDRESS_LOW 0x0698 +#define regCURSOR0_0_HUBP_3DLUT_ADDRESS_LOW_BASE_IDX 2 +#define regCURSOR0_0_HUBP_3DLUT_ADDRESS_HIGH 0x0699 +#define regCURSOR0_0_HUBP_3DLUT_ADDRESS_HIGH_BASE_IDX 2 +#define regCURSOR0_0_HUBP_3DLUT_DLG_PARAM 0x069a +#define regCURSOR0_0_HUBP_3DLUT_DLG_PARAM_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp0_dispdec_hubp_dcperfmon_dc_perfmon_dispdec +// base address: 0x1a74 +#define regDC_PERFMON6_PERFCOUNTER_CNTL 0x069d +#define regDC_PERFMON6_PERFCOUNTER_CNTL_BASE_IDX 2 +#define regDC_PERFMON6_PERFCOUNTER_CNTL2 0x069e +#define regDC_PERFMON6_PERFCOUNTER_CNTL2_BASE_IDX 2 +#define regDC_PERFMON6_PERFCOUNTER_STATE 0x069f +#define regDC_PERFMON6_PERFCOUNTER_STATE_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_CNTL 0x06a0 +#define regDC_PERFMON6_PERFMON_CNTL_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_CNTL2 0x06a1 +#define regDC_PERFMON6_PERFMON_CNTL2_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_CVALUE_INT_MISC 0x06a2 +#define regDC_PERFMON6_PERFMON_CVALUE_INT_MISC_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_CVALUE_LOW 0x06a3 +#define regDC_PERFMON6_PERFMON_CVALUE_LOW_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_HI 0x06a4 +#define regDC_PERFMON6_PERFMON_HI_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_LOW 0x06a5 +#define regDC_PERFMON6_PERFMON_LOW_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_TEST_DEBUG_INDEX 0x06a6 +#define regDC_PERFMON6_PERFMON_TEST_DEBUG_INDEX_BASE_IDX 2 +#define regDC_PERFMON6_PERFMON_TEST_DEBUG_DATA 0x06a7 +#define regDC_PERFMON6_PERFMON_TEST_DEBUG_DATA_BASE_IDX 2 + + +// addressBlock: dce_dc_dcbubp1_dispdec_hubp_dispdec +// base address: 0x370 +#define regHUBP1_DCSURF_SURFACE_CONFIG 0x06c1 +#define regHUBP1_DCSURF_SURFACE_CONFIG_BASE_IDX 2 +#define regHUBP1_DCSURF_ADDR_CONFIG 0x06c2 +#define regHUBP1_DCSURF_ADDR_CONFIG_BASE_IDX 2 +#define regHUBP1_DCSURF_TILING_CONFIG 0x06c3 +#define regHUBP1_DCSURF_TILING_CONFIG_BASE_IDX 2 +#define regHUBP1_DCSURF_LEGACY_ADDR_CONFIG 0x06c4 +#define regHUBP1_DCSURF_LEGACY_ADDR_CONFIG_BASE_IDX 2 +#define regHUBP1_DCSURF_PRI_VIEWPORT_START 0x06c5 +#define regHUBP1_DCSURF_PRI_VIEWPORT_START_BASE_IDX 2 +#define regHUBP1_DCSURF_VIEWPORT_MCACHE_SPLIT_COORDINATE 0x06c6 +#define regHUBP1_DCSURF_VIEWPORT_MCACHE_SPLIT_COORDINATE_BASE_IDX 2 +#define regHUBP1_DCSURF_PRI_VIEWPORT_DIMENSION 0x06c7 +#define regHUBP1_DCSURF_PRI_VIEWPORT_DIMENSION_BASE_IDX 2 +#define regHUBP1_DCSURF_PRI_VIEWPORT_START_C 0x06c8
Lines of this file are not shown. View the raw message.
drivers/gpu/drm/amd/include/asic_reg/dcn/dcn_6_0_0_sh_mask.h new file +58556 -0
58,556 lines not on this page · raw message
drivers/gpu/drm/amd/include/asic_reg/dpcs/dpcs_6_0_0_offset.h new file +47 -0
47 lines not on this page · raw message
drivers/gpu/drm/amd/include/asic_reg/dpcs/dpcs_6_0_0_sh_mask.h new file +55 -0
55 lines not on this page · raw message
drivers/gpu/drm/amd/include/asic_reg/mmhub/mmhub_5_0_1_offset.h new file +17 -0
Lines of this file are not shown. View the raw message.
drivers/gpu/drm/amd/include/asic_reg/mmhub/mmhub_5_0_1_sh_mask.h new file +17 -0
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.53.0
Part of the diff is not shown here. View the raw message.
Greg Kroah-Hartman
maintainerPATCH 188/2214 ACPI: APEI: Handle repeated SEA error storms
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Junhao He <[email protected]>
[ Upstream commit e61487226b7df39e5f4683b036ee6aa7a5039d7b ]
When hardware memory corruption occurs and a user process accesses the corrupted page, the CPU triggers a Synchronous External Abort (SEA). The kernel invokes do_sea() to handle the exception, which calls memory_failure() to handle the faulty page.
Scenario 1: Memory Error Interrupt First, then SEA
The page is already poisoned by the memory error interrupt path. The subsequent SEA handler sends a SIGBUS to the task, which accesses the poisoned page. This flow is correct.
Scenario 2: SEA first, then memory error interrupt (problematic scenario) If a user task directly accesses corrupted memory through a PFNMAP-style mapping (e.g., devmem), the page may still be in the free-buddy state when SEA is handled. In this case, memory_failure() will poison the page without invoking kill_accessing_process(), and then takes the free-buddy recovery path.
After the CPU returns to the task context, the task re-enters the SEA handler due to the same access. However, ghes_estatus_cached() suppresses all subsequent entries during the 10-second window, preventing ghes_do_proc() from being called. This suppression blocks the MF_ACTION_REQUIRED-based SIGBUS delivery, causing the kernel to fail to kill the task immediately. Consequently, the process keeps re-entering the SEA handler, leading to an SEA storm. Later, the memory error interrupt path also cannot kill the task, leaving the system stuck in this repeated loop.
The following error logs are explained using the devmem process:
NOTICE: SEA Handle
[Hardware Error]: Hardware error from APEI Generic Hardware Error Source: 9 [Hardware Error]: event severity: recoverable
[Hardware Error]: section_type: ARM processor error
[Hardware Error]: physical fault address: 0x0000001000093c00
[T54990] Memory failure: 0x1000093: recovery action for free buddy page: Recovered [ T9955] EDAC MC0: 1 UE Multi-bit ECC on unknown memory
(page:0x1000093 offset:0xc00 grain:1 - APEI location: ...)
NOTICE: SEA Handle
NOTICE: SEA Handle
...
... ---> SEA storm
...
NOTICE: SEA Handle
[ T9955] Memory failure: 0x1000093: already hardware poisoned
ghes_print_estatus: 1 callbacks suppressed
[Hardware Error]: Hardware error from APEI Generic Hardware Error Source: 9 [Hardware Error]: event severity: recoverable
[Hardware Error]: section_type: ARM processor error
[Hardware Error]: physical fault address: 0x0000001000093c00
[T54990] Memory failure: 0x1000093: already hardware poisoned
[T54990] 0x1000093: Sending SIGBUS to devmem:54990 due to hardware memory corruption
To resolve this, return an error when encountering the same SEA again. The subsequent SEA handler invocation uses arm64_notify_die() to send a SIGBUS signal to the task, which terminates the process and prevents it from re-entering the handler loop.
--- drivers/acpi/apei/ghes.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-)
drivers/acpi/apei/ghes.c +9 -1
@@ -1102,8 +1102,16 @@ static int ghes_in_nmi_queue_one_entry(struct ghes *ghes,ghes_clear_estatus (ghes, &tmp_header, buf_paddr, fixmap_idx);/* This error has been reported before, don't process it again. */ -if (ghes_estatus_cached (estatus)) +if (ghes_estatus_cached (estatus)) { +/* +* Return failure on duplicate SEA entries so that the +* subsequent SEA handler invocation sends a SIGBUS signal to +* the task to prevent it from re-entering the handler loop. +*/ +if (is_hest_sync_notify (ghes)) + rc = -ECANCELED ; goto no_work; + }llist_add (&estatus_node->llnode, &ghes_estatus_llist);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 189/2214 Bluetooth: btrsi: Move set_bt_context after successful HCI registration
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chen Changcheng <[email protected]>
[ Upstream commit 290a3644609526f7ac12529cd1618042fa5a32db ]
In rsi_hci_attach(), ops->set_bt_context() stores the newly allocated h_adapter into common->bt_adapter before hci_alloc_dev() and hci_register_dev() are called. If either of these fails, h_adapter is freed but common->bt_adapter remains a non-NULL dangling pointer.
This causes a deterministically reachable use-after-free when the device operates in a BT+WiFi coexistence mode and CONFIG_RSI_COEX is enabled. The following software-only trigger paths exist:
1. SDIO driver .remove (rsi_disconnect)
2. USB driver .disconnect (rsi_disconnect)
3. SDIO driver .shutdown (rsi_shutdown)
4. Hibernation .freeze (rsi_freeze)
All four paths check:
if (IS_ENABLED(CONFIG_RSI_COEX) && coex_mode > 1 && bt_adapter)
rsi_bt_ops.detach(bt_adapter); // use-after-free
coex_mode is set during rsi_91x_init(), before rsi_hci_attach() is called, and is not cleared on attach failure. Since set_bt_context() already wrote bt_adapter before the failure, the deinit paths see a non-NULL dangling pointer and proceed to detach it.
Fix this by moving set_bt_context() after hci_register_dev() succeeds. On failure paths bt_adapter stays NULL, and the deinit callers correctly skip the detach call.
--- drivers/bluetooth/btrsi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/bluetooth/btrsi.c +2 -1
@@ -118,7 +118,6 @@ static int rsi_hci_attach(void *priv, struct rsi_proto_ops *ops)return -ENOMEM ; h_adapter->priv = priv; - ops->set_bt_context (priv, h_adapter); h_adapter->proto_ops = ops; hdev =hci_alloc_dev ();
@@ -148,6 +147,8 @@ static int rsi_hci_attach(void *priv, struct rsi_proto_ops *ops) goto err; } + ops->set_bt_context (priv, h_adapter); +return 0 ; err: h_adapter->hdev =NULL ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 190/2214 Bluetooth: hci_bcsp: validate received packet lengths
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Li Qiang <[email protected]>
[ Upstream commit ceea75ad8925425ee6520ead964b55888fe871ec ]
The BCSP transmit path reads an HCI command header when an extension packet has only been tested for a nonzero length. Its LE configuration packet handler also indexes bytes through offset seven without a length check.
Validate the complete command and LE configuration packet headers before accessing their fields.
--- drivers/bluetooth/hci_bcsp.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/bluetooth/hci_bcsp.c +4 -1
@@ -194,7 +194,7 @@ static struct sk_buff *bcsp_prepare_pkt(struct bcsp_struct *bcsp, u8 *data,return NULL ; } -if (hciextn && chan ==5 ) { +if (hciextn && chan ==5 && len >HCI_COMMAND_HDR_SIZE ) {__le16 opcode = ((struct hci_command_hdr *)data)->opcode;/* Vendor specific commands */
@@ -402,6 +402,9 @@ static void bcsp_handle_le_pkt(struct hci_uart *hu)u8 sync_pkt[4 ] = {0xda ,0xdc ,0xed ,0xed };/* spot "conf" pkts and reply with a "conf rsp" pkt */ +if (bcsp->rx_skb->len <8 ) +return ; +if (bcsp->rx_skb->data[1 ] >>4 ==4 && bcsp->rx_skb->data[2 ] ==0 && !memcmp (&bcsp->rx_skb->data[4 ], conf_pkt,4 )) {struct sk_buff *nskb =alloc_skb (4 ,GFP_ATOMIC );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 191/2214 net: dsa: mt7530: error out on failed PHY_IAC command writes
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Daniel Golle <[email protected]>
[ Upstream commit 1c95dcb7e923beebccdc79adc3dc1ec8c52295d0 ]
MT7531_PHY_ACS_ST is only ever set by the command write that precedes each poll in the MT7531 indirect PHY access functions, and that write's return value is discarded. A failed write leaves ACS_ST at 0 from the previous access, so the poll succeeds on its first iteration and the functions return stale IAC contents as if they were fresh PHY data. Check the writes and bail out before polling.
--- drivers/net/dsa/mt7530.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-)
drivers/net/dsa/mt7530.c +18 -6
@@ -650,7 +650,9 @@ mt7531_ind_c45_phy_read(struct mt7530_priv *priv, int port, int devad, reg =MT7531_MDIO_CL45_ADDR |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_DEV_ADDR (devad) | regnum; -mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, val, !(val &MT7531_PHY_ACS_ST ),20 ,100000 );
@@ -661,7 +663,9 @@ mt7531_ind_c45_phy_read(struct mt7530_priv *priv, int port, int devad, reg =MT7531_MDIO_CL45_READ |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_DEV_ADDR (devad); -mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, val, !(val &MT7531_PHY_ACS_ST ),20 ,100000 );
@@ -699,7 +703,9 @@ mt7531_ind_c45_phy_write(struct mt7530_priv *priv, int port, int devad, reg =MT7531_MDIO_CL45_ADDR |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_DEV_ADDR (devad) | regnum; -mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, val, !(val &MT7531_PHY_ACS_ST ),20 ,100000 );
@@ -710,7 +716,9 @@ mt7531_ind_c45_phy_write(struct mt7530_priv *priv, int port, int devad, reg =MT7531_MDIO_CL45_WRITE |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_DEV_ADDR (devad) | data; -mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, val, !(val &MT7531_PHY_ACS_ST ),20 ,100000 );
@@ -747,7 +755,9 @@ mt7531_ind_c22_phy_read(struct mt7530_priv *priv, int port, int regnum) val =MT7531_MDIO_CL22_READ |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_REG_ADDR (regnum); -mt7530_mii_write (priv,MT7531_PHY_IAC , val |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , val |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, val, !(val &MT7531_PHY_ACS_ST ),20 ,100000 );
@@ -786,7 +796,9 @@ mt7531_ind_c22_phy_write(struct mt7530_priv *priv, int port, int regnum, reg =MT7531_MDIO_CL22_WRITE |MT7531_MDIO_PHY_ADDR (port) |MT7531_MDIO_REG_ADDR (regnum) | data; -mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); + ret =mt7530_mii_write (priv,MT7531_PHY_IAC , reg |MT7531_PHY_ACS_ST ); +if (ret <0 ) + goto out; ret =readx_poll_timeout (_mt7530_unlocked_read, &p, reg, !(reg &MT7531_PHY_ACS_ST ),20 ,100000 );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 192/2214 fbdev: omap2: dsi: do not copy isr table
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Andreas Kemnade <[email protected]>
[ Upstream commit 31875c51c31edec57b3620f278680c23a823763b ]
To te able to unregister stuff from isrs, the corresponding table was copied. Nobody seems to unregister stuff that way, so it does not help. But there are stack-allocated objects passed to these isrs giving chances of UAF of these objects if irqs are unregistered while they are handled, so better do not copy that table.
--- drivers/video/fbdev/omap2/omapfb/dss/dsi.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-)
drivers/video/fbdev/omap2/omapfb/dss/dsi.c +1 -8
@@ -325,8 +325,6 @@ struct dsi_data {spinlock_t irq_lock;struct dsi_isr_tables isr_tables; -/* space for a copy used by the interrupt handler */ -struct dsi_isr_tables isr_tables_copy;int update_channel;#ifdef DSI_PERF_MEASURE
@@ -837,15 +835,10 @@ static irqreturn_t omap_dsi_irq_handler(int irq, void *arg)del_timer (&dsi->te_timer);#endif -/* make a copy and unlock, so that isrs can unregister -* themselves */ -memcpy (&dsi->isr_tables_copy, &dsi->isr_tables, -sizeof (dsi->isr_tables)); +dsi_handle_isrs (&dsi->isr_tables, irqstatus, vcstatus, ciostatus);spin_unlock (&dsi->irq_lock); -dsi_handle_isrs (&dsi->isr_tables_copy, irqstatus, vcstatus, ciostatus); -dsi_handle_irq_errors (dsidev, irqstatus, vcstatus, ciostatus);dsi_collect_irq_stats (dsidev, irqstatus, vcstatus, ciostatus);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 193/2214 fbdev: udlfb: validate vendor descriptor items
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 3cc2fad376ac7360b4518277aa923752624db59c ]
dlfb_parse_vendor_descriptor() walks key-length-value items inside the DisplayLink vendor descriptor.
Require each item to contain its key, length and declared value bytes before reading item-specific fields such as max_area.
--- drivers/video/fbdev/udlfb.c | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-)
drivers/video/fbdev/udlfb.c +16 -6
@@ -1636,19 +1636,29 @@ static int dlfb_parse_vendor_descriptor(struct dlfb_data *dlfb, desc +=5 ;/* the fixed header we've already parsed */ while (desc < desc_end) { +char *value;u8 length;u16 key; - key = *desc++; - key |= (u16)*desc++ <<8 ; +if (desc_end - desc <sizeof (key) +sizeof (length)) + goto unrecognized; + + key =get_unaligned_le16 (desc); + desc +=sizeof (key); length = *desc++; +if (length > desc_end - desc) + goto unrecognized; + + value = desc;switch (key) {case 0x0200 : {/* max_area */ -u32 max_area = *desc++; - max_area |= (u32)*desc++ <<8 ; - max_area |= (u32)*desc++ <<16 ; - max_area |= (u32)*desc++ <<24 ; +u32 max_area; + +if (length <sizeof (max_area)) + goto unrecognized; + + max_area =get_unaligned_le32 (value);dev_warn (&intf->dev,"DL chip limited to %d pixel modes\n" , max_area);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 194/2214 ALSA: usx2y: Stop clearing urb->hcpriv before submission
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Michal Pecio <[email protected]>
[ Upstream commit fabae5548149ef5c8a056875d9ebdc38366db539 ]
This is managed by USB core and drivers aren't expected to touch it.
It should only be not NULL on a submitted URB, in which case clearing defeats the "submitted while active" sanity check in usb_submit_urb() and may crash the HCD handling the URB and panic the kernel.
--- sound/usb/usx2y/usbusx2yaudio.c | 1 - 1 file changed, 1 deletion(-)
sound/usb/usx2y/usbusx2yaudio.c +0 -1
@@ -165,7 +165,6 @@ static int usx2y_urb_submit(struct snd_usx2y_substream *subs, struct urb *urb, iif (!urb)return -ENODEV ; urb->start_frame = frame +NRURBS *nr_of_packs ();// let hcd do rollover sanity checks - urb->hcpriv =NULL ; urb->dev = subs->usx2y->dev;/* we need to set this at each time */ err =usb_submit_urb (urb,GFP_ATOMIC );if (err <0 ) {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 195/2214 selftests/net: fin_ack_lat: fix latency threshold typo
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Brian Grech <[email protected]>
[ Upstream commit 2373107782a98ba15931a37bbd9dd46d7213e5aa ]
The commit message for af8c8a450bf4 ("selftests: net: Add FIN_ACK processing order related latency spike test") states: "if the latency is larger than 1 second (spike), print a message". However the code uses a threshold of 100000 us (100 ms), not 1000000 us (1 s).
The lower threshold causes false positives on slower hardware where normal connection latency occasionally exceeds 100 ms but never approaches the 1 s spike that indicates the actual FIN/ACK race bug.
Fix the threshold to match the documented intent.
--- tools/testing/selftests/net/fin_ack_lat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tools/testing/selftests/net/fin_ack_lat.c +1 -1
@@ -69,7 +69,7 @@ static void client(int port) lat =timediff (start, end); sum_lat += lat; nr_lat++; -if (lat <100000 ) +if (lat <1000000 ) goto close;if (getsockname (sock, (struct sockaddr *)&laddr, &len) ==-1 )
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 196/2214 docs: cgroup-v2: fix stale "io" controller introduction
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zhe Liu <[email protected]>
[ Upstream commit 3345c7248a9e2a91cb9e2477c29af16881706f4f ]
The introductory paragraph for the IO controller still states that weight based distribution is "available only if cfq-iosched is in use" and that "neither scheme is available for blk-mq devices". This text dates from when the cgroup v2 documentation was first written (2015) and was correct at the time, but is no longer accurate:
* cfq-iosched was removed in v5.0;
* blk-mq is now the only block I/O path, and both the absolute limit scheme (io.max via blk-throttle) and the weight based scheme (io.weight via iocost, or io.bfq.weight under BFQ) work on it;
* latency based protection (iolatency) and I/O priority (ioprio) controllers have since been added.
The rest of the section already documents io.weight, io.max, io.cost.{qos,model}, io.latency and io.prio.class correctly, so the introduction is the only part that contradicts them. Rewrite it to reflect the current state.
--- Documentation/admin-guide/cgroup-v2.rst | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
Documentation/admin-guide/cgroup-v2.rst +7 -3
@@ -1552,9 +1552,13 @@ IO The "io" controller regulates the distribution of IO resources. This controller implements both weight based and absolute bandwidth or IOPS -limit distribution; however, weight based distribution is available -only if cfq-iosched is in use and neither scheme is available for -blk-mq devices. +limit distribution. Absolute BPS and IOPS limits are enforced by +blk-throttle and apply to all devices, while weight based proportional +distribution is provided by the iocost cost model controller +(CONFIG_BLK_CGROUP_IOCOST) and, when the BFQ I/O scheduler is in use +for a device, by BFQ's own cgroup support. Latency-based protection +(CONFIG_BLK_CGROUP_IOLATENCY) and I/O priority assignment +(CONFIG_BLK_CGROUP_IOPRIO) are also available. IO Interface Files
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 197/2214 nvme-tcp: look up host_iface in the current netns
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Geliang Tang <[email protected]>
[ Upstream commit 58202950e39c127d593ec4f0624d8b8985a285b1 ]
nvme_tcp_alloc_ctrl() looks opts->host_iface up in &init_net, the boot-time netns. When called from any other netns - e.g. the selftest's ns2, where ns2eth1 actually lives - the lookup misses and the controller setup fails with "invalid interface passed":
nvmet: adding nsid 1 to subsystem nqn.2014-08.org.nvmexpress.mptcpdev
nvmet_tcp: enabling port 24660 (0.0.0.0:24099)
# nvme discover -a 10.1.1.1 --tos=0x10 --host-iface=ns2eth1 nvme_tcp: invalid interface passed: ns2eth1 # failed to add controller, error invalid interface
Look the device up in current->nsproxy->net_ns instead so the check sees the calling task's netns.
--- drivers/nvme/host/tcp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/nvme/host/tcp.c +2 -1
@@ -2678,7 +2678,8 @@ static struct nvme_ctrl *nvme_tcp_create_ctrl(struct device *dev, }if (opts->mask &NVMF_OPT_HOST_IFACE ) { -if (!__dev_get_by_name (&init_net, opts->host_iface)) { +if (!__dev_get_by_name (current->nsproxy->net_ns, + opts->host_iface)) {pr_err ("invalid interface passed: %s\n" , opts->host_iface); ret = -ENODEV ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 198/2214 nfc: mrvl: spi: Unregister dev on allocation fail
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Griffin Kroah-Hartman <[email protected]>
[ Upstream commit d832b95697384a2b67f20b35106bbf925358cde9 ]
Call nfcmrvl_nci_unregister_dev() if nci_spi_allocate_spi() fails, unwrapping the previous call to nfcmrvl_nci_register_dev() during the nfcmrvl_spi_probe() function.
--- drivers/nfc/nfcmrvl/spi.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/nfc/nfcmrvl/spi.c +4 -0
@@ -168,6 +168,10 @@ static int nfcmrvl_spi_probe(struct spi_device *spi) drv_data->nci_spi =nci_spi_allocate_spi (drv_data->spi,0 ,10 , drv_data->priv->ndev); +if (!drv_data->nci_spi) { +nfcmrvl_nci_unregister_dev (drv_data->priv); +return -ENOMEM ; + }/* Init completion for slave handshake */ init_completion (&drv_data->handshake_completion);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 199/2214 nfc: nxp-nci: Add remove on IRQ error
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Griffin Kroah-Hartman <[email protected]>
[ Upstream commit 56345cea6a30dc7a1b036d5fb7900434b4a4c5e8 ]
Add a call to nxp_nci_remove() in nxp_nci_i2c_probe() when the request_threaded_irq() fails.
Previously, IRQ resources were not being freed upon error.
--- drivers/nfc/nxp-nci/i2c.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/nfc/nxp-nci/i2c.c +3 -1
@@ -327,8 +327,10 @@ static int nxp_nci_i2c_probe(struct i2c_client *client, nxp_nci_i2c_irq_thread_fn, irqflags |IRQF_ONESHOT , NXP_NCI_I2C_DRIVER_NAME, phy); -if (r <0 ) +if (r <0 ) {nfc_err (&client->dev,"Unable to register IRQ handler\n" ); +nxp_nci_remove (phy->ndev); + }return r; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 200/2214 nvme: ratelimit the completion-path messages driven by device data
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chao Shi <[email protected]>
[ Upstream commit c05c86681170e381e24498257db3a879deb1ae89 ]
nvme_find_rq() and nvme_handle_cqe() print an unratelimited message for every completion queue entry whose command id does not resolve to an in-flight request. Both are reached from the completion interrupt path (nvme_irq() -> nvme_poll_cq() -> nvme_handle_cqe()) and the decision to print is made entirely from device-supplied data, so a controller that posts a stream of bogus command ids drives unbounded printk from hard interrupt context.
This is not hypothetical. A single boot under an emulated controller that posts invalid completions produced 846 "could not locate request for tag 0x0", 846 "invalid id 0 completed on queue 2" and 123 "genctr mismatch" lines. Once the tag set has been torn down every subsequent completion resolves to nothing, so the print rate is bounded only by how fast the device can post entries.
Ratelimit the three messages. The information they carry is diagnostic and repeats, so the suppression count printed by the ratelimit helpers is enough to tell that the condition persists. This matches how the other device-driven error prints in the driver are already handled, for example the status messages in nvme_log_error() and nvme_log_err_passthru().
nvme_find_rq() lives in nvme.h and is shared by pci, tcp, rdma, apple and target-loop, so all transports are covered.
Found by FuzzNvme.
--- drivers/nvme/host/nvme.h | 6 +++--- drivers/nvme/host/pci.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-)
drivers/nvme/host/nvme.h +3 -3
@@ -544,12 +544,12 @@ static inline struct request *nvme_find_rq(struct blk_mq_tags *tags, rq =blk_mq_tag_to_rq (tags, tag);if (unlikely (!rq)) { -pr_err ("could not locate request for tag %#x\n" , - tag); +pr_err_ratelimited ("could not locate request for tag %#x\n" , + tag);return NULL ; }if (unlikely (nvme_genctr_mask (nvme_req (rq)->genctr) != genctr)) { -dev_err (nvme_req (rq)->ctrl->device, +dev_err_ratelimited (nvme_req (rq)->ctrl->device,"request %#x genctr mismatch (got %#x expected %#x)\n" , tag, genctr,nvme_genctr_mask (nvme_req (rq)->genctr));return NULL ;
drivers/nvme/host/pci.c +3 -3
@@ -1015,9 +1015,9 @@ static inline void nvme_handle_cqe(struct nvme_queue *nvmeq, u16 idx) req =nvme_find_rq (nvme_queue_tagset (nvmeq), command_id);if (unlikely (!req)) { -dev_warn (nvmeq->dev->ctrl.device, -"invalid id %d completed on queue %d\n" , - command_id,le16_to_cpu (cqe->sq_id)); +dev_warn_ratelimited (nvmeq->dev->ctrl.device, +"invalid id %d completed on queue %d\n" , + command_id,le16_to_cpu (cqe->sq_id));return ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 201/2214 alpha: run the remote RTC access in a worker, not an IPI callback
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Matt Turner <[email protected]>
[ Upstream commit 6f45effbd74012f1715584ba51abaa3196a47c08 ]
On Marvel the CMOS clock is only reachable from the boot cpu, so remote_read_time() and remote_set_time() bounce the access there with smp_call_function_single(), whose callback runs in hard interrupt context.
alpha_rtc_read_time() calls mc146818_get_time() with a 10 ms timeout. That waits out the RTC update cycle in mc146818_avoid_UIP(), which drops rtc_lock and udelay()s 100 us at a time until the update completes or the timeout expires:
for (i = 0; UIP_RECHECK_LOOPS_MS(i) < timeout; i++) {
spin_lock_irqsave(&rtc_lock, flags);
...
if (CMOS_READ(RTC_FREQ_SELECT) & RTC_UIP) {
spin_unlock_irqrestore(&rtc_lock, flags);
udelay(UIP_RECHECK_DELAY);
continue;
}So a clock read from a non-boot cpu can spin for up to 10 ms in hard interrupt context on the boot cpu, while the cpu that sent the request spins in smp_call_function_single() waiting for it to finish.
mc146818_set_time() does not poll, but it takes rtc_lock too, and rtc_lock is a spinlock_t. Only raw spinlocks may be taken in hard interrupt context, so lockdep reports the write path as soon as a non-boot cpu sets the clock:
[ BUG: Invalid wait context ]
-----------------------------
swapper/0/0 is trying to lock:
fffffc0003690470 (rtc_lock){....}-{3:3}, at: mc146818_set_time+0x74/0x450 other info that might help us debug this:
context-{2:2}
no locks held by swapper/0/0.
stack backtrace: CPU: 0 UID: 0 PID: 0 Comm: swapper/0 Not tainted 7.2.0-rc1 #1 NONE Trace: [<fffffc000102ebb0>] dump_stack+0x28/0x44 [<fffffc000110efcc>] __lock_acquire+0xb0c/0x1060 [<fffffc000110f5f0>] lock_acquire.part.0+0xd0/0x300 [...] [<fffffc0001b0d834>] mc146818_set_time+0x74/0x450 [<fffffc0001f090cc>] _raw_spin_lock_irqsave+0x7c/0xc0 [<fffffc0001042f90>] do_remote_set+0x90/0xc0 [<fffffc000119c1a4>] __flush_smp_call_function_queue+0x314/0x5c0 [<fffffc000119c474>] generic_smp_call_function_single_interrupt+0x24/0x40 [<fffffc000103d984>] handle_ipi+0xa4/0x230 [<fffffc0001037044>] do_entInt+0x1a4/0x2e0
The rtc class ops are always called from process context, so there is no reason to run the access from an interrupt at all. Use work_on_cpu() to run it in a worker on the boot cpu. Alpha does not support cpu hotplug, so the boot cpu cannot go offline while the work is pending.
Tested on an AlphaServer ES47 (Marvel/EV7): hwclock read and write pinned to a non-boot cpu, twenty times, with no splat.
--- arch/alpha/kernel/rtc.c | 37 ++++++++++++------------------------- 1 file changed, 12 insertions(+), 25 deletions(-)
arch/alpha/kernel/rtc.c +12 -25
@@ -15,6 +15,7 @@#include <linux/bcd.h> #include <linux/rtc.h> #include <linux/platform_device.h> +#include <linux/workqueue.h> #include "proto.h"
@@ -142,54 +143,40 @@ static const struct rtc_class_ops alpha_rtc_ops = { };/* -* Similarly, except do the actual CMOS access on the boot cpu only. -* This requires marshalling the data across an interprocessor call. +* Similarly, except do the actual CMOS access on the boot cpu only. The +* access polls for the RTC update cycle and takes rtc_lock, so run it in a +* worker on that cpu rather than from an interprocessor interrupt. */ #if defined(CONFIG_SMP ) && \ (defined(CONFIG_ALPHA_GENERIC ) || defined(CONFIG_ALPHA_MARVEL ))# define HAVE_REMOTE_RTC 1 -union remote_data { -struct rtc_time *tm; -long retval; -}; - -static void +static long do_remote_read (void *data) { -union remote_data *x = data; - x->retval =alpha_rtc_read_time (NULL , x->tm); +return alpha_rtc_read_time (NULL , data); }static int remote_read_time (struct device *dev,struct rtc_time *tm) { -union remote_data x; -if (smp_processor_id () != boot_cpuid) { - x.tm = tm; -smp_call_function_single (boot_cpuid, do_remote_read, &x,1 ); -return x.retval; - } +if (smp_processor_id () != boot_cpuid) +return work_on_cpu (boot_cpuid, do_remote_read, tm);return alpha_rtc_read_time (NULL , tm); } -static void +static long do_remote_set (void *data) { -union remote_data *x = data; - x->retval =alpha_rtc_set_time (NULL , x->tm); +return alpha_rtc_set_time (NULL , data); }static int remote_set_time (struct device *dev,struct rtc_time *tm) { -union remote_data x; -if (smp_processor_id () != boot_cpuid) { - x.tm = tm; -smp_call_function_single (boot_cpuid, do_remote_set, &x,1 ); -return x.retval; - } +if (smp_processor_id () != boot_cpuid) +return work_on_cpu (boot_cpuid, do_remote_set, tm);return alpha_rtc_set_time (NULL , tm); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 202/2214 ALSA: hda/conexant: Add mute LED quirk for HP ProBook 440 G5
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dmytro Moroziuk <[email protected]>
[ Upstream commit 191fe151eb85ff6cb24189fc88c970745497c057 ]
The HP ProBook 440 G5 requires the CXT_FIXUP_MUTE_LED_GPIO quirk to properly toggle the physical mute and mic-mute LEDs via the CX8200 codec. Without this quirk, the LEDs remain permanently dark.
--- sound/pci/hda/patch_conexant.c | 1 + 1 file changed, 1 insertion(+)
sound/pci/hda/patch_conexant.c +1 -0
@@ -1125,6 +1125,7 @@ static const struct snd_pci_quirk cxt5066_fixups[] = {SND_PCI_QUIRK (0x103c ,0x829a ,"HP 800 G3 DM" ,CXT_FIXUP_HP_MIC_NO_PRESENCE ),SND_PCI_QUIRK (0x103c ,0x82b4 ,"HP ProDesk 600 G3" ,CXT_FIXUP_HP_MIC_NO_PRESENCE ),SND_PCI_QUIRK (0x103c ,0x836e ,"HP ProBook 455 G5" ,CXT_FIXUP_MUTE_LED_GPIO ), +SND_PCI_QUIRK (0x103c ,0x837b ,"HP ProBook 440 G5" ,CXT_FIXUP_MUTE_LED_GPIO ),SND_PCI_QUIRK (0x103c ,0x837f ,"HP ProBook 470 G5" ,CXT_FIXUP_MUTE_LED_GPIO ),SND_PCI_QUIRK (0x103c ,0x83b2 ,"HP EliteBook 840 G5" ,CXT_FIXUP_HP_DOCK ), SND_PCI_QUIRK(0x103c, 0x83b3, "HP EliteBook 830 G5", CXT_FIXUP_HP_DOCK),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 203/2214 hfsplus: validate extent record length before writing it back
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiaming Zhang <[email protected]>
[ Upstream commit 627b7865c062ff642c0000f3a4775f1a44b986a4 ]
__hfsplus_ext_write_extent() writes the cached extent record back into a B-tree node using fd->entrylength as the length, and fd->entrylength is derived in __hfs_brec_find() from two on-disk values:
fd->entrylength = len - keylen;
A crafted image can keep both len and keylen valid but make fd->entrylength negative (keylen > len). __hfsplus_ext_write_extent() doesn't check fd->entrylength before consuming it, and hfs_bnode_write() takes the length as u32, so the negative value turns into a huge one. The copy then reads data past the end of hip->cached_extents, which is only sizeof(hfsplus_extent_rec) bytes long, and leaks kernel memory into the image.
Reject an fd->entrylength that does not match sizeof(hfsplus_extent_rec) in __hfsplus_ext_write_extent(), mirroring the check already performed in __hfsplus_ext_read_extent().
--- fs/hfsplus/extents.c | 2 ++ 1 file changed, 2 insertions(+)
fs/hfsplus/extents.c +2 -0
@@ -110,6 +110,8 @@ static int __hfsplus_ext_write_extent(struct inode *inode, }else {if (res)return res; +if (fd->entrylength !=sizeof (hfsplus_extent_rec)) +return -EIO ;hfs_bnode_write (fd->bnode, hip->cached_extents, fd->entryoffset, fd->entrylength); hip->extent_state &= ~HFSPLUS_EXT_DIRTY ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 204/2214 ipmi: Fix leak in __ipmi_bmc_register
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Michail Tatas <[email protected]>
[ Upstream commit 18e633dd9674c8bf118ea8583bb5a531edc2728a ]
In case that ida_alloc(&ipmi_bmc_ida,...) succeeds and then platform_device_register() fails, ipmi_bmc_ida is leaked. Fix by freeing the error path
Message-ID: <anUK_HOy_pCgvsBm@michalis-linux>
--- drivers/char/ipmi/ipmi_msghandler.c | 1 + 1 file changed, 1 insertion(+)
drivers/char/ipmi/ipmi_msghandler.c +1 -0
@@ -3127,6 +3127,7 @@ static int __ipmi_bmc_register(struct ipmi_smi *intf,list_del (&intf->bmc_link);mutex_unlock (&bmc->dyn_mutex); intf->bmc = &intf->tmp_bmc; +ida_free (&ipmi_bmc_ida, bmc->pdev.id);put_device (&bmc->pdev.dev); goto out; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 205/2214 ALSA: hda/intel: Add sanity check for BAR0 size
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Takashi Iwai <[email protected]>
[ Upstream commit 9895573b0185f922be4cf500a0f2e5b9560ab1c3 ]
The recent reports from syzkaller showed that we can bind any wild PCI device to HD-audio controller, and if PCI BAR of the device is too small, it may lead to a crash, as the driver believes as if the full register range were accessible.
For avoiding such a problem, add a safeguard before the actual probe to check the available BAR0 size.
Note that the threshold (0x200) is chosen to cover all needed registers at probing. But this doesn't mean that it would cover fully for all features including the extended ones.
--- sound/pci/hda/hda_intel.c | 9 +++++++++ 1 file changed, 9 insertions(+)
sound/pci/hda/hda_intel.c +9 -0
@@ -2125,6 +2125,15 @@ static int azx_probe(struct pci_dev *pci,dev_warn (&pci->dev,"dmic_detect option is deprecated, pass snd-intel-dspcfg.dsp_driver=1 option instead\n" ); } +/* A sanity check against wild device binding; +* here the range 0x200 is enough for the registers used at probe, +* but it doesn't mean covering all HD-audio registers +*/ +if (pci_resource_len (pci,0 ) <0x200 ) { +dev_err (&pci->dev,"Too small PCI BAR0\n" ); +return -EINVAL ; + } + err =snd_card_new (&pci->dev, index[dev], id[dev],THIS_MODULE ,0 , &card);if (err <0 ) {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 206/2214 exfat: keep FITRIM within the requested range
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wen <[email protected]>
[ Upstream commit 2de727471b3b13409466a4af4f8824a86073bf4b ]
exfat_find_free_bitmap() searches the entire allocation bitmap and may wrap around to its beginning. exfat_trim_fs() does not verify that the returned cluster is still within the requested FITRIM range.
As a result, a partial FITRIM operation may discard free clusters outside the user-specified range and report a trimmed length larger than the requested length.
Validate each returned cluster against the requested range and stop the search when it wraps around or passes the range end.
--- fs/exfat/balloc.c | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-)
fs/exfat/balloc.c +19 -12
@@ -297,14 +297,27 @@ int exfat_trim_fs(struct inode *inode, struct fstrim_range *range)mutex_lock (&sbi->bitmap_lock); trim_begin = trim_end =exfat_find_free_bitmap (sb, clu_start); -if (trim_begin ==EXFAT_EOF_CLUSTER ) +/* +* exfat_find_free_bitmap() may wrap around to the beginning of +* the bitmap. Reject a cluster outside the requested range. +*/ +if (trim_begin ==EXFAT_EOF_CLUSTER || + trim_begin < clu_start || trim_begin > clu_end) goto unlock; - next_free_clu =exfat_find_free_bitmap (sb, trim_end +1 ); -if (next_free_clu ==EXFAT_EOF_CLUSTER ) - goto unlock; +for (;;) { +if (trim_end >= clu_end) +break ; + + next_free_clu =exfat_find_free_bitmap (sb, trim_end +1 ); +/* +* Stop if the search wrapped around or moved beyond the requested +* FITRIM range. +*/ +if (next_free_clu ==EXFAT_EOF_CLUSTER || + next_free_clu <= trim_end || next_free_clu > clu_end) +break ; - do {if (next_free_clu == trim_end +1 ) {/* extend trim range for continuous free cluster */ trim_end++;
@@ -325,17 +338,11 @@ int exfat_trim_fs(struct inode *inode, struct fstrim_range *range) trim_begin = trim_end = next_free_clu; } -if (next_free_clu >= clu_end) -break ; -if (fatal_signal_pending (current)) { err = -ERESTARTSYS ; goto unlock; } - - next_free_clu =exfat_find_free_bitmap (sb, next_free_clu +1 ); - }while (next_free_clu !=EXFAT_EOF_CLUSTER && - next_free_clu > trim_end); + }/* try to trim remainder */ count = trim_end - trim_begin +1 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 207/2214 libbpf: Fix ring buffer consumer loop on 32-bit position wrap
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Israel Téllez García <[email protected]>
[ Upstream commit fdd4fad0bbbd08501465c5f9b556963093c5d58a ]
ringbuf_process_ring() walks the records between the consumer and the producer with an ordering comparison:
while (cons_pos < prod_pos) {cons_pos and prod_pos mirror the kernel's ring positions and are unsigned long here too, so on 32-bit they wrap at 2^32 bytes of traffic. When producer_pos has wrapped and consumer_pos has not, prod_pos is the smaller of the two, the loop body never runs and no record is consumed. Since consumer_pos only advances inside that loop, it never wraps either and the consumer stops delivering samples for good, with no error returned to the caller: ring_buffer__poll() keeps reporting zero records while the kernel side fills up and starts dropping.
Compare the distance instead. The consumer never runs ahead of the producer, so prod_pos - cons_pos is the amount of unconsumed data and stays correct across the wrap.
64-bit hosts are unaffected in practice: the counters would need 16 EiB to wrap. This is the userspace counterpart of the kernel-side walk fixed in "bpf: Fix pending_pos walk on 32-bit ring position wrap"; a 32-bit consumer hits whichever of the two comes first.
--- tools/lib/bpf/ringbuf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tools/lib/bpf/ringbuf.c +1 -1
@@ -219,7 +219,7 @@ static int64_t ringbuf_process_ring(struct ring* r) do { got_new_data = false; prod_pos = smp_load_acquire(r->producer_pos); - while (cons_pos < prod_pos) { + while (prod_pos - cons_pos > 0) { len_ptr = r->data + (cons_pos & r->mask); len = smp_load_acquire(len_ptr);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 208/2214 ksmbd: protect private extended attributes
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 4ea46ea602fc7055eee4b5b0e84f90f22da7f7e7 ]
SMB clients can currently create an EA named NTACL because SMB EAs are mapped into the user namespace while the ksmbd security descriptor is stored as security.NTACL. Allowing the reserved logical name makes the server-private ACL metadata appear writable through the SMB EA API.
Reject NTACL, DOSATTRIB, and DosStream-prefixed EA names without regard to case. Filter the same private names from EA query results so stale or externally-created user namespace attributes cannot be exposed.
This fixes smb2.ea.acl_xattr when acl_xattr_name is configured as NTACL.
--- fs/ksmbd/smb2pdu.c | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-)
fs/ksmbd/smb2pdu.c +22 -6
@@ -2363,6 +2363,22 @@ static noinline int create_smb2_pipe(struct ksmbd_work *work)return err; } +static bool smb2_is_private_ea (const char *name,size_t name_len) +{ +if (name_len ==SD_PREFIX_LEN && + !strncasecmp (name,SD_PREFIX ,SD_PREFIX_LEN )) +return true; +if (name_len ==DOS_ATTRIBUTE_PREFIX_LEN && + !strncasecmp (name,DOS_ATTRIBUTE_PREFIX , +DOS_ATTRIBUTE_PREFIX_LEN )) +return true; +if (name_len >=STREAM_PREFIX_LEN && + !strncasecmp (name,STREAM_PREFIX ,STREAM_PREFIX_LEN )) +return true; + +return false; +} +/** * smb2_set_ea() - handler for setting extended attributes using set * info command
@@ -2404,6 +2420,10 @@ static int smb2_set_ea(struct smb2_ea_info *eabuf, unsigned int buf_len, rc = -EINVAL ;break ; } +if (smb2_is_private_ea (eabuf->name, eabuf->EaNameLength)) { + rc = -EACCES ; +break ; + }memcpy (attr_name,XATTR_USER_PREFIX ,XATTR_USER_PREFIX_LEN ); memcpy(&attr_name[XATTR_USER_PREFIX_LEN], eabuf->name,
@@ -4432,17 +4452,13 @@ static int smb2_get_ea(struct ksmbd_work *work, struct ksmbd_file *fp,if (strncmp (name,XATTR_USER_PREFIX ,XATTR_USER_PREFIX_LEN ))continue ; -if (!strncmp (&name[XATTR_USER_PREFIX_LEN ],STREAM_PREFIX , -STREAM_PREFIX_LEN )) -continue ; -if (req->InputBufferLength &&strncmp (&name[XATTR_USER_PREFIX_LEN ], ea_req->name, ea_req->EaNameLength))continue ; -if (!strncmp (&name[XATTR_USER_PREFIX_LEN ], -DOS_ATTRIBUTE_PREFIX ,DOS_ATTRIBUTE_PREFIX_LEN )) +if (smb2_is_private_ea (&name[XATTR_USER_PREFIX_LEN ], + name_len -XATTR_USER_PREFIX_LEN ))continue ;if (!strncmp (name,XATTR_USER_PREFIX ,XATTR_USER_PREFIX_LEN ))
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 209/2214 ksmbd: preserve access denied status for copychunk
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit f7c0366e0a80bf8cd5eacc5479927abb50958b5e ]
The copychunk error mapping handles -EACCES in an independent if statement. The following error chain therefore reaches its final else clause and overwrites STATUS_ACCESS_DENIED with STATUS_UNEXPECTED_IO_ERROR.
Join the -EACCES check to the remaining error chain so an access failure is returned as STATUS_ACCESS_DENIED.
--- fs/ksmbd/smb2pdu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/ksmbd/smb2pdu.c +1 -1
@@ -7423,7 +7423,7 @@ static int fsctl_copychunk(struct ksmbd_work *work,if (ret <0 ) {if (ret == -EACCES ) rsp->hdr.Status =STATUS_ACCESS_DENIED ; -if (ret == -EAGAIN ) +else if (ret == -EAGAIN ) rsp->hdr.Status =STATUS_FILE_LOCK_CONFLICT ;else if (ret == -EBADF ) rsp->hdr.Status =STATUS_INVALID_HANDLE ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 210/2214 ksmbd: handle empty QUERY_ALLOCATED_RANGES output
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 7f07791522a251e2be087d11ae9cd51eb3408f1d ]
FSCTL_QUERY_ALLOCATED_RANGES can be issued with a valid input buffer but without room for an output range. Do not reject the request before looking at the file layout. If the query would produce a range, return STATUS_BUFFER_TOO_SMALL. If it produces no ranges, return success with an empty output.
--- fs/ksmbd/smb2pdu.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
fs/ksmbd/smb2pdu.c +12 -4
@@ -7626,8 +7626,6 @@ static int fsctl_query_allocated_ranges(struct ksmbd_work *work, u64 id,int ret =0 ; *out_count =0 ; -if (in_count ==0 ) -return -EINVAL ; start =le64_to_cpu (qar_req->file_offset); length =le64_to_cpu (qar_req->length);
@@ -7639,8 +7637,18 @@ static int fsctl_query_allocated_ranges(struct ksmbd_work *work, u64 id,if (!fp)return -ENOENT ; - ret =ksmbd_vfs_fqar_lseek (fp, start, length, - qar_rsp, in_count, out_count); +if (!in_count) { +struct file_allocated_range_buffer range; + + ret =ksmbd_vfs_fqar_lseek (fp, start, length, &range,1 , + out_count); +if (!ret && *out_count) + ret = -ENOSPC ; + *out_count =0 ; + }else { + ret =ksmbd_vfs_fqar_lseek (fp, start, length, + qar_rsp, in_count, out_count); + }if (ret && ret != -E2BIG ) *out_count =0 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 211/2214 ksmbd: allow FSCTL_SET_SPARSE without input buffer
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 86c84cc760080929b7be44bceebe5854957b99da ]
FSCTL_SET_SPARSE without an input buffer sets a file sparse. Treat a zero-length input buffer as SetSparse=true and keep rejecting truncated non-empty buffers.
--- fs/ksmbd/smb2pdu.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
fs/ksmbd/smb2pdu.c +8 -2
@@ -7928,15 +7928,21 @@ int smb2_ioctl(struct ksmbd_work *work) rsp);break ;case FSCTL_SET_SPARSE : -if (in_buf_len <sizeof (struct file_sparse )) { + { +struct file_sparse sparse = {0 }; + +if (in_buf_len && in_buf_len <sizeof (struct file_sparse )) { ret = -EINVAL ; goto out; } - ret =fsctl_set_sparse (work, id, (struct file_sparse *)buffer); + *(u8 *)&sparse =1 ; + ret =fsctl_set_sparse (work, id, in_buf_len ? + (struct file_sparse *)buffer : &sparse);if (ret <0 ) goto out;break ; + }case FSCTL_SET_ZERO_DATA : {struct file_zero_data_information *zero_data;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 212/2214 ksmbd: skip fallocate for SMB2_CREATE_ALLOCATION_SIZE on a stream handle
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Gael Blivet <[email protected]>
[ Upstream commit bfdf81c62f4f52a3626ea62db0744def6778e83f ]
smb2_open() calls vfs_fallocate(fp->filp, ...) unconditionally when a client's CREATE request includes an AllocationSize create context. For a stream handle, fp->filp refers to the base file's data fork (streams are xattr-backed on the same underlying file, not separate files), so this pre-allocates storage on the base file's actual data instead of doing anything meaningful for the stream -- fallocate has no applicability to an xattr-backed stream at all.
Skip the fallocate call for stream handles.
--- fs/ksmbd/smb2pdu.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-)
fs/ksmbd/smb2pdu.c +16 -7
@@ -3347,13 +3347,22 @@ int smb2_open(struct ksmbd_work *work)ksmbd_debug (SMB ,"request smb2 create allocate size : %llu\n" , alloc_size); -smb_break_all_levII_oplock (work, fp,1 ); - err =vfs_fallocate (fp->filp,FALLOC_FL_KEEP_SIZE ,0 , - alloc_size); -if (err <0 ) -ksmbd_debug (SMB , -"vfs_fallocate is failed : %d\n" , - err); +/* +* fp->filp is the base file's data fork for a stream +* handle (streams are xattr-backed on the same +* underlying file) -- fallocate has no meaning for a +* stream and would otherwise pre-allocate storage on +* the base file's data instead. +*/ +if (!ksmbd_stream_fd (fp)) { +smb_break_all_levII_oplock (work, fp,1 ); + err =vfs_fallocate (fp->filp,FALLOC_FL_KEEP_SIZE ,0 , + alloc_size); +if (err <0 ) +ksmbd_debug (SMB , +"vfs_fallocate is failed : %d\n" , + err); + } } context =smb2_find_context_vals (req,SMB2_CREATE_QUERY_ON_DISK_ID ,4 );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 213/2214 smb/server: cancel async requests when closing connection
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: ChenXiaoSong <[email protected]>
[ Upstream commit 4fd5bad647bfa45eb86bfd2f03ba1bef3fcd5851 ]
An async request may still be waiting when a connection is closed. This can stop the connection from closing.
Cancel active async requests before waiting for them to finish.
--- fs/ksmbd/connection.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+)
fs/ksmbd/connection.c +21 -0
@@ -190,6 +190,26 @@ void ksmbd_conn_try_dequeue_request(struct ksmbd_work *work)wake_up_all (&conn->req_running_q); } +static void ksmbd_conn_cancel_async_requests (struct ksmbd_conn *conn) +{ +struct ksmbd_work *work, *tmp; + +ksmbd_debug (CONN ,"Cancel pending async requests on releasing connection\n" ); +spin_lock (&conn->request_lock); +list_for_each_entry_safe (work, tmp, &conn->async_requests, + async_request_entry) { +if (work->state !=KSMBD_WORK_ACTIVE ) +continue ; + +ksmbd_debug (CONN ,"Cancel async request id %d\n" , + work->async_id); + work->state =KSMBD_WORK_CANCELLED ; +if (work->cancel_fn) + work->cancel_fn (work->cancel_argv); + } +spin_unlock (&conn->request_lock); +} +void ksmbd_conn_lock (struct ksmbd_conn *conn) {mutex_lock (&conn->srv_mutex);
@@ -422,6 +442,7 @@ int ksmbd_conn_handler_loop(void *p) out:ksmbd_conn_set_releasing (conn); +ksmbd_conn_cancel_async_requests (conn);/* Wait till all reference dropped to the Server object*/ wait_event (conn->r_count_q,atomic_read (&conn->r_count) ==0 );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 214/2214 ksmbd: fix SMB2 byte-range lock end offset
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 54d90311f9b4eb23f3b0b62650b0cfddb11a12ef ]
SMB2 describes a byte-range lock using an offset and a length, while Linux file_lock uses an inclusive end offset. smb2_lock() currently sets fl_end to start + length and consequently locks one extra byte for every nonzero-length request.
Translate nonzero lengths to start + length - 1 and reject ranges that cannot be represented by loff_t instead of silently truncating them at OFFSET_MAX. Track zero-length locks from the request length so one-byte ranges are not mistaken for zero-length locks after endpoint conversion.
--- fs/ksmbd/smb2pdu.c | 44 ++++++++++++++------------------------------ 1 file changed, 14 insertions(+), 30 deletions(-)
fs/ksmbd/smb2pdu.c +14 -30
@@ -6938,7 +6938,7 @@ static int smb2_set_flock_flags(struct file_lock *flock, int flags) }static struct ksmbd_lock *smb2_lock_init (struct file_lock *flock, -unsigned int cmd,int flags, +unsigned int cmd,int flags,bool zero_len,struct list_head *lock_list) {struct ksmbd_lock *lock;
@@ -6952,8 +6952,7 @@ static struct ksmbd_lock *smb2_lock_init(struct file_lock *flock, lock->start = flock->fl_start; lock->end = flock->fl_end; lock->flags = flags; -if (lock->start == lock->end) - lock->zero_len =1 ; + lock->zero_len = zero_len;INIT_LIST_HEAD (&lock->clist);INIT_LIST_HEAD (&lock->flist);INIT_LIST_HEAD (&lock->llist);
@@ -7033,32 +7032,18 @@ int smb2_lock(struct ksmbd_work *work) lock_start =le64_to_cpu (lock_ele[i].Offset); lock_length =le64_to_cpu (lock_ele[i].Length); -if (lock_start >U64_MAX - lock_length) { +if (lock_start >OFFSET_MAX || + (lock_length && + lock_length -1 >OFFSET_MAX - lock_start)) {pr_err ("Invalid lock range requested\n" ); rsp->hdr.Status =STATUS_INVALID_LOCK_RANGE ;locks_free_lock (flock); goto out; } -if (lock_start >OFFSET_MAX ) - flock->fl_start =OFFSET_MAX ; -else - flock->fl_start = lock_start; - - lock_length =le64_to_cpu (lock_ele[i].Length); -if (lock_length >OFFSET_MAX - flock->fl_start) - lock_length =OFFSET_MAX - flock->fl_start; - - flock->fl_end = flock->fl_start + lock_length; - -if (flock->fl_end < flock->fl_start) { -ksmbd_debug (SMB , -"the end offset(%llx) is smaller than the start offset(%llx)\n" , - flock->fl_end, flock->fl_start); - rsp->hdr.Status =STATUS_INVALID_LOCK_RANGE ; -locks_free_lock (flock); - goto out; - } + flock->fl_start = lock_start; + flock->fl_end = lock_length ? + flock->fl_start + lock_length -1 : flock->fl_start;/* Check conflict locks in one request */ list_for_each_entry (cmp_lock, &lock_list, llist) {
@@ -7074,7 +7059,8 @@ int smb2_lock(struct ksmbd_work *work) } } - smb_lock =smb2_lock_init (flock, cmd, flags, &lock_list); + smb_lock =smb2_lock_init (flock, cmd, flags, !lock_length, + &lock_list);if (!smb_lock) { err = -EINVAL ;locks_free_lock (flock);
@@ -7148,7 +7134,7 @@ int smb2_lock(struct ksmbd_work *work)/* check zero byte lock range */ if (cmp_lock->zero_len && !smb_lock->zero_len && cmp_lock->start > smb_lock->start && - cmp_lock->start < smb_lock->end) { + cmp_lock->start <= smb_lock->end) {spin_unlock (&conn->llist_lock);up_read (&conn_list_lock);pr_err ("previous lock conflict with zero byte lock range\n" );
@@ -7157,17 +7143,15 @@ int smb2_lock(struct ksmbd_work *work)if (smb_lock->zero_len && !cmp_lock->zero_len && smb_lock->start > cmp_lock->start && - smb_lock->start < cmp_lock->end) { + smb_lock->start <= cmp_lock->end) {spin_unlock (&conn->llist_lock);up_read (&conn_list_lock);pr_err ("current lock conflict with zero byte lock range\n" ); goto out; } -if (((cmp_lock->start <= smb_lock->start && - cmp_lock->end > smb_lock->start) || - (cmp_lock->start < smb_lock->end && - cmp_lock->end >= smb_lock->end)) && +if (cmp_lock->start <= smb_lock->end && + smb_lock->start <= cmp_lock->end && !cmp_lock->zero_len && !smb_lock->zero_len) {spin_unlock (&conn->llist_lock);up_read (&conn_list_lock);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 215/2214 ksmbd: reject blocking compound lock requests
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 16a7f7c2ecf3c893b65f0fb78fa7a7171ae0ba9e ]
Clients set SMB2_LOCKFLAG_FAIL_IMMEDIATELY when a LOCK request contains multiple lock elements, and servers reject requests that omit it. Accepting such a request can leave earlier elements locked while a later element waits asynchronously, enabling prolonged partial lock ownership and avoidable deadlocks.
Return STATUS_INVALID_PARAMETER before processing any element when a multi-element lock request contains a blocking lock. Unlock arrays remain unaffected.
--- fs/ksmbd/smb2pdu.c | 7 +++++++ 1 file changed, 7 insertions(+)
fs/ksmbd/smb2pdu.c +7 -0
@@ -7069,6 +7069,13 @@ int smb2_lock(struct ksmbd_work *work) }list_for_each_entry_safe (smb_lock, tmp, &lock_list, llist) { +if (lock_count >1 && + !(le32_to_cpu (lock_ele[0 ].Flags) &SMB2_LOCKFLAG_UNLOCK ) && + !(smb_lock->flags &SMB2_LOCKFLAG_FAIL_IMMEDIATELY )) { + err = -EINVAL ; + goto out; + } +if (smb_lock->cmd <0 ) { err = -EINVAL ; goto out;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 216/2214 ksmbd: honor client signing-required in all modes
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit bc2f3f3dd69424f76e2ed3dc53d29bfd6c9966d4 ]
The SMB2 NEGOTIATE request's SMB2_NEGOTIATE_SIGNING_REQUIRED bit requires the server to set Connection.ShouldSign. KSMBD represents that state with conn->sign, but previously set it only when its signing configuration was auto or disabled.
Set conn->sign whenever the client requires signing, independently of the server's signing mode. Keep the mandatory server-mode handling unchanged.
--- fs/ksmbd/smb2pdu.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
fs/ksmbd/smb2pdu.c +2 -4
@@ -1257,11 +1257,9 @@ int smb2_handle_negotiate(struct ksmbd_work *work) rsp->SecurityMode =SMB2_NEGOTIATE_SIGNING_ENABLED_LE ; conn->use_spnego = true; -if ((server_conf.signing ==KSMBD_CONFIG_OPT_AUTO || - server_conf.signing ==KSMBD_CONFIG_OPT_DISABLED ) && - req->SecurityMode &SMB2_NEGOTIATE_SIGNING_REQUIRED_LE ) +if (req->SecurityMode &SMB2_NEGOTIATE_SIGNING_REQUIRED_LE ) conn->sign = true; -else if (server_conf.signing ==KSMBD_CONFIG_OPT_MANDATORY ) { +if (server_conf.signing ==KSMBD_CONFIG_OPT_MANDATORY ) { server_conf.enforced_signing = true; rsp->SecurityMode |=SMB2_NEGOTIATE_SIGNING_REQUIRED_LE ; conn->sign = true;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 217/2214 ksmbd: notify parent directory leases on child create
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit abe5acb34282206c2a6303d0e09b3165b1addf0e ]
BVT_DirectoryLeasing_ReadWriteHandleCaching requires a parent directory lease break notification when another client creates a child in the leased directory. A child CREATE without a lease context did not notify the parent lease holders because the notification path expected a non-NULL lease context.
Allow the parent lease notification helper to handle a NULL child lease context and notify matching parent leases. Invoke it after a child is created without a lease context while preserving the existing lease-key filtering for requests that provide one.
--- fs/ksmbd/oplock.c | 9 +++++---- fs/ksmbd/smb2pdu.c | 3 +++ 2 files changed, 8 insertions(+), 4 deletions(-)
fs/ksmbd/oplock.c +5 -4
@@ -1105,7 +1105,7 @@ void smb_send_parent_lease_break_noti(struct ksmbd_file *fp,struct oplock_info *opinfo;struct ksmbd_inode *p_ci =NULL ; -if (lctx->version !=2 ) +if (lctx && lctx->version !=2 )return ; p_ci =ksmbd_inode_lookup_lock (fp->filp->f_path.dentry->d_parent);
@@ -1118,9 +1118,10 @@ void smb_send_parent_lease_break_noti(struct ksmbd_file *fp,continue ;if (opinfo->o_lease->state !=SMB2_OPLOCK_LEVEL_NONE && - (!(lctx->flags &SMB2_LEASE_FLAG_PARENT_LEASE_KEY_SET_LE ) || - !compare_guid_key (opinfo, fp->conn->ClientGUID, - lctx->parent_lease_key))) { + (!lctx || + (!(lctx->flags &SMB2_LEASE_FLAG_PARENT_LEASE_KEY_SET_LE ) || + !compare_guid_key (opinfo, fp->conn->ClientGUID, + lctx->parent_lease_key)))) {if (!atomic_inc_not_zero (&opinfo->refcount))continue ;
fs/ksmbd/smb2pdu.c +3 -0
@@ -3284,6 +3284,9 @@ int smb2_open(struct ksmbd_work *work) goto err_out1; } }else { +if (created && !lc) +smb_send_parent_lease_break_noti (fp,NULL ); +if (req_op_level ==SMB2_OPLOCK_LEVEL_LEASE && lc) {/* * Compare parent lease using parent key. If there is no
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 218/2214 smb: server: Free session data in user_session.c with kfree_sensitive()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Thomas Huth <[email protected]>
[ Upstream commit 9a4bd6507c21f66e84dc021705a4b9d84773111e ]
struct ksmbd_session contains some arrays with sensitive information, like sess_key, smb3encryptionkey, smb3decryptionkey and smb3signingkey. Thus let's make sure that this information cannot leak via the heap and use kfree_sensitive() to free it.
--- fs/ksmbd/mgmt/user_session.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/ksmbd/mgmt/user_session.c +2 -2
@@ -151,10 +151,10 @@ void ksmbd_session_destroy(struct ksmbd_session *sess)ksmbd_destroy_file_table (&sess->file_table);ksmbd_session_rpc_clear_list (sess);free_channel_list (sess); -kfree (sess->Preauth_HashValue); +kfree_sensitive (sess->Preauth_HashValue);ksmbd_release_id (&session_ida, sess->id);ida_destroy (&sess->tree_conn_ida); -kfree (sess); +kfree_sensitive (sess); }static struct ksmbd_session *__session_lookup (unsigned long long id)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 219/2214 net: stmmac: use dma_addr_t for DMA addresses
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Alex Elder <[email protected]>
[ Upstream commit 0c1f9020d2ada55aed8a2e055903ad9cd5d49dab ]
In jumbo_frm() (implemented in both "chain_mode.c" and "ring_mode.c"), an unsigned integer local variable is used to hold the value returned by dma_map_single(). On systems where a dma_addr_t is 64 bits, the subsequent dma_mapping_error() check of the returned value operates only on the low 32 bits (whose high bit won't be sign-extended). In this case, dma_mapping_error() would return 0 (no error) even if there were one.
Fix this in both spots by using a dma_addr_t for the local variable.
--- drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 3 ++- drivers/net/ethernet/stmicro/stmmac/ring_mode.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/net/ethernet/stmicro/stmmac/chain_mode.c +2 -1
@@ -20,9 +20,10 @@ static int jumbo_frm(struct stmmac_tx_queue *tx_q, struct sk_buff *skb,unsigned int nopaged_len =skb_headlen (skb);struct stmmac_priv *priv = tx_q->priv_data;unsigned int entry = tx_q->cur_tx; -unsigned int bmax, buf_len, des2; +unsigned int bmax, buf_len;unsigned int i =1 , len;struct dma_desc *desc; +dma_addr_t des2; desc = tx_q->dma_tx + entry;
drivers/net/ethernet/stmicro/stmmac/ring_mode.c +2 -1
@@ -20,8 +20,9 @@ static int jumbo_frm(struct stmmac_tx_queue *tx_q, struct sk_buff *skb,unsigned int nopaged_len =skb_headlen (skb);struct stmmac_priv *priv = tx_q->priv_data;unsigned int entry = tx_q->cur_tx; -unsigned int bmax, len, des2; +unsigned int bmax, len;struct dma_desc *desc; +dma_addr_t des2;if (priv->extend_desc) desc = (struct dma_desc *)(tx_q->dma_etx + entry);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 220/2214 ASoC: codec: max98926: fixup invert setup mask
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kuninori Morimoto <[email protected]>
[ Upstream commit dd0ae9a2e19a24c532c9aa80a44f572b4907bcdf ]
invert might have both WCI/BCI mask, but regmap_update_bits() masks BCI only. It needs both mask. Fixup it.
static int max98926_dai_set_fmt(...)
{
...
switch (fmt & SND_SOC_DAIFMT_INV_MASK) {
case SND_SOC_DAIFMT_NB_NF:
break;
case SND_SOC_DAIFMT_NB_IF:
=> invert = MAX98926_DAI_WCI_MASK;
break; ^^^^^^^^^^^^^^^^^^^^^
case SND_SOC_DAIFMT_IB_NF:
=> invert = MAX98926_DAI_BCI_MASK;
break; ^^^^^^^^^^^^^^^^^^^^^
case SND_SOC_DAIFMT_IB_IF:
=> invert = MAX98926_DAI_BCI_MASK | MAX98926_DAI_WCI_MASK;
break; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
default:
...
}
...
regmap_update_bits(max98926->regmap, MAX98926_FORMAT,
MAX98926_DAI_BCI_MASK, invert);
... ^^^^^^^^^^^^^^^^^^^^^
}--- sound/soc/codecs/max98926.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/codecs/max98926.c +1 -1
@@ -360,7 +360,7 @@ static int max98926_dai_set_fmt(struct snd_soc_dai *codec_dai,regmap_write (max98926->regmap,MAX98926_FORMAT ,MAX98926_DAI_DLY_MASK );regmap_update_bits (max98926->regmap,MAX98926_FORMAT , -MAX98926_DAI_BCI_MASK , invert); +MAX98926_DAI_BCI_MASK |MAX98926_DAI_WCI_MASK , invert);return 0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 221/2214 virtio_balloon: warn on failed buffer add in tell_host()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Denis V. Lunev <[email protected]>
[ Upstream commit 198eda395067b56ee605de076f0519620f4e5d90 ]
tell_host() ignores the return value of virtqueue_add_outbuf() and goes on to kick the queue and wait_event() for the host's ack. The comment claims "We should always be able to add one buffer to an empty queue", but that does not hold once the virtqueue has been broken (e.g. on device shutdown): the add then fails with -EIO and the following wait_event() would block forever on a buffer the host can never return.
Warn and bail out on failure, mirroring virtballoon_free_page_report().
Message-ID: <[email protected]>
--- drivers/virtio/virtio_balloon.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/virtio/virtio_balloon.c +4 -2
@@ -154,16 +154,18 @@ static void tell_host(struct virtio_balloon *vb, struct virtqueue *vq) {struct scatterlist sg;unsigned int len; +int err;sg_init_one (&sg, vb->pfns,sizeof (vb->pfns[0 ]) * vb->num_pfns);/* We should always be able to add one buffer to an empty queue. */ -virtqueue_add_outbuf (vq, &sg,1 , vb,GFP_KERNEL ); + err =virtqueue_add_outbuf (vq, &sg,1 , vb,GFP_KERNEL ); +if (WARN_ON_ONCE (err)) +return ;virtqueue_kick (vq);/* When host has read buffer, this completes via balloon_ack */ wait_event (vb->acked,virtqueue_get_buf (vq, &len)); - } static int virtballoon_free_page_report(struct page_reporting_dev_info *pr_dev_info,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 222/2214 rtc: ab-eoz9: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman5.15-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 7490b8356e52e09c196645912f2c054f79aa5f3a ]
The driver has a match table for the i2c bus wired into its driver structure, but the table is not exported with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE() entry so module alias information is generated for automatic module loading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the driver registration structure, and the missing module alias publication.
--- drivers/rtc/rtc-ab-eoz9.c | 1 + 1 file changed, 1 insertion(+)
drivers/rtc/rtc-ab-eoz9.c +1 -0
@@ -566,6 +566,7 @@ static const struct i2c_device_id abeoz9_id[] = { { "abeoz9", 0 }, { } }; +MODULE_DEVICE_TABLE(i2c, abeoz9_id); static struct i2c_driver abeoz9_driver = { .driver = {
Signature · 1 line
2.53.0