1. 20 3月, 2015 10 次提交
  2. 19 3月, 2015 7 次提交
  3. 18 3月, 2015 4 次提交
  4. 17 3月, 2015 3 次提交
    • M
      virtio_mmio: fix access width for mmio · 704a0b5f
      Michael S. Tsirkin 提交于
      Going over the virtio mmio code, I noticed that it doesn't correctly
      access modern device config values using "natural" accessors: it uses
      readb to get/set them byte by byte, while the virtio 1.0 spec explicitly states:
      
      	4.2.2.2 Driver Requirements: MMIO Device Register Layout
      
      	...
      
      	The driver MUST only use 32 bit wide and aligned reads and writes to
      	access the control registers described in table 4.1.
      	For the device-specific configuration space, the driver MUST use
      	8 bit wide accesses for 8 bit wide fields, 16 bit wide and aligned
      	accesses for 16 bit wide fields and 32 bit wide and aligned accesses for
      	32 and 64 bit wide fields.
      
      Borrow code from virtio_pci_modern to do this correctly.
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
      704a0b5f
    • M
      bnx2x: fix encapsulation features on 57710/57711 · a8e0c246
      Michal Schmidt 提交于
      E1x chips (57710, 57711(E)) have no support for encapsulation
      offload. bnx2x incorrectly advertises the support as available.
      
      Setting of those features is conditional on "!CHIP_IS_E1x(bp)", but
      the bp struct is not initialized yet at this point and consequently
      any chip passes the check.
      The check must use the "chip_is_e1x" local variable instead to work
      correctly.
      Signed-off-by: NMichal Schmidt <mschmidt@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a8e0c246
    • D
      Revert "Input: synaptics - use dmax in input_mt_assign_slots" · 09d042a2
      Dmitry Torokhov 提交于
      This reverts commit 6ab17a84 since it,
      according to Benjamin, causes issues with slot assignment:
      
      E: 15.669119 0000 0000 0000     # ------------ SYN_REPORT (0) ----------
      E: 15.954242 0003 002f 0000     # EV_ABS / ABS_MT_SLOT          0
      E: 15.954242 0003 0039 0505     # EV_ABS / ABS_MT_TRACKING_ID   505
      E: 15.954242 0003 0035 3851     # EV_ABS / ABS_MT_POSITION_X    3851
      E: 15.954242 0003 0036 4076     # EV_ABS / ABS_MT_POSITION_Y    4076
      E: 15.954242 0003 003a 0034     # EV_ABS / ABS_MT_PRESSURE      34
      E: 15.954242 0001 014a 0001     # EV_KEY / BTN_TOUCH            1
      E: 15.954242 0003 0000 3851     # EV_ABS / ABS_X                3851
      E: 15.954242 0003 0001 4076     # EV_ABS / ABS_Y                4076
      E: 15.954242 0003 0018 0034     # EV_ABS / ABS_PRESSURE         34
      E: 15.954242 0001 0145 0001     # EV_KEY / BTN_TOOL_FINGER      1
      E: 15.954242 0000 0000 0000     # ------------ SYN_REPORT (0) ----------
      ... (bunch of regular events)...
      E: 16.020614 0000 0000 0000     # ------------ SYN_REPORT (0) ----------
      E: 16.043601 0003 0035 3873     # EV_ABS / ABS_MT_POSITION_X    3873
      E: 16.043601 0003 0036 3903     # EV_ABS / ABS_MT_POSITION_Y    3903
      E: 16.043601 0003 003a 0050     # EV_ABS / ABS_MT_PRESSURE      50
      E: 16.043601 0003 0035 3032     # EV_ABS / ABS_MT_POSITION_X    3032
      E: 16.043601 0003 0036 3832     # EV_ABS / ABS_MT_POSITION_Y    3832
      E: 16.043601 0003 003a 0044     # EV_ABS / ABS_MT_PRESSURE      44
      E: 16.043601 0003 0000 3032     # EV_ABS / ABS_X                3032
      E: 16.043601 0003 0001 3832     # EV_ABS / ABS_Y                3832
      E: 16.043601 0003 0018 0044     # EV_ABS / ABS_PRESSURE         44
      E: 16.043601 0001 0145 0000     # EV_KEY / BTN_TOOL_FINGER      0
      E: 16.043601 0001 014d 0001     # EV_KEY / BTN_TOOL_DOUBLETAP   1
      E: 16.043601 0000 0000 0000     # ------------ SYN_REPORT (0) ----------
      E: 16.068837 0003 002f 0001     # EV_ABS / ABS_MT_SLOT          1
      E: 16.068837 0003 0039 0506     # EV_ABS / ABS_MT_TRACKING_ID   506
      E: 16.068837 0003 0035 3912     # EV_ABS / ABS_MT_POSITION_X    3912
      E: 16.068837 0003 0036 3743     # EV_ABS / ABS_MT_POSITION_Y    3743
      E: 16.068837 0003 003a 0056     # EV_ABS / ABS_MT_PRESSURE      56
      E: 16.068837 0003 002f 0000     # EV_ABS / ABS_MT_SLOT          0
      E: 16.068837 0003 0035 3026     # EV_ABS / ABS_MT_POSITION_X    3026
      E: 16.068837 0003 0036 3708     # EV_ABS / ABS_MT_POSITION_Y    3708
      E: 16.068837 0003 003a 0052     # EV_ABS / ABS_MT_PRESSURE      52
      E: 16.068837 0003 0000 3026     # EV_ABS / ABS_X                3026
      E: 16.068837 0003 0001 3708     # EV_ABS / ABS_Y                3708
      E: 16.068837 0003 0018 0052     # EV_ABS / ABS_PRESSURE         52
      E: 16.068837 0000 0000 0000     # ------------ SYN_REPORT (0) ----------
      
      Slot 0 and 1 gets inverted in the second report above, which
      introduces a cursor jump. The problem is that this cursor jump is
      often enough to leave the current widget, and X sends the
      scrolling events to whoever is now under the cursor.
      Reported-by: NBenjamin Tissoires <btissoir@redhat.com>
      Reported-by: NHans de Goede <hdegoede@redhat.com>
      09d042a2
  5. 16 3月, 2015 3 次提交
  6. 15 3月, 2015 1 次提交
  7. 14 3月, 2015 5 次提交
  8. 13 3月, 2015 4 次提交
    • M
      virtio_mmio: generation support · 87e7bf14
      Michael S. Tsirkin 提交于
      virtio_mmio currently lacks generation support which
      makes multi-byte field access racy.
      Fix by getting the value at offset 0xfc for version 2
      devices. Nothing we can do for version 1, so return
      generation id 0.
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
      87e7bf14
    • M
      virtio_rpmsg: set DRIVER_OK before using device · 71e4b8bf
      Michael S. Tsirkin 提交于
      virtio spec requires that all drivers set DRIVER_OK
      before using devices. While rpmsg isn't yet
      included in the virtio 1 spec, previous spec versions
      also required this.
      
      virtio rpmsg violates this rule: is calls kick
      before setting DRIVER_OK.
      
      The fix isn't trivial since simply calling virtio_device_ready earlier
      would mean we might get an interrupt in parallel with adding buffers.
      
      Instead, split kick out to prepare+notify calls.  prepare before
      virtio_device_ready - when we know we won't get interrupts. notify right
      afterwards.
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      Acked-by: NOhad Ben-Cohen <ohad@wizery.com>
      Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
      71e4b8bf
    • J
      drivers/rtc/rtc-s3c.c: add .needs_src_clk to s3c6410 RTC data · 8792f777
      Javier Martinez Canillas 提交于
      Commit df9e26d0 ("rtc: s3c: add support for RTC of Exynos3250 SoC")
      added an "rtc_src" DT property to specify the clock used as a source to
      the S3C real-time clock.
      
      Not all SoCs needs this so commit eaf3a659 ("drivers/rtc/rtc-s3c.c:
      fix initialization failure without rtc source clock") changed to check
      the struct s3c_rtc_data .needs_src_clk to conditionally grab the clock.
      
      But that commit didn't update the data for each IP version so the RTC
      broke on the boards that needs a source clock. This is the case of at
      least Exynos5250 and Exynos5440 which uses the s3c6410 RTC IP block.
      
      This commit fixes the S3C rtc on the Exynos5250 Snow and Exynos5420
      Peach Pit and Pi Chromebooks.
      Signed-off-by: NJavier Martinez Canillas <javier.martinez@collabora.co.uk>
      Cc: Marek Szyprowski <m.szyprowski@samsung.com>
      Cc: Chanwoo Choi <cw00.choi@samsung.com>
      Cc: Doug Anderson <dianders@chromium.org>
      Cc: Olof Johansson <olof@lixom.net>
      Cc: Kevin Hilman <khilman@linaro.org>
      Cc: Tyler Baker <tyler.baker@linaro.org>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      8792f777
    • J
      virtio-net: correctly delete napi hash · ab3971b1
      Jason Wang 提交于
      We don't delete napi from hash list during module exit. This will
      cause the following panic when doing module load and unload:
      
      BUG: unable to handle kernel paging request at 0000004e00000075
      IP: [<ffffffff816bd01b>] napi_hash_add+0x6b/0xf0
      PGD 3c5d5067 PUD 0
      Oops: 0000 [#1] SMP
      ...
      Call Trace:
      [<ffffffffa0a5bfb7>] init_vqs+0x107/0x490 [virtio_net]
      [<ffffffffa0a5c9f2>] virtnet_probe+0x562/0x791815639d880be [virtio_net]
      [<ffffffff8139e667>] virtio_dev_probe+0x137/0x200
      [<ffffffff814c7f2a>] driver_probe_device+0x7a/0x250
      [<ffffffff814c81d3>] __driver_attach+0x93/0xa0
      [<ffffffff814c8140>] ? __device_attach+0x40/0x40
      [<ffffffff814c6053>] bus_for_each_dev+0x63/0xa0
      [<ffffffff814c7a79>] driver_attach+0x19/0x20
      [<ffffffff814c76f0>] bus_add_driver+0x170/0x220
      [<ffffffffa0a60000>] ? 0xffffffffa0a60000
      [<ffffffff814c894f>] driver_register+0x5f/0xf0
      [<ffffffff8139e41b>] register_virtio_driver+0x1b/0x30
      [<ffffffffa0a60010>] virtio_net_driver_init+0x10/0x12 [virtio_net]
      
      This patch fixes this by doing this in virtnet_free_queues(). And also
      don't delete napi in virtnet_freeze() since it will call
      virtnet_free_queues() which has already did this.
      
      Fixes 91815639 ("virtio-net: rx busy polling support")
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Michael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NJason Wang <jasowang@redhat.com>
      Acked-by: NMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ab3971b1
  9. 12 3月, 2015 3 次提交