/usr/include/libdfu/dfu-sector.h is in libdfu-dev 0.7.0-0ubuntu4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
*
* Copyright (C) 2015 Richard Hughes <richard@hughsie.com>
*
* Licensed under the GNU Lesser General Public License Version 2.1
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef __DFU_SECTOR_H
#define __DFU_SECTOR_H
#include <glib-object.h>
#include <gio/gio.h>
G_BEGIN_DECLS
#define DFU_TYPE_SECTOR (dfu_sector_get_type ())
G_DECLARE_DERIVABLE_TYPE (DfuSector, dfu_sector, DFU, SECTOR, GObject)
struct _DfuSectorClass
{
GObjectClass parent_class;
/*< private >*/
/* Padding for future expansion */
void (*_dfu_sector_reserved1) (void);
void (*_dfu_sector_reserved2) (void);
void (*_dfu_sector_reserved3) (void);
void (*_dfu_sector_reserved4) (void);
void (*_dfu_sector_reserved5) (void);
void (*_dfu_sector_reserved6) (void);
void (*_dfu_sector_reserved7) (void);
void (*_dfu_sector_reserved8) (void);
void (*_dfu_sector_reserved9) (void);
};
/**
* DfuSectorCap:
* @DFU_SECTOR_CAP_NONE: No operations possible
* @DFU_SECTOR_CAP_READABLE: Sector can be read
* @DFU_SECTOR_CAP_WRITEABLE: Sector can be written
* @DFU_SECTOR_CAP_ERASEABLE: Sector can be erased
*
* The flags indicating what the sector can do.
**/
typedef enum {
DFU_SECTOR_CAP_NONE = 0,
DFU_SECTOR_CAP_READABLE = 1 << 0,
DFU_SECTOR_CAP_WRITEABLE = 1 << 1,
DFU_SECTOR_CAP_ERASEABLE = 1 << 2,
/*< private >*/
DFU_SECTOR_CAP_LAST
} DfuSectorCap;
guint32 dfu_sector_get_id (DfuSector *sector);
guint32 dfu_sector_get_address (DfuSector *sector);
guint32 dfu_sector_get_size (DfuSector *sector);
guint32 dfu_sector_get_size_left (DfuSector *sector);
gboolean dfu_sector_has_cap (DfuSector *sector,
DfuSectorCap cap);
gchar *dfu_sector_to_string (DfuSector *sector);
G_END_DECLS
#endif /* __DFU_SECTOR_H */
|