def padpartion(args, size, partSize, zeros=False):
    """
    Pad give partition up to give size (default 0xFF)
    """

    while True:
        if size < partSize:
            if True == zeros:
                args.output.write(b'\x00')
            else:
                args.output.write(b'\xFF')
            size += 1
        else:
            break  # while loop

    return size