### Function

# FwupdPlugin common_align_up

#### Declaration [src]

    gsize
    fu_common_align_up (
      gsize value,
      guint8 alignment
    )

#### Description [src]

Align a value to a power of 2 boundary, where `alignment` is the bit position to align to. If `alignment` is zero then `value` is always returned unchanged.

Available since: | 1.6.0

#### Parameters

`value` | `gsize`
| Value to align.
`alignment` | `guint8`
| Align to this power of 2, where 0x1F is the maximum value of 2GB.

#### Return value

Returns: | `gsize`
| Aligned value, which will be the same as `value` if already aligned, or `G_MAXSIZE` if the value would overflow.