Most desktop motherboards can set a custom size for UMA Buffer in BIOS when using a processor with integrated IGP.
If your laptop BIOS doesn't have a setting for UMA Buffer you are probably out of luck. You could try contacting HP Support to see if they offer this.
For the number of graphics processing cores that the IGP offers and the available memory bandwidth, there really isn't a significant performance difference between a UMA Buffer of 512MB and 2GB. My 5700G for example scored by comparison 3DMark Time Spy of 1716 on 512MB and 1733 on 2GB.
Ryzen R7 5700X | B550 Gaming X | 2x16GB G.Skill 3600 | Radeon RX 7900XT
Ryzen R7 5700G | B550 Gaming X | 2x8GB G.Skill 4000 | Radeon Vega 8 IGP
Ryzen R5 5600 | B550 Gaming Edge | 4x8GB G.Skill 3600 | Radeon RX 6800XT