Merge tag 'firewire-update' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394...
authorLinus Torvalds <torvalds@linux-foundation.org>
Mon, 2 Dec 2019 22:13:00 +0000 (14:13 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 2 Dec 2019 22:13:00 +0000 (14:13 -0800)
Pull FireWire updates from Stefan Richter:

 - another y2038 fix

 - janitorial code movement

* tag 'firewire-update' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394:
  firewire: core: code cleanup after vm_map_pages_zero introduction
  firewire: ohci: stop using get_seconds() for BUS_TIME

drivers/firewire/core-cdev.c
drivers/firewire/core-iso.c
drivers/firewire/core.h
drivers/firewire/ohci.c

index c777088f5828bce4337fce24bc58c1158cfdbf16..6e291d8f3a278556c8d0349b7aed9c8d9e67db9c 100644 (file)
@@ -1686,7 +1686,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;
 
index df8a56a979b996c0c1a48e19c7ef84739b7e2611..185b0b78b3d68c8d9e8b8135d3841a728602b109 100644 (file)
@@ -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)
 {
index 0f0bed3a4bbb8490315b5c6cf0a08436cf16f8e3..4b0e4ee655a191896c2405ae7fbf2db8ac9a64e7 100644 (file)
@@ -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 */
index 522f3addb5bd79b54e1bc78ead5aad17090280b0..33269316f111155dc6cfbb1840db8434bab148ee 100644 (file)
@@ -1752,7 +1752,7 @@ static u32 update_bus_time(struct fw_ohci *ohci)
 
        if (unlikely(!ohci->bus_time_running)) {
                reg_write(ohci, OHCI1394_IntMaskSet, OHCI1394_cycle64Seconds);
-               ohci->bus_time = (lower_32_bits(get_seconds()) & ~0x7f) |
+               ohci->bus_time = (lower_32_bits(ktime_get_seconds()) & ~0x7f) |
                                 (cycle_time_seconds & 0x40);
                ohci->bus_time_running = true;
        }