hdr->sector = cache_start;
hdr->magic = BOOTCACHE_MAGIC;
hdr->version = BOOTCACHE_VERSION;
- strncpy(hdr->date, __DATE__, sizeof(hdr->date));
- strncpy(hdr->time, __TIME__, sizeof(hdr->time));
hdr->state = BC_INIT;
+ hdr->alignment = PAGE_SIZE;
hdr->max_hw_sectors = queue_max_hw_sectors(bdev_get_queue(bdev));
hdr->max_sectors = queue_max_sectors(bdev_get_queue(bdev));
+ strncpy(hdr->date, __DATE__, sizeof(hdr->date));
+ strncpy(hdr->time, __TIME__, sizeof(hdr->time));
strncpy(hdr->signature, signature, sizeof(hdr->signature));
}
#include <linux/types.h>
enum { BOOTCACHE_MAGIC = 1651470196,
- BOOTCACHE_VERSION = 2,
+ BOOTCACHE_VERSION = 3,
MAX_SIGNATURE = 256
};
__u32 sectors_data; /* Size of the data area in sectors*/
__u32 max_sectors; /* Max sectors that can to read */
__u32 max_hw_sectors; /* Max hardware sectore that can be read */
+ __u32 alignment; /* Alignement on disk */
char date[12]; /* Date and time dm-bootcache was compiled */
char time[12];
char signature[MAX_SIGNATURE];