···159159}160160161161struct mdata_req {162162- struct io_region *where;162162+ struct dm_io_region *where;163163 struct dm_io_request *io_req;164164 struct work_struct work;165165 int result;···177177 */178178static int chunk_io(struct pstore *ps, uint32_t chunk, int rw, int metadata)179179{180180- struct io_region where = {180180+ struct dm_io_region where = {181181 .bdev = ps->snap->cow->bdev,182182 .sector = ps->snap->chunk_size * chunk,183183 .count = ps->snap->chunk_size,
+6-5
drivers/md/dm-io.c
···66 */7788#include "dm-io.h"99+#include "dm.h"9101011#include <linux/bio.h>1112#include <linux/mempool.h>···272271/*-----------------------------------------------------------------273272 * IO routines that accept a list of pages.274273 *---------------------------------------------------------------*/275275-static void do_region(int rw, unsigned int region, struct io_region *where,274274+static void do_region(int rw, unsigned region, struct dm_io_region *where,276275 struct dpages *dp, struct io *io)277276{278277 struct bio *bio;···321320}322321323322static void dispatch_io(int rw, unsigned int num_regions,324324- struct io_region *where, struct dpages *dp,323323+ struct dm_io_region *where, struct dpages *dp,325324 struct io *io, int sync)326325{327326 int i;···348347}349348350349static int sync_io(struct dm_io_client *client, unsigned int num_regions,351351- struct io_region *where, int rw, struct dpages *dp,350350+ struct dm_io_region *where, int rw, struct dpages *dp,352351 unsigned long *error_bits)353352{354353 struct io io;···385384}386385387386static int async_io(struct dm_io_client *client, unsigned int num_regions,388388- struct io_region *where, int rw, struct dpages *dp,387387+ struct dm_io_region *where, int rw, struct dpages *dp,389388 io_notify_fn fn, void *context)390389{391390 struct io *io;···439438 * New collapsed (a)synchronous interface440439 */441440int dm_io(struct dm_io_request *io_req, unsigned num_regions,442442- struct io_region *where, unsigned long *sync_error_bits)441441+ struct dm_io_region *where, unsigned long *sync_error_bits)443442{444443 int r;445444 struct dpages dp;
+12-6
drivers/md/dm-io.h
···11/*22 * Copyright (C) 2003 Sistina Software33+ * Copyright (C) 2004 - 2008 Red Hat, Inc. All rights reserved.44+ *55+ * Device-Mapper low-level I/O.36 *47 * This file is released under the GPL.58 */6977-#ifndef _DM_IO_H88-#define _DM_IO_H1010+#ifndef _LINUX_DM_IO_H1111+#define _LINUX_DM_IO_H9121010-#include "dm.h"1313+#ifdef __KERNEL__11141212-struct io_region {1515+#include <linux/types.h>1616+1717+struct dm_io_region {1318 struct block_device *bdev;1419 sector_t sector;1520 sector_t count; /* If this is zero the region is ignored. */···7974 * error occurred doing io to the corresponding region.8075 */8176int dm_io(struct dm_io_request *io_req, unsigned num_regions,8282- struct io_region *region, unsigned long *sync_error_bits);7777+ struct dm_io_region *region, unsigned long *sync_error_bits);83788484-#endif7979+#endif /* __KERNEL__ */8080+#endif /* _LINUX_DM_IO_H */