linux/drivers/gpu/drm/radeon/radeon_asic.c

/*
 * Copyright 2008 Advanced Micro Devices, Inc.
 * Copyright 2008 Red Hat Inc.
 * Copyright 2009 Jerome Glisse.
 *
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the "Software"),
 * to deal in the Software without restriction, including without limitation
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
 * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 * OTHER DEALINGS IN THE SOFTWARE.
 *
 * Authors: Dave Airlie
 *          Alex Deucher
 *          Jerome Glisse
 */

#include <linux/console.h>
#include <linux/pci.h>
#include <linux/vgaarb.h>

#include <drm/radeon_drm.h>

#include "atom.h"
#include "radeon.h"
#include "radeon_asic.h"
#include "radeon_reg.h"

/*
 * Registers accessors functions.
 */
/**
 * radeon_invalid_rreg - dummy reg read function
 *
 * @rdev: radeon device pointer
 * @reg: offset of register
 *
 * Dummy register read function.  Used for register blocks
 * that certain asics don't have (all asics).
 * Returns the value in the register.
 */
static uint32_t radeon_invalid_rreg(struct radeon_device *rdev, uint32_t reg)
{}

/**
 * radeon_invalid_wreg - dummy reg write function
 *
 * @rdev: radeon device pointer
 * @reg: offset of register
 * @v: value to write to the register
 *
 * Dummy register read function.  Used for register blocks
 * that certain asics don't have (all asics).
 */
static void radeon_invalid_wreg(struct radeon_device *rdev, uint32_t reg, uint32_t v)
{}

/**
 * radeon_register_accessor_init - sets up the register accessor callbacks
 *
 * @rdev: radeon device pointer
 *
 * Sets up the register accessor callbacks for various register
 * apertures.  Not all asics have all apertures (all asics).
 */
static void radeon_register_accessor_init(struct radeon_device *rdev)
{}

static int radeon_invalid_get_allowed_info_register(struct radeon_device *rdev,
						    u32 reg, u32 *val)
{}

/* helper to disable agp */
/**
 * radeon_agp_disable - AGP disable helper function
 *
 * @rdev: radeon device pointer
 *
 * Removes AGP flags and changes the gart callbacks on AGP
 * cards when using the internal gart rather than AGP (all asics).
 */
void radeon_agp_disable(struct radeon_device *rdev)
{}

/*
 * ASIC
 */

static const struct radeon_asic_ring r100_gfx_ring =;

static struct radeon_asic r100_asic =;

static struct radeon_asic r200_asic =;

static const struct radeon_asic_ring r300_gfx_ring =;

static const struct radeon_asic_ring rv515_gfx_ring =;

static struct radeon_asic r300_asic =;

static struct radeon_asic r300_asic_pcie =;

static struct radeon_asic r420_asic =;

static struct radeon_asic rs400_asic =;

static struct radeon_asic rs600_asic =;

static struct radeon_asic rs690_asic =;

static struct radeon_asic rv515_asic =;

static struct radeon_asic r520_asic =;

static const struct radeon_asic_ring r600_gfx_ring =;

static const struct radeon_asic_ring r600_dma_ring =;

static struct radeon_asic r600_asic =;

static const struct radeon_asic_ring rv6xx_uvd_ring =;

static struct radeon_asic rv6xx_asic =;

static struct radeon_asic rs780_asic =;

static const struct radeon_asic_ring rv770_uvd_ring =;

static struct radeon_asic rv770_asic =;

static const struct radeon_asic_ring evergreen_gfx_ring =;

static const struct radeon_asic_ring evergreen_dma_ring =;

static struct radeon_asic evergreen_asic =;

static struct radeon_asic sumo_asic =;

static struct radeon_asic btc_asic =;

static const struct radeon_asic_ring cayman_gfx_ring =;

static const struct radeon_asic_ring cayman_dma_ring =;

static const struct radeon_asic_ring cayman_uvd_ring =;

static struct radeon_asic cayman_asic =;

static const struct radeon_asic_ring trinity_vce_ring =;

static struct radeon_asic trinity_asic =;

static const struct radeon_asic_ring si_gfx_ring =;

static const struct radeon_asic_ring si_dma_ring =;

static struct radeon_asic si_asic =;

static const struct radeon_asic_ring ci_gfx_ring =;

static const struct radeon_asic_ring ci_cp_ring =;

static const struct radeon_asic_ring ci_dma_ring =;

static const struct radeon_asic_ring ci_vce_ring =;

static struct radeon_asic ci_asic =;

static struct radeon_asic kv_asic =;

/**
 * radeon_asic_init - register asic specific callbacks
 *
 * @rdev: radeon device pointer
 *
 * Registers the appropriate asic specific callbacks for each
 * chip family.  Also sets other asics specific info like the number
 * of crtcs and the register aperture accessors (all asics).
 * Returns 0 for success.
 */
int radeon_asic_init(struct radeon_device *rdev)
{}