1. 09 Nov, 2012 3 commits
    • Afzal Mohammed's avatar
      ARM: OMAP2+: onenand: generic timing calculation · 4f4426f9
      Afzal Mohammed authored
      Generic gpmc timing calculation helper is available now, use
      it instead of custom timing calculation.
      Signed-off-by: default avatarAfzal Mohammed <afzal@ti.com>
      4f4426f9
    • Afzal Mohammed's avatar
      ARM: OMAP2+: gpmc: generic timing calculation · 246da26d
      Afzal Mohammed authored
      Presently there are three peripherals that gets it timing
      by runtime calculation. Those peripherals can work with
      frequency scaling that affects gpmc clock. But timing
      calculation for them are in different ways.
      
      Here a generic runtime calculation method is proposed. Input
      to this function were selected so that they represent timing
      variables that are present in peripheral datasheets. Motive
      behind this was to achieve DT bindings for the inputs as is.
      Even though a few of the tusb6010 timings could not be made
      directly related to timings normally found on peripherals,
      expressions used were translated to those that could be
      justified.
      
      There are possibilities of improving the calculations, like
      calculating timing for read & write operations in a more
      similar way. Expressions derived here were tested for async
      onenand on omap3evm (as vanilla Kernel does not have omap3evm
      onenand support, local patch was used). Other peripherals,
      tusb6010, smc91x calculations were validated by simulating
      on omap3evm.
      
      Regarding "we_on" for onenand async, it was found that even
      for muxed address/data, it need not be greater than
      "adv_wr_off", but rather could be derived from write setup
      time for peripheral from start of access time, hence would
      more be in line with peripheral timings. With this method
      it was working fine. If it is required in some cases to
      have "we_on" same as "wr_data_mux_bus" (i.e. greater than
      "adv_wr_off"), another variable could be added to indicate
      it. But such a requirement is not expected though.
      
      It has been observed that "adv_rd_off" & "adv_wr_off" are
      currently calculated by adding an offset over "oe_on" and
      "we_on" respectively in the case of smc91x. But peripheral
      datasheet does not specify so and so "adv_rd(wr)_off" has
      been derived (to be specific, made ignorant of "oe_on" and
      "we_on") observing datasheet rather than adding an offset.
      Hence this generic routine is expected to work for smc91x
      (91C96 RX51 board). This was verified on smsc911x (9220 on
      OMAP3EVM) - a similar ethernet controller.
      
      Timings are calculated in ps to prevent rounding errors and
      converted to ns at final stage so that these values can be
      directly fed to gpmc_cs_set_timings(). gpmc_cs_set_timings()
      would be modified to take ps once all custom timing routines
      are replaced by the generic routine, at the same time
      generic timing routine would be modified to provide timings
      in ps. struct gpmc_timings field types are upgraded from
      u16 => u32 so that it can hold ps values.
      
      Whole of this exercise is being done to achieve driver and
      DT conversion. If timings could not be calculated in a
      peripheral agnostic way, either gpmc driver would have to
      be peripheral gnostic or a wrapper arrangement over gpmc
      driver would be required.
      Signed-off-by: default avatarAfzal Mohammed <afzal@ti.com>
      246da26d
    • Afzal Mohammed's avatar
      ARM: OMAP2+: gpmc: handle additional timings · 559d94b0
      Afzal Mohammed authored
      Configure busturnaround, cycle2cycledelay, waitmonitoringtime,
      clkactivationtime in gpmc_cs_set_timings(). This is done so
      that boards can configure these parameters of gpmc in Kernel
      instead of relying on bootloader. Also configure bool type
      timings like extradelay.
      
      This needed change to the existing users that were configuring
      clk activation time and extra delay by directly writing to
      registers. Thanks to Tony for making me aware of users of clk
      activation and being kind enough to test the modified one.
      Signed-off-by: default avatarAfzal Mohammed <afzal@ti.com>
      559d94b0
  2. 08 Nov, 2012 1 commit
  3. 07 Nov, 2012 1 commit
  4. 02 Nov, 2012 2 commits
  5. 31 Oct, 2012 13 commits
  6. 26 Oct, 2012 5 commits
    • Paul Walmsley's avatar
      ARM: OMAP1: usb: fix sparse warnings · eba36d77
      Paul Walmsley authored
      
      Resolve the following sparse warnings:
      
      arch/arm/mach-omap1/usb.c:304:12: warning: symbol 'omap1_usb0_init' was not declared. Should it be static?
      arch/arm/mach-omap1/usb.c:412:12: warning: symbol 'omap1_usb1_init' was not declared. Should it be static?
      arch/arm/mach-omap1/usb.c:478:12: warning: symbol 'omap1_usb2_init' was not declared. Should it be static?
      
      by declaring those functions as static.
      Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Felipe Balbi <balbi@ti.com>
      [tony@atomide.com: this was missed with plat/usb.h removal]
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      eba36d77
    • Tony Lindgren's avatar
      Merge tag 'omap-cleanup-fixes-a-for-3.8' of... · a0212796
      Tony Lindgren authored
      Merge tag 'omap-cleanup-fixes-a-for-3.8' of git://git.kernel.org/pub/scm/linux/kernel/git/pjw/omap-pending into omap-for-v3.8/cleanup-headers
      
      Several fixes for build failures and sparse warnings in the
      OMAP cleanup-headers branch.  Intended for 3.8 cleanup.
      
      Basic build, boot, and PM test logs are available from here:
      
          http://www.pwsan.com/omap/testlogs/cleanup-headers-compile-fixes-3.8/20121026132711/
      
      Due to underlying problems in v3.7-rc2, several tests fail.  These
      failures are unrelated to these patches.
      a0212796
    • Paul Walmsley's avatar
      ARM: OMAP1: fix sparse warning added by commit 4c98dc6b · 97af08b6
      Paul Walmsley authored
      Commit 4c98dc6b ("ARM: OMAP: Make
      plat/fpga.h local to arch/arm/plat-omap") results in a new warning from
      sparse:
      
      arch/arm/mach-omap1/fpga.c:147:6: warning: symbol 'omap1510_fpga_init_irq' was not declared. Should it be static?
      
      Fix by adding a missing include.
      Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
      Cc: Tony Lindgren <tony@atomide.com>
      97af08b6
    • Paul Walmsley's avatar
      ARM: OMAP1: fix build breakage introduced by commit 25c7d49e · 47ba7099
      Paul Walmsley authored
      Commit 25c7d49e ("ARM: OMAP: Make
      omap_device local to mach-omap2") broke an OMAP5912-only build here:
      
      arch/arm/mach-omap1/pm_bus.c: In function 'omap1_pm_runtime_init':
      arch/arm/mach-omap1/pm_bus.c:69:2: error: implicit declaration of function
      'cpu_class_is_omap1'
      make[1]: *** [arch/arm/mach-omap1/pm_bus.o] Error 1
      
      Fix by adding a missing include.
      Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
      Cc: Tony Lindgren <tony@atomide.com>
      47ba7099
    • Paul Walmsley's avatar
      ARM: OMAP2+: fix build breakage introduced by commit b7754452 · ea5d8f42
      Paul Walmsley authored
      Commit b7754452 ("mtd: onenand: omap:
      use pdata info instead of cpu_is") broke an OMAP3+4 build and an N800
      multi-OMAP2xxx build here:
      
      drivers/built-in.o: In function `omap2_onenand_probe':
      drivers/mtd/onenand/omap2.c:742: undefined reference to `omap2_onenand_read_bufferram'
      drivers/mtd/onenand/omap2.c:743: undefined reference to `omap2_onenand_write_bufferram'
      drivers/mtd/onenand/omap2.c:742: undefined reference to `omap2_onenand_read_bufferram'
      drivers/mtd/onenand/omap2.c:743: undefined reference to `omap2_onenand_write_bufferram'
      
      ...
      
      drivers/built-in.o: In function `omap2_onenand_probe':
      drivers/mtd/onenand/omap2.c:788: undefined reference to `omap3_onenand_read_bufferram'
      drivers/mtd/onenand/omap2.c:788: undefined reference to `omap3_onenand_write_bufferram'
      
      Fix by declaring static functions for the missing symbols, rather than
      just prototypes.
      Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
      Cc: Afzal Mohammed <afzal@ti.com>
      Cc: Tony Lindgren <tony@atomide.com>
      ea5d8f42
  7. 25 Oct, 2012 1 commit
  8. 24 Oct, 2012 11 commits
  9. 22 Oct, 2012 3 commits
    • Jiri Slaby's avatar
      TTY: move tty buffers to tty_port · ecbbfd44
      Jiri Slaby authored
      So this is it. The big step why we did all the work over the past
      kernel releases. Now everything is prepared, so nothing protects us
      from doing that big step.
      
                 |  |            \  \ nnnn/^l      |  |
                 |  |             \  /     /       |  |
                 |  '-,.__   =>    \/   ,-`    =>  |  '-,.__
                 | O __.´´)        (  .`           | O __.´´)
                  ~~~   ~~          ``              ~~~   ~~
      The buffers are now in the tty_port structure and we can start
      teaching the buffer helpers (insert char/string, flip etc.) to use
      tty_port instead of tty_struct all around.
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Acked-by: default avatarAlan Cox <alan@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      ecbbfd44
    • Jiri Slaby's avatar
      TTY: add port -> tty link · 967fab69
      Jiri Slaby authored
      For that purpose we have to temporarily introduce a second tty back
      pointer into tty_port. It is because serial layer, and maybe others,
      still do not use tty_port_tty_set/get. So that we cannot set the
      tty_port->tty to NULL at will now.
      
      Yes, the fix would be to convert whole serial layer and all its users
      to tty_port_tty_set/get. However we are in the process of removing the
      need of tty in most of the call sites, so this would lead to a
      duplicated work.
      
      Instead we have now tty_port->itty (internal tty) which will be used
      only in flush_to_ldisc. For that one it is ensured that itty is valid
      wherever the work is run. IOW, the work is synchronously cancelled
      before we set itty to NULL and also before hangup is processed.
      
      After we need only tty_port and not tty_struct in most code, this
      shall be changed to tty_port_tty_set/get and itty removed completely.
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Acked-by: default avatarAlan Cox <alan@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      967fab69
    • Jiri Slaby's avatar
      TTY: tty_buffer, cache pointer to tty->buf · 5cff39c6
      Jiri Slaby authored
      During the move of tty buffers from tty_struct to tty_port, we will
      need to switch all users of buf to tty->port->buf. There are many
      functions where this is accessed directly in their code many times.
      Cache the tty->buf pointer in such functions now and change only
      single lines in each function in the next patch.
      
      Not that it is convenient for the next patch, but the code is now also
      more readable.
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Acked-by: default avatarAlan Cox <alan@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5cff39c6