Commit graph

664 commits

Author SHA1 Message Date
Dave Airlie
52bb4a7391 Merge branch 'drm-nouveau-next' of git://git.freedesktop.org/git/nouveau/linux-2.6 into drm-fixes
* 'drm-nouveau-next' of git://git.freedesktop.org/git/nouveau/linux-2.6:
  drm/nvc0/grctx: correct an off-by-one
  drm/nv50: Fix race with PFIFO during PGRAPH context destruction.
  drm/nouveau: Workaround incorrect DCB entry on a GeForce3 Ti 200.
  drm/nvc0: implement irq handler for whatever's at 0x14xxxx
  drm/nvc0: fix incorrect TPC register setup
  drm/nouveau: probe for adt7473 before f75375
  drm/nouveau: remove dead function definition
2011-01-26 17:12:42 +10:00
Ben Skeggs
5d07929808 drm/nvc0/grctx: correct an off-by-one
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:05:01 +10:00
Francisco Jerez
34311c7301 drm/nv50: Fix race with PFIFO during PGRAPH context destruction.
Reported-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:53 +10:00
Francisco Jerez
670820c0e6 drm/nouveau: Workaround incorrect DCB entry on a GeForce3 Ti 200.
Fixes the DVI-D output on that board (fdo bug 32645).

Reported-by: Bryan Quigley <BryanQuigley@Ubuntu.com>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:50 +10:00
Ben Skeggs
51f73d64b4 drm/nvc0: implement irq handler for whatever's at 0x14xxxx
This is just barely enough to stop a never-ending IRQ storm that can
be triggered by our 3D driver.  We have no idea what this engine is..

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:44 +10:00
Ben Skeggs
0f1cb203b4 drm/nvc0: fix incorrect TPC register setup
Was hitting TPC+1's regs by accident, oops.

Reported-by: Christoph Bumiller <e0425955@student.tuwien.ac.at>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:39 +10:00
Ben Skeggs
b26e72fbb5 drm/nouveau: probe for adt7473 before f75375
There's a reported case where probing for f75375 causes the system
to hang completely, in this case there's an adt7473 at the same
i2c address.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:34 +10:00
Ben Skeggs
1c2a679aa9 drm/nouveau: remove dead function definition
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-25 11:04:30 +10:00
David Rientjes
6a108a14fa kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT
The meaning of CONFIG_EMBEDDED has long since been obsoleted; the option
is used to configure any non-standard kernel with a much larger scope than
only small devices.

This patch renames the option to CONFIG_EXPERT in init/Kconfig and fixes
references to the option throughout the kernel.  A new CONFIG_EMBEDDED
option is added that automatically selects CONFIG_EXPERT when enabled and
can be used in the future to isolate options that should only be
considered for embedded systems (RISC architectures, SLOB, etc).

Calling the option "EXPERT" more accurately represents its intention: only
expert users who understand the impact of the configuration changes they
are making should enable it.

Reviewed-by: Ingo Molnar <mingo@elte.hu>
Acked-by: David Woodhouse <david.woodhouse@intel.com>
Signed-off-by: David Rientjes <rientjes@google.com>
Cc: Greg KH <gregkh@suse.de>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Robin Holt <holt@sgi.com>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-01-20 17:02:05 -08:00
Dave Airlie
51fda92223 Merge remote branch 'nouveau/drm-nouveau-next' of /ssd/git/drm-nouveau-next into drm-fixes
* 'nouveau/drm-nouveau-next' of /ssd/git/drm-nouveau-next:
  drm/nouveau: fix gpu page faults triggered by plymouthd
  drm/nouveau: greatly simplify mm, killing some bugs in the process
  drm/nvc0: enable protection of system-use-only structures in vm
  drm/nv40: initialise 0x17xx on all chipsets that have it
  drm/nv40: make detection of 0x4097-ful chipsets available everywhere
2011-01-17 12:20:31 +10:00
Ben Skeggs
f01a9720cb drm/nouveau: fix gpu page faults triggered by plymouthd
The switch to separate BAR and channel address spaces made the fbcon memory
address calculation incorrect on NV50+ boards, this commit fixes that.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-17 11:28:59 +10:00
Ben Skeggs
8b464bfed6 drm/nouveau: greatly simplify mm, killing some bugs in the process
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-17 11:28:54 +10:00
Ben Skeggs
c906ca0fbf drm/nvc0: enable protection of system-use-only structures in vm
Somehow missed this in the original merge of the nvc0 code.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-17 11:28:50 +10:00
Ben Skeggs
1380da4979 drm/nv40: initialise 0x17xx on all chipsets that have it
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-17 11:28:43 +10:00
Ben Skeggs
c693931d93 drm/nv40: make detection of 0x4097-ful chipsets available everywhere
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-17 11:28:31 +10:00
Dave Airlie
3632ef8909 Revert "drm: Update fbdev fb_fix_screeninfo"
This reverts commit dfe63bb0ad.

This commit was causing nouveau not to work properly, for -rc1 I'd
prefer it worked and we can look if this is useful for 2.6.39.

Cc: James Simmons <jsimmons@infradead.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-01-14 16:10:28 -08:00
Linus Torvalds
008d23e485 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (43 commits)
  Documentation/trace/events.txt: Remove obsolete sched_signal_send.
  writeback: fix global_dirty_limits comment runtime -> real-time
  ppc: fix comment typo singal -> signal
  drivers: fix comment typo diable -> disable.
  m68k: fix comment typo diable -> disable.
  wireless: comment typo fix diable -> disable.
  media: comment typo fix diable -> disable.
  remove doc for obsolete dynamic-printk kernel-parameter
  remove extraneous 'is' from Documentation/iostats.txt
  Fix spelling milisec -> ms in snd_ps3 module parameter description
  Fix spelling mistakes in comments
  Revert conflicting V4L changes
  i7core_edac: fix typos in comments
  mm/rmap.c: fix comment
  sound, ca0106: Fix assignment to 'channel'.
  hrtimer: fix a typo in comment
  init/Kconfig: fix typo
  anon_inodes: fix wrong function name in comment
  fix comment typos concerning "consistent"
  poll: fix a typo in comment
  ...

Fix up trivial conflicts in:
 - drivers/net/wireless/iwlwifi/iwl-core.c (moved to iwl-legacy.c)
 - fs/ext4/ext4.h

Also fix missed 'diabled' typo in drivers/net/bnx2x/bnx2x.h while at it.
2011-01-13 10:05:56 -08:00
Dave Airlie
7ad7f87b87 Merge remote branch 'nouveau/drm-nouveau-next' of ../drm-nouveau-next into drm-core-next
* 'nouveau/drm-nouveau-next' of ../drm-nouveau-next:
  drm/nouveau: fix hwmon device binding
  drm/nouveau: create grctx on the fly on all chipsets
  drm/nvc0: fix init without firmware present
  drm/nvc0/pgraph: fix 0x406028/0x405870 init
  drm/nvc0/pgraph: more unit names
  drm/nvc0/pfifo: support for chipsets with only one PSUBFIFO (0xc1)
  drm/nvc0: reserve only subc 0 for kernel use
  drm/nv50: sync up gr data error names with rnn, use for nvc0 also
  drm/nvc0: parse a couple more PGRAPH_INTR
  drm/nvc0: nuke left-over debug messages
  drm/nvc0: kill off a couple more magics
  drm/nouveau: Validate channel indices passed from userspace.
  drm/nouveau: Only select ACPI_VIDEO if its dependencies are met
2011-01-10 09:23:49 +10:00
Lucas Stach
07cfe0e7a8 drm/nouveau: fix hwmon device binding
Bind the hwmon structs to nouveau device kobj. This makes sure
the hwmon files are created in the device subdir in line with
all other hwmon drivers.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-07 23:22:17 +10:00
Ben Skeggs
e457acaed4 drm/nouveau: create grctx on the fly on all chipsets
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-07 14:03:58 +10:00
James Simmons
dfe63bb0ad drm: Update fbdev fb_fix_screeninfo
If you change the color depth via fbset or some other framebuffer aware
userland application struct fb_fix_screeninfo is not updated to this new
information. This patch fixes this issue. Also the function is changed to
just pass in struct drm_framebuffer so in the future we could use more
fields. I'm hoping some day fix->smem* could be set here :-)

Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-01-07 13:44:40 +10:00
Ben Skeggs
eeb9cc015f drm/nvc0: fix init without firmware present
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-06 22:10:15 +10:00
Dave Airlie
5bcf719b7d drm/switcheroo: track state of switch in drivers.
We need to track the state of the switch in drivers, so that after s/r
we don't resume the card we've explicitly switched off before. Also
don't allow a userspace open to occur if we've switched the gpu off.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-01-05 13:45:30 +10:00
Dave Airlie
8d608aa629 vga_switcheroo: add reprobe hook for fbcon to recheck connected outputs.
This adds a hook after the mux is switched for the driver to reprobe
the connected outputs.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-01-05 13:44:07 +10:00
Dave Airlie
d1fbd923da nouveau/acpi: improve detection of what is IGD and what is DIS.
This improves the IGD/DIS picking using firstly if Intel, then
if the bus is bus 0. There may be a correct way to do this, but
I've no idea what it is.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-01-05 13:43:32 +10:00
Dave Airlie
5ccb377fea drm/nouveau: add delayed switch complete callback.
this just adds the callback on the delayed switch mechanism.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-01-05 13:43:22 +10:00
Stefan Weil
e8a8b252fb Fix spelling mistakes in comments
milisecond -> millisecond
 meassge -> message

Cc: Kalle Valo <kvalo@adurom.com>
Cc: Jiri Kosina <trivial@kernel.org>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Stefan Weil <weil@mail.berlios.de>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2011-01-03 13:51:58 +01:00
Ben Skeggs
47a44d27ca drm/nvc0/pgraph: fix 0x406028/0x405870 init
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-01-01 12:26:23 +10:00
Ben Skeggs
680a48720f drm/nvc0/pgraph: more unit names
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-31 12:21:56 +10:00
Ben Skeggs
ec9c0883ea drm/nvc0/pfifo: support for chipsets with only one PSUBFIFO (0xc1)
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-31 12:11:50 +10:00
Ben Skeggs
2a55c9a7ff drm/nvc0: reserve only subc 0 for kernel use
Current 3D driver expects this behaviour.  While this could be changed,
there's no compelling reason to reserve more than one subchannel for the
DRM.  If we ever need to use an object other then M2MF, we can just
re-bind subchannel 0 as required.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-30 11:55:07 +10:00
Ben Skeggs
6effe39364 drm/nv50: sync up gr data error names with rnn, use for nvc0 also
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-30 11:48:03 +10:00
Ben Skeggs
eae5e7f304 drm/nvc0: parse a couple more PGRAPH_INTR
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-30 11:40:07 +10:00
Ben Skeggs
93d0cd7b9e drm/nvc0: nuke left-over debug messages
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-29 10:51:34 +10:00
Ben Skeggs
b1cd916ab9 drm/nvc0: kill off a couple more magics
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-29 10:51:27 +10:00
Michel Hermier
8e91182bbd drm/nouveau: Validate channel indices passed from userspace.
When hacking the libdrm for improvements, I triggered a kernel crash
related to the fact that the NOUVEAU_NOTIFIEROBJ_ALLOC ioctl calls
nouveau_channel_get with an unchecked channel index.
The patch ensures that the channel index is an unsigned and validates
its value in nouveau_channel_get.

Signed-off-by: Michel Hermier <hermier@frugalware.org>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-27 10:41:01 +10:00
Ben Hutchings
c42988012a drm/nouveau: Only select ACPI_VIDEO if its dependencies are met
CONFIG_ACPI_VIDEO depends on more than just CONFIG_ACPI, so add those
dependencies to the Kconfig select condition.  The case where some
dependencies fail to be satisfied should be handled correctly, because
in that case the ACPI_VIDEO symbols we use are converted into
static-inline stubs.

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-27 10:40:47 +10:00
Jiri Kosina
4b7bd36470 Merge branch 'master' into for-next
Conflicts:
	MAINTAINERS
	arch/arm/mach-omap2/pm24xx.c
	drivers/scsi/bfa/bfa_fcpim.c

Needed to update to apply fixes for which the old branch was too
outdated.
2010-12-22 18:57:02 +01:00
Dave Airlie
1d99e5c572 Merge remote branch 'nouveau/drm-nouveau-next' of /ssd/git/drm-nouveau-next into drm-core-next
* 'nouveau/drm-nouveau-next' of /ssd/git/drm-nouveau-next:
  drm/nvc0: accelerate ttm buffer moves
  drm/nvc0: initial support for tiled buffer objects
  drm/nvc0: implement fbcon acceleration
  drm/nvc0: implement pgraph engine hooks
  drm/nvc0: implement pfifo engine hooks
  drm/nvc0: implement fencing
  drm/nvc0: fix channel dma init paths
  drm/nvc0: skip dma object creation for drm channel
  drm/nvc0: implement channel structure initialisation
  drm/nvc0: gpuobj_new need only check validity and init the relevant engine
  drm/nvc0: reject the notifier_alloc ioctl
  drm/nvc0: create shared channel vm
  drm/nvc0: initial vm implementation, use for bar1/bar3 management
  drm/nvc0: import initial vm backend
  drm/nouveau: modify vm to accomodate dual page tables for nvc0
  drm/nv50: add missing license header to nv50_fbcon.c
  drm/nv50: fix smatch warning in nv50_vram.c
  drm/nouveau: sizeof() vs ARRAY_SIZE()
2010-12-22 09:48:04 +10:00
Ben Skeggs
183720b8af drm/nvc0: accelerate ttm buffer moves
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:18:44 +10:00
Ben Skeggs
6d86951a45 drm/nvc0: initial support for tiled buffer objects
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:18:42 +10:00
Ben Skeggs
ddbaf79a8b drm/nvc0: implement fbcon acceleration
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:18:39 +10:00
Ben Skeggs
966a5b7daa drm/nvc0: implement pgraph engine hooks
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:18:32 +10:00
Ben Skeggs
b2b099388f drm/nvc0: implement pfifo engine hooks
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:39 +10:00
Ben Skeggs
529c495912 drm/nvc0: implement fencing
Just simple REF_CNT fencing for the moment.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:36 +10:00
Ben Skeggs
96545299d7 drm/nvc0: fix channel dma init paths
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:34 +10:00
Ben Skeggs
5216782bf8 drm/nvc0: skip dma object creation for drm channel
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:31 +10:00
Ben Skeggs
effd6e066f drm/nvc0: implement channel structure initialisation
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:28 +10:00
Ben Skeggs
7460d70355 drm/nvc0: gpuobj_new need only check validity and init the relevant engine
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:26 +10:00
Ben Skeggs
587107b690 drm/nvc0: reject the notifier_alloc ioctl
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-12-21 17:17:23 +10:00