Commit 7807759e authored by Stefan Richter's avatar Stefan Richter
Browse files

firewire: core: code cleanup after vm_map_pages_zero introduction



Commit 22660db8 turned fw_iso_buffer_map_vma into a one-liner.
There is no need to keep this in the core-iso.c collection of buffer
management functions; put it inline into the sole user, the character
device file driver.

Signed-off-by: default avatarStefan Richter <stefanr@s5r6.in-berlin.de>
parent b98c7518
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1694,7 +1694,8 @@ static int fw_device_op_mmap(struct file *file, struct vm_area_struct *vma)
	if (ret < 0)
		goto fail;

	ret = fw_iso_buffer_map_vma(&client->buffer, vma);
	ret = vm_map_pages_zero(vma, client->buffer.pages,
				client->buffer.page_count);
	if (ret < 0)
		goto fail;

+0 −7
Original line number Diff line number Diff line
@@ -91,13 +91,6 @@ int fw_iso_buffer_init(struct fw_iso_buffer *buffer, struct fw_card *card,
}
EXPORT_SYMBOL(fw_iso_buffer_init);

int fw_iso_buffer_map_vma(struct fw_iso_buffer *buffer,
			  struct vm_area_struct *vma)
{
	return vm_map_pages_zero(vma, buffer->pages,
					buffer->page_count);
}

void fw_iso_buffer_destroy(struct fw_iso_buffer *buffer,
			   struct fw_card *card)
{
+0 −2
Original line number Diff line number Diff line
@@ -158,8 +158,6 @@ void fw_node_event(struct fw_card *card, struct fw_node *node, int event);
int fw_iso_buffer_alloc(struct fw_iso_buffer *buffer, int page_count);
int fw_iso_buffer_map_dma(struct fw_iso_buffer *buffer, struct fw_card *card,
			  enum dma_data_direction direction);
int fw_iso_buffer_map_vma(struct fw_iso_buffer *buffer,
			  struct vm_area_struct *vma);


/* -topology */