1. 20 3月, 2013 2 次提交
  2. 21 2月, 2013 2 次提交
  3. 26 1月, 2013 1 次提交
  4. 25 1月, 2013 1 次提交
  5. 04 1月, 2013 1 次提交
    • G
      Drivers: gpu: remove __dev* attributes. · 56550d94
      Greg Kroah-Hartman 提交于
      CONFIG_HOTPLUG is going away as an option.  As a result, the __dev*
      markings need to be removed.
      
      This change removes the use of __devinit, __devexit_p, and __devexit
      from these drivers.
      
      Based on patches originally written by Bill Pemberton, but redone by me
      in order to handle some of the coding style issues better, by hand.
      
      Cc: Bill Pemberton <wfp5p@virginia.edu>
      Cc: David Airlie <airlied@linux.ie>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      56550d94
  6. 05 12月, 2012 2 次提交
  7. 04 12月, 2012 2 次提交
    • I
      drm/exynos: add userptr feature for g2d module · 2a3098ff
      Inki Dae 提交于
      This patch adds userptr feautre for G2D module.
      
      The userptr means user space address allocated by malloc().
      And the purpose of this feature is to make G2D's dma able
      to access the user space region.
      
      To user this feature, user should flag G2D_BUF_USRPTR to
      offset variable of struct drm_exynos_g2d_cmd and fill
      struct drm_exynos_g2d_userptr with user space address
      and size for it and then should set a pointer to
      drm_exynos_g2d_userptr object to data variable of struct
      drm_exynos_g2d_cmd. The last bit of offset variable is used
      to check if the cmdlist's buffer type is userptr or not.
      If userptr, the g2d driver gets user space address and size
      and then gets pages through get_user_pages().
      (another case is counted as gem handle)
      
      Below is sample codes:
      
      static void set_cmd(struct drm_exynos_g2d_cmd *cmd,
      		unsigned long offset, unsigned long data)
      {
      	cmd->offset = offset;
      	cmd->data = data;
      }
      
      static int solid_fill_test(int x, int y, unsigned long userptr)
      {
      	struct drm_exynos_g2d_cmd cmd_gem[5];
      	struct drm_exynos_g2d_userptr g2d_userptr;
      	unsigned int gem_nr = 0;
      	...
      
      	g2d_userptr.userptr = userptr;
      	g2d_userptr.size = x * y * 4;
      
      	set_cmd(&cmd_gem[gem_nr++], DST_BASE_ADDR_REG |
      					G2D_BUF_USERPTR,
      			(unsigned long)&g2d_userptr);
      	...
      }
      
      int main(int argc, char **argv)
      {
      	unsigned long addr;
      	...
      
      	addr = malloc(x * y * 4);
      	...
      
      	solid_fill_test(x, y, addr);
      	...
      }
      
      And next, the pages are mapped with iommu table and the device
      address is set to cmdlist so that G2D's dma can access it.
      As you may know, the pages from get_user_pages() are pinned.
      In other words, they CAN NOT be migrated and also swapped out.
      So the dma access would be safe.
      
      But the use of userptr feature has performance overhead so
      this patch also has memory pool to the userptr feature.
      Please, assume that user sends cmdlist filled with userptr
      and size every time to g2d driver, and the get_user_pages
      funcion will be called every time.
      
      The memory pool has maximum 64MB size and the userptr that
      user had ever sent, is holded in the memory pool.
      This meaning is that if the userptr from user is same as one
      in the memory pool, device address to the userptr in the memory
      pool is set to cmdlist.
      
      And last, the pages from get_user_pages() will be freed once
      user calls free() and the dma access is completed. Actually,
      get_user_pages() takes 2 reference counts if the user process
      has never accessed user region allocated by malloc(). Then, if
      the user calls free(), the page reference count becomes 1 and
      becomes 0 with put_page() call. And the reverse holds as well.
      This means how the pages backed are used by dma and freed.
      
      This patch is based on "drm/exynos: add iommu support for g2d",
      	https://patchwork.kernel.org/patch/1629481/Signed-off-by: NInki Dae <inki.dae@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      2a3098ff
    • I
      drm/exynos: add iommu support for g2d · d87342c1
      Inki Dae 提交于
      Chagelog v2:
      removed unnecessary structure, struct g2d_gem_node.
      
      Chagelog v1:
      This patch adds iommu support for g2d driver. For this, it
      adds subdrv_probe/remove callback to enable or disable
      g2d iommu. And with this patch, in case of using g2d iommu,
      we can get or put device address to a gem handle from user
      through exynos_drm_gem_get/put_dma_addr(). Actually, these
      functions take a reference to a gem handle so that the gem
      object used by g2d dma is released properly.
      
      And runqueue_node has a pointer to drm_file object of current
      process to manage gem handles to owner.
      
      This patch is based on the below patch set, "drm/exynos: add
      iommu support for -next".
           http://www.spinics.net/lists/dri-devel/msg29041.htmlSigned-off-by: NInki Dae <inki.dae@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      d87342c1
  8. 04 10月, 2012 2 次提交
  9. 03 10月, 2012 1 次提交
  10. 13 9月, 2012 2 次提交
  11. 21 8月, 2012 1 次提交
    • T
      workqueue: deprecate flush[_delayed]_work_sync() · 43829731
      Tejun Heo 提交于
      flush[_delayed]_work_sync() are now spurious.  Mark them deprecated
      and convert all users to flush[_delayed]_work().
      
      If you're cc'd and wondering what's going on: Now all workqueues are
      non-reentrant and the regular flushes guarantee that the work item is
      not pending or running on any CPU on return, so there's no reason to
      use the sync flushes at all and they're going away.
      
      This patch doesn't make any functional difference.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Ian Campbell <ian.campbell@citrix.com>
      Cc: Jens Axboe <axboe@kernel.dk>
      Cc: Mattia Dongili <malattia@linux.it>
      Cc: Kent Yoder <key@linux.vnet.ibm.com>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Jiri Kosina <jkosina@suse.cz>
      Cc: Karsten Keil <isdn@linux-pingi.de>
      Cc: Bryan Wu <bryan.wu@canonical.com>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Alasdair Kergon <agk@redhat.com>
      Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
      Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: linux-wireless@vger.kernel.org
      Cc: Anton Vorontsov <cbou@mail.ru>
      Cc: Sangbeom Kim <sbkim73@samsung.com>
      Cc: "James E.J. Bottomley" <James.Bottomley@HansenPartnership.com>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Eric Van Hensbergen <ericvh@gmail.com>
      Cc: Takashi Iwai <tiwai@suse.de>
      Cc: Steven Whitehouse <swhiteho@redhat.com>
      Cc: Petr Vandrovec <petr@vandrovec.name>
      Cc: Mark Fasheh <mfasheh@suse.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Avi Kivity <avi@redhat.com> 
      43829731
  12. 17 5月, 2012 1 次提交
    • J
      drm/exynos: add G2D driver · d7f1642c
      Joonyoung Shim 提交于
      Changelog v3:
      - use __u64 instead of pointer in ioctl struct.
      
      The G2D is a 2D graphic accelerator that supports Bit Block Transfer.
      This G2D driver is exynos drm specific and supports only G2D(version
      4.1) of later Exynos series from Exynos4X12 because supporting DMA.
      
      The G2D is performed by two tasks simply.
      1. Configures the rendering parameters, such as foreground color and
         coordinates data by setting the drawing context registers.
      2. Start the rendering process by setting thre relevant command
         registers accordingly.
      
      The G2D version 4.1 supports DMA mode as host interface. User can make
      command list to reduce HOST(ARM) loads. The contents of The command list
      is setted to relevant registers of G2D by DMA.
      
      The command list is composed Header and command sets and Tail.
      - Header: The number of command set(4Bytes)
      - Command set: Register offset(4Bytes) + Register data(4Bytes)
      - Tail: Pointer of base address of the other command list(4Bytes)
      
      By Tail field, the G2D can process many command lists without halt at
      one go.
      
      The G2D has following the rendering pipeline.
      --> Primitive Drawing --> Rotation --> Clipping --> Bilinear Sampling
      --> Color Key --> ROP --> Mask Operation --> Alpha Blending -->
      Dithering --> FrameBuffer
      
      And supports various operations from the rendering pipeline.
      - copy
      - fast solid color fill
      - window clipping
      - rotation
      - flip
      - 4 operand raster operation(ROP4)
      - masking operation
      - alpha blending
      - color key
      - dithering
      - etc
      
      User should make the command list to data and registers needed by
      operation to use. The Exynos G2D driver only manages the command lists
      received from user. Some registers needs memory base address(physical
      address) of image. User doesn't know its physical address, so fills the
      gem handle of that memory than address to command sets, then G2D driver
      converts it to memory base address.
      
      We adds three ioctls and one event for Exynos G2D.
      
      - ioctls
      DRM_EXYNOS_G2D_GET_VER: get the G2D hardware version
      DRM_EXYNOS_G2D_SET_CMDLIST: set the command list from user to driver
      DRM_EXYNOS_G2D_EXEC: execute the command lists setted to driver
      
      - event
      DRM_EXYNOS_G2D_EVENT: event to give notification completion of the
      		      command list to user
      Signed-off-by: NJoonyoung Shim <jy0922.shim@samsung.com>
      Signed-off-by: NInki Dae <inki.dae@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      d7f1642c