feat(io): add new mmio helper APIs to io.h

These will be required by other drivers such as GICv3 in the upcoming
patches.

Change-Id: Ia3147ba26219299ea308fb3230fbe7acddc3d809
Signed-off-by: Madhukar Pappireddy <madhukar.pappireddy@arm.com>
diff --git a/inc/hf/io.h b/inc/hf/io.h
index d505ced..9a146a2 100644
--- a/inc/hf/io.h
+++ b/inc/hf/io.h
@@ -207,6 +207,21 @@
 	*io.ptr = v;
 }
 
+static inline void io_clrbits32(io32_t io, uint32_t clear)
+{
+	io_write32(io, io_read32(io) & ~clear);
+}
+
+static inline void io_setbits32(io32_t io, uint32_t set)
+{
+	io_write32(io, io_read32(io) | set);
+}
+
+static inline void io_clrsetbits32(io32_t io, uint32_t clear, uint32_t set)
+{
+	io_write32(io, (io_read32(io) & ~clear) | set);
+}
+
 static inline void io_write8_array(io8_array_t io, size_t n, uint8_t v)
 {
 	CHECK(n < io.count);