qemu-patch-raspberry4/hw/block-common.h
Markus Armbruster 1f24d7b47e hd-geometry: Switch to uint32_t to match BlockConf
Best to use the same type, to avoid unwanted truncation or sign
extension.

BlockConf can't use plain int for cyls, heads and secs, because
integer properties require an exact width.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2012-07-17 16:48:30 +02:00

23 lines
532 B
C

/*
* Common code for block device models
*
* Copyright (C) 2012 Red Hat, Inc.
* Copyright (c) 2003-2008 Fabrice Bellard
*
* This work is licensed under the terms of the GNU GPL, version 2 or
* later. See the COPYING file in the top-level directory.
*/
#ifndef HW_BLOCK_COMMON_H
#define HW_BLOCK_COMMON_H
#include "qemu-common.h"
/* Hard disk geometry */
void hd_geometry_guess(BlockDriverState *bs,
uint32_t *pcyls, uint32_t *pheads, uint32_t *psecs,
int *ptrans);
#endif