Hi,
On 2/13/2024 11:24 AM, Mukesh Ojha wrote:
On 2/13/2024 9:22 AM, Subbaraman Narayanamurthy wrote:
Hi Maulik,
+bool cmd_db_match_resource_addr(u32 addr1, u32 addr2)
+{
<snip>
+ if (SLAVE_ID(addr1) == CMD_DB_HW_VRM
+ && VRM_ADDR(addr1) == VRM_ADDR(addr2))
+ return true;
+ else if (addr1 == addr2)
+ return true;
+ else
+ return false;
Minor..it would be better if you modify it as following.
+ if (addr1 == addr2)
+ return true;
+ else if (SLAVE_ID(addr1) == CMD_DB_HW_VRM
+ && VRM_ADDR(addr1) == VRM_ADDR(addr2))
+ return true;
+
+ return false;
Even better if it becomes one statement for true rest with
false..
Thanks for the review.
I will fix in v4, will wait for sometime if there are any other comments
to take care along with this.
Thanks,
Maulik