Commit 0a4583eb authored by Dave Airlie's avatar Dave Airlie
Browse files

Merge branch 'drm-radeon-linus' of ../drm-next

* 'drm-radeon-linus' of ../drm-next:
  drm/radeon/kms: retry auxch on 0x20 timeout value.
  drm/radeon: Skip dma copy test in benchmark if card doesn't have dma engine.
  drm/radeon/kms: fix screen clearing before fbcon.
  drm/radeon/kms: add quirk for VGA without DDC on rv730 XFX card.
  drm/radeon/kms: don't crash if no DDC bus on VGA/DVI connector.
  drm/radeon/kms: change Kconfig text to reflect the new option.
  drm/radeon/kms: suspend and resume audio stuff
parents e8a47c10 648ac05c
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
config DRM_RADEON_KMS
	bool "Enable modesetting on radeon by default"
	bool "Enable modesetting on radeon by default - NEW DRIVER"
	depends on DRM_RADEON
	help
	  Choose this option if you want kernel modesetting enabled by default,
	  and you have a new enough userspace to support this. Running old
	  userspaces with this enabled will cause pain.
	  Choose this option if you want kernel modesetting enabled by default.

	  This is a completely new driver. It's only part of the existing drm
	  for compatibility reasons. It requires an entirely different graphics
	  stack above it and works very differently from the old drm stack.
	  i.e. don't enable this unless you know what you are doing it may
	  cause issues or bugs compared to the previous userspace driver stack.

	  When kernel modesetting is enabled the IOCTL of radeon/drm
	  driver are considered as invalid and an error message is printed
+7 −3
Original line number Diff line number Diff line
@@ -332,11 +332,13 @@ bool radeon_process_aux_ch(struct radeon_i2c_chan *chan, u8 *req_bytes,
	PROCESS_AUX_CHANNEL_TRANSACTION_PS_ALLOCATION args;
	int index = GetIndexIntoMasterTable(COMMAND, ProcessAuxChannelTransaction);
	unsigned char *base;
	int retry_count = 0;

	memset(&args, 0, sizeof(args));

	base = (unsigned char *)rdev->mode_info.atom_context->scratch;

retry:
	memcpy(base, req_bytes, num_bytes);

	args.lpAuxRequest = 0;
@@ -347,10 +349,12 @@ bool radeon_process_aux_ch(struct radeon_i2c_chan *chan, u8 *req_bytes,

	atom_execute_table(rdev->mode_info.atom_context, index, (uint32_t *)&args);

	if (args.ucReplyStatus) {
		DRM_DEBUG("failed to get auxch %02x%02x %02x %02x 0x%02x %02x\n",
	if (args.ucReplyStatus && !args.ucDataOutLen) {
		if (args.ucReplyStatus == 0x20 && retry_count < 10)
			goto retry;
		DRM_DEBUG("failed to get auxch %02x%02x %02x %02x 0x%02x %02x after %d retries\n",
			  req_bytes[1], req_bytes[0], req_bytes[2], req_bytes[3],
			  chan->rec.i2c_id, args.ucReplyStatus);
			  chan->rec.i2c_id, args.ucReplyStatus, retry_count);
		return false;
	}

+8 −0
Original line number Diff line number Diff line
@@ -1950,6 +1950,13 @@ int r600_resume(struct radeon_device *rdev)
		DRM_ERROR("radeon: failled testing IB (%d).\n", r);
		return r;
	}

	r = r600_audio_init(rdev);
	if (r) {
		DRM_ERROR("radeon: audio resume failed\n");
		return r;
	}

	return r;
}

@@ -1957,6 +1964,7 @@ int r600_suspend(struct radeon_device *rdev)
{
	int r;

	r600_audio_fini(rdev);
	/* FIXME: we should wait for ring to be empty */
	r600_cp_stop(rdev);
	rdev->cp.ready = false;
+1 −2
Original line number Diff line number Diff line
@@ -261,7 +261,6 @@ void r600_audio_fini(struct radeon_device *rdev)
	if (!r600_audio_chipset_supported(rdev))
		return;

	WREG32_P(R600_AUDIO_ENABLE, 0x0, ~0x81000000);

	del_timer(&rdev->audio_timer);
	WREG32_P(R600_AUDIO_ENABLE, 0x0, ~0x81000000);
}
+9 −0
Original line number Diff line number Diff line
@@ -287,6 +287,15 @@ static bool radeon_atom_apply_quirks(struct drm_device *dev,
			*connector_type = DRM_MODE_CONNECTOR_DVID;
	}

	/* XFX Pine Group device rv730 reports no VGA DDC lines
	 * even though they are wired up to record 0x93
	 */
	if ((dev->pdev->device == 0x9498) &&
	    (dev->pdev->subsystem_vendor == 0x1682) &&
	    (dev->pdev->subsystem_device == 0x2452)) {
		struct radeon_device *rdev = dev->dev_private;
		*i2c_bus = radeon_lookup_i2c_gpio(rdev, 0x93);
	}
	return true;
}

Loading