sendfile: kill generic_file_sendfile()
It's no longer used. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
This commit is contained in:
Родитель
5ffc4ef45b
Коммит
0452a4e5d0
|
@ -1762,7 +1762,6 @@ extern ssize_t generic_file_buffered_write(struct kiocb *, const struct iovec *,
|
||||||
unsigned long, loff_t, loff_t *, size_t, ssize_t);
|
unsigned long, loff_t, loff_t *, size_t, ssize_t);
|
||||||
extern ssize_t do_sync_read(struct file *filp, char __user *buf, size_t len, loff_t *ppos);
|
extern ssize_t do_sync_read(struct file *filp, char __user *buf, size_t len, loff_t *ppos);
|
||||||
extern ssize_t do_sync_write(struct file *filp, const char __user *buf, size_t len, loff_t *ppos);
|
extern ssize_t do_sync_write(struct file *filp, const char __user *buf, size_t len, loff_t *ppos);
|
||||||
extern ssize_t generic_file_sendfile(struct file *, loff_t *, size_t, read_actor_t, void *);
|
|
||||||
extern void do_generic_mapping_read(struct address_space *mapping,
|
extern void do_generic_mapping_read(struct address_space *mapping,
|
||||||
struct file_ra_state *, struct file *,
|
struct file_ra_state *, struct file *,
|
||||||
loff_t *, read_descriptor_t *, read_actor_t);
|
loff_t *, read_descriptor_t *, read_actor_t);
|
||||||
|
|
20
mm/filemap.c
20
mm/filemap.c
|
@ -1245,26 +1245,6 @@ int file_send_actor(read_descriptor_t * desc, struct page *page, unsigned long o
|
||||||
return written;
|
return written;
|
||||||
}
|
}
|
||||||
|
|
||||||
ssize_t generic_file_sendfile(struct file *in_file, loff_t *ppos,
|
|
||||||
size_t count, read_actor_t actor, void *target)
|
|
||||||
{
|
|
||||||
read_descriptor_t desc;
|
|
||||||
|
|
||||||
if (!count)
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
desc.written = 0;
|
|
||||||
desc.count = count;
|
|
||||||
desc.arg.data = target;
|
|
||||||
desc.error = 0;
|
|
||||||
|
|
||||||
do_generic_file_read(in_file, ppos, &desc, actor);
|
|
||||||
if (desc.written)
|
|
||||||
return desc.written;
|
|
||||||
return desc.error;
|
|
||||||
}
|
|
||||||
EXPORT_SYMBOL(generic_file_sendfile);
|
|
||||||
|
|
||||||
static ssize_t
|
static ssize_t
|
||||||
do_readahead(struct address_space *mapping, struct file *filp,
|
do_readahead(struct address_space *mapping, struct file *filp,
|
||||||
unsigned long index, unsigned long nr)
|
unsigned long index, unsigned long nr)
|
||||||
|
|
Загрузка…
Ссылка в новой задаче