1. 17 Jun, 2014 21 commits
    • Alexander Shiyan's avatar
      [media] media: mx2_camera: Change Kconfig dependency · 50f06b88
      Alexander Shiyan authored
      This patch change MACH_MX27 dependency to SOC_IMX27 for MX2 camera
      driver, since MACH_MX27 symbol is scheduled for removal.
      Signed-off-by: default avatarAlexander Shiyan <shc_work@mail.ru>
      Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      50f06b88
    • Alexander Shiyan's avatar
      [media] media: mx1_camera: Remove driver · 90b05589
      Alexander Shiyan authored
      That driver hasn't been really maintained for a long time. It doesn't
      compile in any way, it includes non-existent headers, has no users,
      and marked as "BROKEN" more than year. Due to these factors, mx1_camera
      is now removed from the tree.
      Signed-off-by: default avatarAlexander Shiyan <shc_work@mail.ru>
      Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      90b05589
    • Jean Delvare's avatar
      [media] V4L2: soc_camera: add run-time dependencies to R-Car VIN driver · 0b911999
      Jean Delvare authored
      The R-Car Video Input driver is only useful on shmobile unless build
      testing.
      Signed-off-by: default avatarJean Delvare <jdelvare@suse.de>
      Cc: Vladimir Barinov <vladimir.barinov@cogentembedded.com>
      Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
      Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      0b911999
    • Ben Dooks's avatar
      [media] rcar_vin: copy flags from pdata · 25dfa02c
      Ben Dooks authored
      The platform data is a single word, so simply copy
      it into the device's private data structure than
      keeping a copy of the pointer.
      
      This will make changing to device-tree binding
      easier as it is one allocation instead of two.
      Signed-off-by: default avatarBen Dooks <ben.dooks@codethink.co.uk>
      Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      25dfa02c
    • Guennadi Liakhovetski's avatar
      [media] V4L: soc-camera: explicitly free allocated managed memory on error · 057c2a2e
      Guennadi Liakhovetski authored
      devm_kzalloc() allocations are freed when the device is unbound. But if a
      certain path fails and the allocated memory cannot be used anyway it is
      better to free it explicitly immediately. This patch does exactly this if
      asynchronous group probing in scan_async_group() fails after memory has
      been allocated.
      Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      057c2a2e
    • Mauro Carvalho Chehab's avatar
      [media] dib7000p: Callibrate signal strength · 3926d91a
      Mauro Carvalho Chehab authored
      Calibrate the signal strength to dB.
      
      For this callibration, I used adapter 0 (antenna 1), connected
      via a normal cable to a DTF-2111 generator.
      
      The same cabling and RF generator connected to adapter 1
      (antenna 2) has a difference of +3dBm (signal was stronger
      there).
      
      Yet, changing the RF for a difference of, let's say, 6dB
      reflected on a 6dB difference at the measured signal, with
      is good.
      
      So, the signal strengh can indeed be used to measure the
      antenna gain, if the antenna is repositioned. It is
      not precise to measure the absolute dBm value, however.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      3926d91a
    • Mauro Carvalho Chehab's avatar
      [media] dib7000p: Add DVBv5 stats support · 041ad449
      Mauro Carvalho Chehab authored
      Adds DVBv5 stats support. For now, just mimic whatever dib8000
      does, as they're very similar, with regards to statistics.
      
      However, dib7000p_get_time_us() likely require some
      adjustments, as I didn't actually reviewed the formula
      for it to work with DVB-T. Still, better than nothing,
      as latter patches can improve it.
      
      This patch also doesn't show the signal strength in dB
      yet. The code is already there, but it requires to be
      callibrated.
      
      A latter patch will do the calibration.
      
      It seems that this patch is also a bug fix: Before this
      patch, the frontend were not tuning with some userspace
      tools. I suspect that dib7000p firmware or hardware
      internally expects that the statistics to be collected,
      in order for it to work. With this patch, the DVB core
      will always retrive statistics, even if userspace doesn't
      request. So, it makes the device work on all tested apps.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      041ad449
    • Mauro Carvalho Chehab's avatar
      [media] dib8000: export just one symbol · d44913c1
      Mauro Carvalho Chehab authored
      Exporting multiple symbols don't work as it causes compilation
      breakages, due to the way dvb_attach() works.
      
      The bug happens when:
              CONFIG_DVB_DIB8000=m
      	CONFIG_DVB_USB_DIB0700=y
      
      As a bonus, dib8000 won't be loaded anymore if the device uses
      a different frontend, reducing the memory footprint.
      
      Tested with both Pixelview PV-D231 and MyGica S870.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      d44913c1
    • Mauro Carvalho Chehab's avatar
      [media] dib8000: rename dib8000_attach to dib8000_init · b9bc7d59
      Mauro Carvalho Chehab authored
      Well, what we call as "foo_attach" is the method that should
      be called by the dvb_attach() macro.
      
      It should be noticed that the name "dvb_attach" is really a
      bad name and don't express what it does.
      
      dvb_attach() basically does three things, if the frontend is
      compiled as a module:
      - It lookups for the module that it is known to have the
        given symbol name and requests such module;
      - It increments the module usage (anonymously - so lsmod
        doesn't print who loaded the module);
      - after loading the module, it runs the function associated
        with the dynamic symbol.
      
      When compiled as builtin, it just calls the function given to it.
      
      As dvb_attach() increments refcount, it can't be (easily)
      called more than once for the same module, or the kernel
      will deny to remove the module, because refcount will never
      be zeroed.
      
      In other words, the function name given to dvb_attach()
      should be one single symbol that will always be called
      before any other function on that module to be used.
      
      For almost all DVB frontends, there's just one function,
      but, on dib8000, there are several exported symbols.
      
      We need to get rid of all those direct calls, because they
      cause compilation breakages when bridge is builtin and
      frontend is module, we'll need to add a new function that
      will be the first one to be called, whatever initialization
      is needed.
      
      So, let's rename this function, in order to prepare for
      a next patch that will add a new attach() function that
      will be the only one exported by this module.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      b9bc7d59
    • Mauro Carvalho Chehab's avatar
      [media] dib7000: export just one symbol · 8abe4a0a
      Mauro Carvalho Chehab authored
      Exporting multiple symbols don't work as it causes compilation
      breakages, due to the way dvb_attach() works.
      
      This were reported several times, like:
      
         drivers/built-in.o: In function `cxusb_dualdig4_rev2_tuner_attach':
      >> cxusb.c:(.text+0x27d4b5): undefined reference to `dib7000p_get_i2c_master'
         drivers/built-in.o: In function `dib7070_set_param_override':
         cxusb.c:(.text+0x27d5a5): undefined reference to `dib0070_wbd_offset'
      >> cxusb.c:(.text+0x27d5be): undefined reference to `dib7000p_set_wbd_ref'
         drivers/built-in.o: In function `dib7070_tuner_reset':
      >> cxusb.c:(.text+0x27d5f9): undefined reference to `dib7000p_set_gpio'
         drivers/built-in.o: In function `cxusb_dualdig4_rev2_frontend_attach':
      >> cxusb.c:(.text+0x27df5c): undefined reference to `dib7000p_i2c_enumeration'
      
      In this specific report:
      	CONFIG_DVB_USB_CXUSB=y
      	CONFIG_DVB_DIB7000P=m
      
      But the same type of bug can happen if:
      	CONFIG_DVB_DIB7000P=m
      and one of the bridge drivers is compiled builtin (cxusb, cx23885-dvb
      and/or dib0700).
      
      As a bonus, dib7000p won't be loaded anymore if the device uses
      a different frontend, reducing the memory footprint.
      
      Tested with Hauppauge Nova-TD (2 frontends).
      Reported-by: default avatarFengguang Wu <fengguang.wu@intel.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      8abe4a0a
    • Mauro Carvalho Chehab's avatar
      [media] dib7000p: rename dib7000p_attach to dib7000p_init · 7f67d96a
      Mauro Carvalho Chehab authored
      Well, what we call as "foo_attach" is the method that should
      be called by the dvb_attach() macro.
      
      It should be noticed that the name "dvb_attach" is really a
      bad name and don't express what it does.
      
      dvb_attach() basically does three things, if the frontend is
      compiled as a module:
      - It lookups for the module that it is known to have the
        given symbol name and requests such module;
      - It increments the module usage (anonymously - so lsmod
        doesn't print who loaded the module);
      - after loading the module, it runs the function associated
        with the dynamic symbol.
      
      When compiled as builtin, it just calls the function given to it.
      
      As dvb_attach() increments refcount, it can't be (easily)
      called more than once for the same module, or the kernel
      will deny to remove the module, because refcount will never
      be zeroed.
      
      In other words, the function name given to dvb_attach()
      should be one single symbol that will always be called
      before any other function on that module to be used.
      
      For almost all DVB frontends, there's just one function.
      
      However, the dib7000p initialization can require up to 3
      functions to be called:
      	- dib7000p_get_i2c_master;
      	- dib7000p_i2c_enumeration;
      	- dib7000p_init (before this patch dib7000_attach).
      
      (plus a bunch of other functions that the bridge driver will
      need to call).
      
      As we need to get rid of all those direct calls, because they
      cause compilation breakages when bridge is builtin and
      frontend is module, we'll need to add a new function that
      will be the first one to be called, whatever initialization
      is needed.
      
      So, let's rename the function that probes and init the hardware
      to dib7000p_init.
      
      A latter patch will add a new dib7000p_attach that will be
      used as originally conceived by dvb_attach() way.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      7f67d96a
    • Mauro Carvalho Chehab's avatar
      [media] dvbdev: add a dvb_detach() macro · 4647f487
      Mauro Carvalho Chehab authored
      The dvb_attach() was unbalanced, as there was no dvb_dettach. Ok,
      on current cases, the dettach is done by dvbdev, but that are some
      future corner cases where we may need to do this before registering
      the frontend.
      
      So, add a dvb_detach() and use it at dvb_frontend.c.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      4647f487
    • Malcolm Priestley's avatar
      [media] lmedm04: rs2000 check if interrupt urb is over due · 3a370222
      Malcolm Priestley authored
      Change handling of signal_lock on rs2000. Use ibuf[2] to detect
      lock as there is a longer wait for lock to appear in ibuf[6].
      
      Remove last_key and key_timeout and use jiffies plus 60ms
      to detect that streaming is still active.
      
      If the current jiffies is time_after the interrupt urb overdue and
      clear signal lock.
      
      This results in far faster recovery of lock and streaming.
      Signed-off-by: default avatarMalcolm Priestley <tvboxspy@gmail.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      3a370222
    • Alexander Shiyan's avatar
      [media] m2m-deinterlace: Convert to devm* API · 3c1e7f27
      Alexander Shiyan authored
      Replace resource handling in the driver with managed device resource.
      Signed-off-by: default avatarAlexander Shiyan <shc_work@mail.ru>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      3c1e7f27
    • Alexey Khoroshilov's avatar
      [media] usbtv: fix leak at failure path in usbtv_probe() · ebdae650
      Alexey Khoroshilov authored
      Error handling code in usbtv_probe() misses usb_put_dev().
      
      Found by Linux Driver Verification project (linuxtesting.org).
      Signed-off-by: default avatarAlexey Khoroshilov <khoroshilov@ispras.ru>
      Acked-by: default avatarLubomir Rintel <lkundrak@v3.sk>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      ebdae650
    • Sakari Ailus's avatar
      [media] smiapp: I2C address is the last part of the subdev name · f8d36b89
      Sakari Ailus authored
      The I2C address of the sensor device was in the middle of the sub-device
      name and not in the end as it should have been. The smiapp sub-device names
      will change from e.g. "vs6555 1-0010 pixel array" to "vs6555 pixel array
      1-0010".
      Signed-off-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      f8d36b89
    • Lad, Prabhakar's avatar
      [media] media: davinci: vpif_capture: fix v4l-compliance issues · a4965c59
      Lad, Prabhakar authored
      This patch does the following:
      
      1: sets initial default format during probe.
      2: removes spurious messages.
      3: optimize vpif_s/try_fmt_vid_out code.
      Signed-off-by: default avatarLad, Prabhakar <prabhakar.csengg@gmail.com>
      Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      a4965c59
    • Lad, Prabhakar's avatar
      [media] media: davinci: vpif_capture: drop unneeded module params · 4015bef6
      Lad, Prabhakar authored
      Remove bogus 'numbuffers' and 'bufsize' module options. The number of buffers and
      buffer sizes are determined by VIDIOC_REQBUFS and VIDIOC_S_FMT and the amount of
      available memory (in the case of the MMAP stream I/O mode) and not by module
      options.
      
      These module params are a left-over from the original montavista code that used
      these parameters to pre-allocate the memory needed for the buffers. The code that
      allocated those buffers was never upstreamed since by the time the drivers were
      added to the kernel the TI cmem module could be used in combination with the
      USERPTR mode to reserve and pass physically contiguous memory pointers around.
      
      These days of course CMA is used instead of cmem.
      
      This patch removes these module options altogether since they no longer do what
      they originally were designed for. They should never have been part of the
      upstreamed code in the first place, so they've been pointless ever since
      2.6.32 when this driver first appeared in the mainline kernel.
      Signed-off-by: default avatarLad, Prabhakar <prabhakar.csengg@gmail.com>
      Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      4015bef6
    • Mauro Carvalho Chehab's avatar
      [media] drxd: get rid of EXPORT_SYMBOL(drxd_config_i2c) · 619c027d
      Mauro Carvalho Chehab authored
      This symbol is not used externally. Get rid of it.
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      619c027d
    • Laurent Pinchart's avatar
      [media] v4l: vsp1: Remove the unneeded vsp1_video_buffer video field · e51daefc
      Laurent Pinchart authored
      The field is assigned but never read, remove it.
      
      This fixes a bug caused by the struct vb2_buffer field not being be the
      very first field of the vsp1_video_buffer buffer structure as required
      by videobuf2.
      
      Cc: stable@vger.kernel.org
      Reported-by: default avatarTakanari Hayama <taki@igel.co.jp>
      Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
      e51daefc
    • Mauro Carvalho Chehab's avatar
      Merge tag 'v3.16-rc1' into patchwork · 50e59058
      Mauro Carvalho Chehab authored
      Linux 3.16-rc1
      
      * tag 'v3.16-rc1': (11443 commits)
        Linux 3.16-rc1
        net: sctp: fix permissions for rto_alpha and rto_beta knobs
        vxlan: Checksum fixes
        net: add skb_pop_rcv_encapsulation
        udp: call __skb_checksum_complete when doing full checksum
        net: Fix save software checksum complete
        net: Fix GSO constants to match NETIF flags
        fix __swap_writepage() compile failure on old gcc versions
        udp: ipv4: do not waste time in __udp4_lib_mcast_demux_lookup
        vxlan: use dev->needed_headroom instead of dev->hard_header_len
        MAINTAINERS: update cxgb4 maintainer
        x86/vdso: Fix vdso_install
        NVMe: Fix START_STOP_UNIT Scsi->NVMe translation.
        btrfs: fix error handling in create_pending_snapshot
        btrfs: fix use of uninit "ret" in end_extent_writepage()
        btrfs: free ulist in qgroup_shared_accounting() error path
        Btrfs: fix qgroups sanity test crash or hang
        btrfs: prevent RCU warning when dereferencing radix tree slot
        Btrfs: fix unfinished readahead thread for raid5/6 degraded mounting
        btrfs: new ioctl TREE_SEARCH_V2
        ...
      50e59058
  2. 16 Jun, 2014 4 commits
    • Linus Torvalds's avatar
      Linux 3.16-rc1 · 7171511e
      Linus Torvalds authored
      7171511e
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · a9be2242
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) Fix checksumming regressions, from Tom Herbert.
      
       2) Undo unintentional permissions changes for SCTP rto_alpha and
          rto_beta sysfs knobs, from Denial Borkmann.
      
       3) VXLAN, like other IP tunnels, should advertize it's encapsulation
          size using dev->needed_headroom instead of dev->hard_header_len.
          From Cong Wang.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
        net: sctp: fix permissions for rto_alpha and rto_beta knobs
        vxlan: Checksum fixes
        net: add skb_pop_rcv_encapsulation
        udp: call __skb_checksum_complete when doing full checksum
        net: Fix save software checksum complete
        net: Fix GSO constants to match NETIF flags
        udp: ipv4: do not waste time in __udp4_lib_mcast_demux_lookup
        vxlan: use dev->needed_headroom instead of dev->hard_header_len
        MAINTAINERS: update cxgb4 maintainer
      a9be2242
    • Linus Torvalds's avatar
      Merge tag 'clk-for-linus-3.16-part2' of git://git.linaro.org/people/mike.turquette/linux · dd1845af
      Linus Torvalds authored
      Pull more clock framework updates from Mike Turquette:
       "This contains the second half the of the clk changes for 3.16.
      
        They are simply fixes and code refactoring for the OMAP clock drivers.
        The sunxi clock driver changes include splitting out the one
        mega-driver into several smaller pieces and adding support for the A31
        SoC clocks"
      
      * tag 'clk-for-linus-3.16-part2' of git://git.linaro.org/people/mike.turquette/linux: (25 commits)
        clk: sunxi: document PRCM clock compatible strings
        clk: sunxi: add PRCM (Power/Reset/Clock Management) clks support
        clk: sun6i: Protect SDRAM gating bit
        clk: sun6i: Protect CPU clock
        clk: sunxi: Rework clock protection code
        clk: sunxi: Move the GMAC clock to a file of its own
        clk: sunxi: Move the 24M oscillator to a file of its own
        clk: sunxi: Remove calls to clk_put
        clk: sunxi: document new A31 USB clock compatible
        clk: sunxi: Implement A31 USB clock
        ARM: dts: OMAP5/DRA7: use omap5-mpu-dpll-clock capable of dealing with higher frequencies
        CLK: TI: dpll: support OMAP5 MPU DPLL that need special handling for higher frequencies
        ARM: OMAP5+: dpll: support Duty Cycle Correction(DCC)
        CLK: TI: clk-54xx: Set the rate for dpll_abe_m2x2_ck
        CLK: TI: Driver for DRA7 ATL (Audio Tracking Logic)
        dt:/bindings: DRA7 ATL (Audio Tracking Logic) clock bindings
        ARM: dts: dra7xx-clocks: Correct name for atl clkin3 clock
        CLK: TI: gate: add composite interface clock to OMAP2 only build
        ARM: OMAP2: clock: add DT boot support for cpufreq_ck
        CLK: TI: OMAP2: add clock init support
        ...
      dd1845af
    • Linus Torvalds's avatar
      Merge git://git.infradead.org/users/willy/linux-nvme · b55b3902
      Linus Torvalds authored
      Pull NVMe update from Matthew Wilcox:
       "Mostly bugfixes again for the NVMe driver.  I'd like to call out the
        exported tracepoint in the block layer; I believe Keith has cleared
        this with Jens.
      
        We've had a few reports from people who're really pounding on NVMe
        devices at scale, hence the timeout changes (and new module
        parameters), hotplug cpu deadlock, tracepoints, and minor performance
        tweaks"
      
      [ Jens hadn't seen that tracepoint thing, but is ok with it - it will
        end up going away when mq conversion happens ]
      
      * git://git.infradead.org/users/willy/linux-nvme: (22 commits)
        NVMe: Fix START_STOP_UNIT Scsi->NVMe translation.
        NVMe: Use Log Page constants in SCSI emulation
        NVMe: Define Log Page constants
        NVMe: Fix hot cpu notification dead lock
        NVMe: Rename io_timeout to nvme_io_timeout
        NVMe: Use last bytes of f/w rev SCSI Inquiry
        NVMe: Adhere to request queue block accounting enable/disable
        NVMe: Fix nvme get/put queue semantics
        NVMe: Delete NVME_GET_FEAT_TEMP_THRESH
        NVMe: Make admin timeout a module parameter
        NVMe: Make iod bio timeout a parameter
        NVMe: Prevent possible NULL pointer dereference
        NVMe: Fix the buffer size passed in GetLogPage(CDW10.NUMD)
        NVMe: Update data structures for NVMe 1.2
        NVMe: Enable BUILD_BUG_ON checks
        NVMe: Update namespace and controller identify structures to the 1.1a spec
        NVMe: Flush with data support
        NVMe: Configure support for block flush
        NVMe: Add tracepoints
        NVMe: Protect against badly formatted CQEs
        ...
      b55b3902
  3. 15 Jun, 2014 11 commits
    • Daniel Borkmann's avatar
      net: sctp: fix permissions for rto_alpha and rto_beta knobs · b58537a1
      Daniel Borkmann authored
      Commit 3fd091e7 ("[SCTP]: Remove multiple levels of msecs
      to jiffies conversions.") has silently changed permissions for
      rto_alpha and rto_beta knobs from 0644 to 0444. The purpose of
      this was to discourage users from tweaking rto_alpha and
      rto_beta knobs in production environments since they are key
      to correctly compute rtt/srtt.
      
      RFC4960 under section 6.3.1. RTO Calculation says regarding
      rto_alpha and rto_beta under rule C3 and C4:
      
        [...]
        C3)  When a new RTT measurement R' is made, set
      
             RTTVAR <- (1 - RTO.Beta) * RTTVAR + RTO.Beta * |SRTT - R'|
      
             and
      
             SRTT <- (1 - RTO.Alpha) * SRTT + RTO.Alpha * R'
      
             Note: The value of SRTT used in the update to RTTVAR
             is its value before updating SRTT itself using the
             second assignment. After the computation, update
             RTO <- SRTT + 4 * RTTVAR.
      
        C4)  When data is in flight and when allowed by rule C5
             below, a new RTT measurement MUST be made each round
             trip. Furthermore, new RTT measurements SHOULD be
             made no more than once per round trip for a given
             destination transport address. There are two reasons
             for this recommendation: First, it appears that
             measuring more frequently often does not in practice
             yield any significant benefit [ALLMAN99]; second,
             if measurements are made more often, then the values
             of RTO.Alpha and RTO.Beta in rule C3 above should be
             adjusted so that SRTT and RTTVAR still adjust to
             changes at roughly the same rate (in terms of how many
             round trips it takes them to reflect new values) as
             they would if making only one measurement per
             round-trip and using RTO.Alpha and RTO.Beta as given
             in rule C3. However, the exact nature of these
             adjustments remains a research issue.
        [...]
      
      While it is discouraged to adjust rto_alpha and rto_beta
      and not further specified how to adjust them, the RFC also
      doesn't explicitly forbid it, but rather gives a RECOMMENDED
      default value (rto_alpha=3, rto_beta=2). We have a couple
      of users relying on the old permissions before they got
      changed. That said, if someone really has the urge to adjust
      them, we could allow it with a warning in the log.
      
      Fixes: 3fd091e7 ("[SCTP]: Remove multiple levels of msecs to jiffies conversions.")
      Signed-off-by: default avatarDaniel Borkmann <dborkman@redhat.com>
      Cc: Vlad Yasevich <vyasevich@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b58537a1
    • David S. Miller's avatar
      Merge branch 'csum_fixes' · e4f7ae93
      David S. Miller authored
      Tom Herbert says:
      
      ====================
      Fixes related to some recent checksum modifications.
      
      - Fix GSO constants to match NETIF flags
      - Fix logic in saving checksum complete in __skb_checksum_complete
      - Call __skb_checksum_complete from UDP if we are checksumming over
        whole packet in order to save checksum.
      - Fixes to VXLAN to work correctly with checksum complete
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e4f7ae93
    • Tom Herbert's avatar
      vxlan: Checksum fixes · f79b064c
      Tom Herbert authored
      Call skb_pop_rcv_encapsulation and postpull_rcsum for the Ethernet
      header to work properly with checksum complete.
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f79b064c
    • Tom Herbert's avatar
      net: add skb_pop_rcv_encapsulation · e5eb4e30
      Tom Herbert authored
      This function is used by UDP encapsulation protocols in RX when
      crossing encapsulation boundary. If ip_summed is set to
      CHECKSUM_UNNECESSARY and encapsulation is not set, change to
      CHECKSUM_NONE since the checksum has not been validated within the
      encapsulation. Clears csum_valid by the same rationale.
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e5eb4e30
    • Tom Herbert's avatar
      udp: call __skb_checksum_complete when doing full checksum · bbdff225
      Tom Herbert authored
      In __udp_lib_checksum_complete check if checksum is being done over all
      the data (len is equal to skb->len) and if it is call
      __skb_checksum_complete instead of __skb_checksum_complete_head. This
      allows checksum to be saved in checksum complete.
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bbdff225
    • Tom Herbert's avatar
      net: Fix save software checksum complete · 46fb51eb
      Tom Herbert authored
      Geert reported issues regarding checksum complete and UDP.
      The logic introduced in commit 7e3cead5
      ("net: Save software checksum complete") is not correct.
      
      This patch:
      1) Restores code in __skb_checksum_complete_header except for setting
         CHECKSUM_UNNECESSARY. This function may be calculating checksum on
         something less than skb->len.
      2) Adds saving checksum to __skb_checksum_complete. The full packet
         checksum 0..skb->len is calculated without adding in pseudo header.
         This value is saved in skb->csum and then the pseudo header is added
         to that to derive the checksum for validation.
      3) In both __skb_checksum_complete_header and __skb_checksum_complete,
         set skb->csum_valid to whether checksum of zero was computed. This
         allows skb_csum_unnecessary to return true without changing to
         CHECKSUM_UNNECESSARY which was done previously.
      4) Copy new csum related bits in __copy_skb_header.
      Reported-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      46fb51eb
    • Tom Herbert's avatar
      net: Fix GSO constants to match NETIF flags · 4b28252c
      Tom Herbert authored
      Joseph Gasparakis reported that VXLAN GSO offload stopped working with
      i40e device after recent UDP changes. The problem is that the
      SKB_GSO_* bits are out of sync with the corresponding NETIF flags. This
      patch fixes that. Also, we add BUILD_BUG_ONs in net_gso_ok for several
      GSO constants that were missing to avoid the problem in the future.
      Reported-by: default avatarJoseph Gasparakis <joseph.gasparakis@intel.com>
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4b28252c
    • Linus Torvalds's avatar
      Merge tag 'scsi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · abf04af7
      Linus Torvalds authored
      Pull more SCSI updates from James Bottomley:
       "This is just a couple of drivers (hpsa and lpfc) that got left out for
        further testing in linux-next.  We also have one fix to a prior
        submission (qla2xxx sparse)"
      
      * tag 'scsi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (36 commits)
        qla2xxx: fix sparse warnings introduced by previous target mode t10-dif patch
        lpfc: Update lpfc version to driver version 10.2.8001.0
        lpfc: Fix ExpressLane priority setup
        lpfc: mark old devices as obsolete
        lpfc: Fix for initializing RRQ bitmap
        lpfc: Fix for cleaning up stale ring flag and sp_queue_event entries
        lpfc: Update lpfc version to driver version 10.2.8000.0
        lpfc: Update Copyright on changed files from 8.3.45 patches
        lpfc: Update Copyright on changed files
        lpfc: Fixed locking for scsi task management commands
        lpfc: Convert runtime references to old xlane cfg param to fof cfg param
        lpfc: Fix FW dump using sysfs
        lpfc: Fix SLI4 s abort loop to process all FCP rings and under ring_lock
        lpfc: Fixed kernel panic in lpfc_abort_handler
        lpfc: Fix locking for postbufq when freeing
        lpfc: Fix locking for lpfc_hba_down_post
        lpfc: Fix dynamic transitions of FirstBurst from on to off
        hpsa: fix handling of hpsa_volume_offline return value
        hpsa: return -ENOMEM not -1 on kzalloc failure in hpsa_get_device_id
        hpsa: remove messages about volume status VPD inquiry page not supported
        ...
      abf04af7
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · 16d52ef7
      Linus Torvalds authored
      Pull more btrfs updates from Chris Mason:
       "This has a few fixes since our last pull and a new ioctl for doing
        btree searches from userland.  It's very similar to the existing
        ioctl, but lets us return larger items back down to the app"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        btrfs: fix error handling in create_pending_snapshot
        btrfs: fix use of uninit "ret" in end_extent_writepage()
        btrfs: free ulist in qgroup_shared_accounting() error path
        Btrfs: fix qgroups sanity test crash or hang
        btrfs: prevent RCU warning when dereferencing radix tree slot
        Btrfs: fix unfinished readahead thread for raid5/6 degraded mounting
        btrfs: new ioctl TREE_SEARCH_V2
        btrfs: tree_search, search_ioctl: direct copy to userspace
        btrfs: new function read_extent_buffer_to_user
        btrfs: tree_search, copy_to_sk: return needed size on EOVERFLOW
        btrfs: tree_search, copy_to_sk: return EOVERFLOW for too small buffer
        btrfs: tree_search, search_ioctl: accept varying buffer
        btrfs: tree_search: eliminate redundant nr_items check
      16d52ef7
    • Linus Torvalds's avatar
      Merge git://git.kvack.org/~bcrl/aio-next · a311c480
      Linus Torvalds authored
      Pull aio fix and cleanups from Ben LaHaise:
       "This consists of a couple of code cleanups plus a minor bug fix"
      
      * git://git.kvack.org/~bcrl/aio-next:
        aio: cleanup: flatten kill_ioctx()
        aio: report error from io_destroy() when threads race in io_destroy()
        fs/aio.c: Remove ctx parameter in kiocb_cancel
      a311c480
    • Al Viro's avatar
      fix __swap_writepage() compile failure on old gcc versions · 05064084
      Al Viro authored
      Tetsuo Handa wrote:
       "Commit 62a8067a ("bio_vec-backed iov_iter") introduced an unnamed
        union inside a struct which gcc-4.4.7 cannot handle.  Name the unnamed
         union as u in order to fix build failure"
      
      Let's do this instead: there is only one place in the entire tree that
      steps into this breakage.  Anon structs and unions work in older gcc
      versions; as the matter of fact, we have those in the tree - see e.g.
      struct ieee80211_tx_info in include/net/mac80211.h
      
      What doesn't work is handling their initializers:
      
      struct {
      	int a;
      	union {
      		int b;
      		char c;
      	};
      } x[2] = {{.a = 1, .c = 'a'}, {.a = 0, .b = 1}};
      
      is the obvious syntax for initializer, perfectly fine for C11 and
      handled correctly by gcc-4.7 or later.
      
      Earlier versions, though, break on it - declaration is fine and so's
      access to fields (i.e.  x[0].c = 'a'; would produce the right code), but
      members of the anon structs and unions are not inserted into the right
      namespace.  Tellingly, those older versions will not barf on struct {int
      a; struct {int a;};}; - looks like they just have it hacked up somewhere
      around the handling of .  and -> instead of doing the right thing.
      
      The easiest way to deal with that crap is to turn initialization of
      those fields (in the only place where we have such initializer of
      iov_iter) into plain assignment.
      Reported-by: default avatarTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
      Reported-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      05064084
  4. 14 Jun, 2014 4 commits