From patchwork Fri Jan 13 06:23:18 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 1725710 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=GNC2n5IK; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NtWbf1Np7z23fd for ; Fri, 13 Jan 2023 17:24:30 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=8PqpHM6+4s3ZwyCNzMcW6M8DwjuYc1kOwVA35uJf/So=; b=GNC2n5IK8xVZ5v T0dD5M82nYz798/5SmyI041SXrkcr9tEpyIUYkq0P492tzl9gUrHJFOwlicS1Sc/ZXueEOkIC6nzc iXaCEo7j41SonzzxjOMi4qk7E+rBohqD8HLV0AARySrsd4CrV9wwSzJ+M5MJMLLEb7SiEYjn0EVdU eQu9s0BnWPzJsaaar3mvnndvqAcwp9D1VYHGkWhh2my7Ha9LHNOg6jpHAprXCZ4mjC57y28NZNaK2 8fIvNOav7/rt2gs6PUdbi9MwxTjYvVWDSCv4BvadzTNJSO/Nd+zKPQU54SXeF3ZuabUMHbIzqWiGg EtKdhPgy201kuNDsgarw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTh-000lOl-U4; Fri, 13 Jan 2023 06:23:49 +0000 Received: from [2001:4bb8:181:656b:9509:7d20:8d39:f895] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTc-000lMt-MQ; Fri, 13 Jan 2023 06:23:45 +0000 From: Christoph Hellwig To: Yoshinori Sato , Rich Felker , Arnd Bergmann , Greg Kroah-Hartman Cc: Laurent Pinchart , Kieran Bingham , Geert Uytterhoeven , linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org, linux-arch@vger.kernel.org, dmaengine@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, linux-i2c@vger.kernel.org, linux-input@vger.kernel.org, linux-media@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, linux-rtc@vger.kernel.org, linux-spi@vger.kernel.org, linux-serial@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, alsa-devel@alsa-project.org, linux-sh@vger.kernel.org Subject: [PATCH 01/22] gpu/drm: remove the shmobile drm driver Date: Fri, 13 Jan 2023 07:23:18 +0100 Message-Id: <20230113062339.1909087-2-hch@lst.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230113062339.1909087-1-hch@lst.de> References: <20230113062339.1909087-1-hch@lst.de> MIME-Version: 1.0 X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org This driver depends on ARM && ARCH_SHMOBILE, but ARCH_SHMOBILE can only be set for each/sh, making the driver dead code except for the COMPILE_TEST case. Signed-off-by: Christoph Hellwig Reviewed-by: Laurent Pinchart --- drivers/gpu/drm/Kconfig | 2 - drivers/gpu/drm/Makefile | 1 - drivers/gpu/drm/shmobile/Kconfig | 12 - drivers/gpu/drm/shmobile/Makefile | 8 - .../gpu/drm/shmobile/shmob_drm_backlight.c | 82 --- .../gpu/drm/shmobile/shmob_drm_backlight.h | 19 - drivers/gpu/drm/shmobile/shmob_drm_crtc.c | 683 ------------------ drivers/gpu/drm/shmobile/shmob_drm_crtc.h | 55 -- drivers/gpu/drm/shmobile/shmob_drm_drv.c | 303 -------- drivers/gpu/drm/shmobile/shmob_drm_drv.h | 42 -- drivers/gpu/drm/shmobile/shmob_drm_kms.c | 150 ---- drivers/gpu/drm/shmobile/shmob_drm_kms.h | 29 - drivers/gpu/drm/shmobile/shmob_drm_plane.c | 261 ------- drivers/gpu/drm/shmobile/shmob_drm_plane.h | 19 - drivers/gpu/drm/shmobile/shmob_drm_regs.h | 310 -------- 15 files changed, 1976 deletions(-) delete mode 100644 drivers/gpu/drm/shmobile/Kconfig delete mode 100644 drivers/gpu/drm/shmobile/Makefile delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_backlight.c delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_backlight.h delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_crtc.c delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_crtc.h delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_drv.c delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_drv.h delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_kms.c delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_kms.h delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_plane.c delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_plane.h delete mode 100644 drivers/gpu/drm/shmobile/shmob_drm_regs.h diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig index 315cbdf6197927..1cb4bcb0714c87 100644 --- a/drivers/gpu/drm/Kconfig +++ b/drivers/gpu/drm/Kconfig @@ -286,8 +286,6 @@ source "drivers/gpu/drm/atmel-hlcdc/Kconfig" source "drivers/gpu/drm/rcar-du/Kconfig" -source "drivers/gpu/drm/shmobile/Kconfig" - source "drivers/gpu/drm/sun4i/Kconfig" source "drivers/gpu/drm/omapdrm/Kconfig" diff --git a/drivers/gpu/drm/Makefile b/drivers/gpu/drm/Makefile index cc637343d87b09..87709cf7db8145 100644 --- a/drivers/gpu/drm/Makefile +++ b/drivers/gpu/drm/Makefile @@ -160,7 +160,6 @@ obj-$(CONFIG_DRM_AST) += ast/ obj-$(CONFIG_DRM_ARMADA) += armada/ obj-$(CONFIG_DRM_ATMEL_HLCDC) += atmel-hlcdc/ obj-y += rcar-du/ -obj-$(CONFIG_DRM_SHMOBILE) +=shmobile/ obj-y += omapdrm/ obj-$(CONFIG_DRM_SUN4I) += sun4i/ obj-y += tilcdc/ diff --git a/drivers/gpu/drm/shmobile/Kconfig b/drivers/gpu/drm/shmobile/Kconfig deleted file mode 100644 index 4ec5dc74a6b0b8..00000000000000 --- a/drivers/gpu/drm/shmobile/Kconfig +++ /dev/null @@ -1,12 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -config DRM_SHMOBILE - tristate "DRM Support for SH Mobile" - depends on DRM && ARM - depends on ARCH_SHMOBILE || COMPILE_TEST - select BACKLIGHT_CLASS_DEVICE - select DRM_KMS_HELPER - select DRM_GEM_DMA_HELPER - help - Choose this option if you have an SH Mobile chipset. - If M is selected the module will be called shmob-drm. - diff --git a/drivers/gpu/drm/shmobile/Makefile b/drivers/gpu/drm/shmobile/Makefile deleted file mode 100644 index 861edafed8562c..00000000000000 --- a/drivers/gpu/drm/shmobile/Makefile +++ /dev/null @@ -1,8 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -shmob-drm-y := shmob_drm_backlight.o \ - shmob_drm_crtc.o \ - shmob_drm_drv.o \ - shmob_drm_kms.o \ - shmob_drm_plane.o - -obj-$(CONFIG_DRM_SHMOBILE) += shmob-drm.o diff --git a/drivers/gpu/drm/shmobile/shmob_drm_backlight.c b/drivers/gpu/drm/shmobile/shmob_drm_backlight.c deleted file mode 100644 index 794573badfe860..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_backlight.c +++ /dev/null @@ -1,82 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * shmob_drm_backlight.c -- SH Mobile DRM Backlight - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#include - -#include "shmob_drm_backlight.h" -#include "shmob_drm_crtc.h" -#include "shmob_drm_drv.h" - -static int shmob_drm_backlight_update(struct backlight_device *bdev) -{ - struct shmob_drm_connector *scon = bl_get_data(bdev); - struct shmob_drm_device *sdev = scon->connector.dev->dev_private; - const struct shmob_drm_backlight_data *bdata = &sdev->pdata->backlight; - int brightness = backlight_get_brightness(bdev); - - return bdata->set_brightness(brightness); -} - -static int shmob_drm_backlight_get_brightness(struct backlight_device *bdev) -{ - struct shmob_drm_connector *scon = bl_get_data(bdev); - struct shmob_drm_device *sdev = scon->connector.dev->dev_private; - const struct shmob_drm_backlight_data *bdata = &sdev->pdata->backlight; - - return bdata->get_brightness(); -} - -static const struct backlight_ops shmob_drm_backlight_ops = { - .options = BL_CORE_SUSPENDRESUME, - .update_status = shmob_drm_backlight_update, - .get_brightness = shmob_drm_backlight_get_brightness, -}; - -void shmob_drm_backlight_dpms(struct shmob_drm_connector *scon, int mode) -{ - if (scon->backlight == NULL) - return; - - scon->backlight->props.power = mode == DRM_MODE_DPMS_ON - ? FB_BLANK_UNBLANK : FB_BLANK_POWERDOWN; - backlight_update_status(scon->backlight); -} - -int shmob_drm_backlight_init(struct shmob_drm_connector *scon) -{ - struct shmob_drm_device *sdev = scon->connector.dev->dev_private; - const struct shmob_drm_backlight_data *bdata = &sdev->pdata->backlight; - struct drm_connector *connector = &scon->connector; - struct drm_device *dev = connector->dev; - struct backlight_device *backlight; - - if (!bdata->max_brightness) - return 0; - - backlight = backlight_device_register(bdata->name, dev->dev, scon, - &shmob_drm_backlight_ops, NULL); - if (IS_ERR(backlight)) { - dev_err(dev->dev, "unable to register backlight device: %ld\n", - PTR_ERR(backlight)); - return PTR_ERR(backlight); - } - - backlight->props.max_brightness = bdata->max_brightness; - backlight->props.brightness = bdata->max_brightness; - backlight->props.power = FB_BLANK_POWERDOWN; - backlight_update_status(backlight); - - scon->backlight = backlight; - return 0; -} - -void shmob_drm_backlight_exit(struct shmob_drm_connector *scon) -{ - backlight_device_unregister(scon->backlight); -} diff --git a/drivers/gpu/drm/shmobile/shmob_drm_backlight.h b/drivers/gpu/drm/shmobile/shmob_drm_backlight.h deleted file mode 100644 index d9abb7a60be5c4..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_backlight.h +++ /dev/null @@ -1,19 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm_backlight.h -- SH Mobile DRM Backlight - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_BACKLIGHT_H__ -#define __SHMOB_DRM_BACKLIGHT_H__ - -struct shmob_drm_connector; - -void shmob_drm_backlight_dpms(struct shmob_drm_connector *scon, int mode); -int shmob_drm_backlight_init(struct shmob_drm_connector *scon); -void shmob_drm_backlight_exit(struct shmob_drm_connector *scon); - -#endif /* __SHMOB_DRM_BACKLIGHT_H__ */ diff --git a/drivers/gpu/drm/shmobile/shmob_drm_crtc.c b/drivers/gpu/drm/shmobile/shmob_drm_crtc.c deleted file mode 100644 index 4624c0aff51ffa..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_crtc.c +++ /dev/null @@ -1,683 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * shmob_drm_crtc.c -- SH Mobile DRM CRTCs - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "shmob_drm_backlight.h" -#include "shmob_drm_crtc.h" -#include "shmob_drm_drv.h" -#include "shmob_drm_kms.h" -#include "shmob_drm_plane.h" -#include "shmob_drm_regs.h" - -/* - * TODO: panel support - */ - -/* ----------------------------------------------------------------------------- - * Clock management - */ - -static int shmob_drm_clk_on(struct shmob_drm_device *sdev) -{ - int ret; - - if (sdev->clock) { - ret = clk_prepare_enable(sdev->clock); - if (ret < 0) - return ret; - } - - return 0; -} - -static void shmob_drm_clk_off(struct shmob_drm_device *sdev) -{ - if (sdev->clock) - clk_disable_unprepare(sdev->clock); -} - -/* ----------------------------------------------------------------------------- - * CRTC - */ - -static void shmob_drm_crtc_setup_geometry(struct shmob_drm_crtc *scrtc) -{ - struct drm_crtc *crtc = &scrtc->crtc; - struct shmob_drm_device *sdev = crtc->dev->dev_private; - const struct shmob_drm_interface_data *idata = &sdev->pdata->iface; - const struct drm_display_mode *mode = &crtc->mode; - u32 value; - - value = sdev->ldmt1r - | ((mode->flags & DRM_MODE_FLAG_PVSYNC) ? 0 : LDMT1R_VPOL) - | ((mode->flags & DRM_MODE_FLAG_PHSYNC) ? 0 : LDMT1R_HPOL) - | ((idata->flags & SHMOB_DRM_IFACE_FL_DWPOL) ? LDMT1R_DWPOL : 0) - | ((idata->flags & SHMOB_DRM_IFACE_FL_DIPOL) ? LDMT1R_DIPOL : 0) - | ((idata->flags & SHMOB_DRM_IFACE_FL_DAPOL) ? LDMT1R_DAPOL : 0) - | ((idata->flags & SHMOB_DRM_IFACE_FL_HSCNT) ? LDMT1R_HSCNT : 0) - | ((idata->flags & SHMOB_DRM_IFACE_FL_DWCNT) ? LDMT1R_DWCNT : 0); - lcdc_write(sdev, LDMT1R, value); - - if (idata->interface >= SHMOB_DRM_IFACE_SYS8A && - idata->interface <= SHMOB_DRM_IFACE_SYS24) { - /* Setup SYS bus. */ - value = (idata->sys.cs_setup << LDMT2R_CSUP_SHIFT) - | (idata->sys.vsync_active_high ? LDMT2R_RSV : 0) - | (idata->sys.vsync_dir_input ? LDMT2R_VSEL : 0) - | (idata->sys.write_setup << LDMT2R_WCSC_SHIFT) - | (idata->sys.write_cycle << LDMT2R_WCEC_SHIFT) - | (idata->sys.write_strobe << LDMT2R_WCLW_SHIFT); - lcdc_write(sdev, LDMT2R, value); - - value = (idata->sys.read_latch << LDMT3R_RDLC_SHIFT) - | (idata->sys.read_setup << LDMT3R_RCSC_SHIFT) - | (idata->sys.read_cycle << LDMT3R_RCEC_SHIFT) - | (idata->sys.read_strobe << LDMT3R_RCLW_SHIFT); - lcdc_write(sdev, LDMT3R, value); - } - - value = ((mode->hdisplay / 8) << 16) /* HDCN */ - | (mode->htotal / 8); /* HTCN */ - lcdc_write(sdev, LDHCNR, value); - - value = (((mode->hsync_end - mode->hsync_start) / 8) << 16) /* HSYNW */ - | (mode->hsync_start / 8); /* HSYNP */ - lcdc_write(sdev, LDHSYNR, value); - - value = ((mode->hdisplay & 7) << 24) | ((mode->htotal & 7) << 16) - | (((mode->hsync_end - mode->hsync_start) & 7) << 8) - | (mode->hsync_start & 7); - lcdc_write(sdev, LDHAJR, value); - - value = ((mode->vdisplay) << 16) /* VDLN */ - | mode->vtotal; /* VTLN */ - lcdc_write(sdev, LDVLNR, value); - - value = ((mode->vsync_end - mode->vsync_start) << 16) /* VSYNW */ - | mode->vsync_start; /* VSYNP */ - lcdc_write(sdev, LDVSYNR, value); -} - -static void shmob_drm_crtc_start_stop(struct shmob_drm_crtc *scrtc, bool start) -{ - struct shmob_drm_device *sdev = scrtc->crtc.dev->dev_private; - u32 value; - - value = lcdc_read(sdev, LDCNT2R); - if (start) - lcdc_write(sdev, LDCNT2R, value | LDCNT2R_DO); - else - lcdc_write(sdev, LDCNT2R, value & ~LDCNT2R_DO); - - /* Wait until power is applied/stopped. */ - while (1) { - value = lcdc_read(sdev, LDPMR) & LDPMR_LPS; - if ((start && value) || (!start && !value)) - break; - - cpu_relax(); - } - - if (!start) { - /* Stop the dot clock. */ - lcdc_write(sdev, LDDCKSTPR, LDDCKSTPR_DCKSTP); - } -} - -/* - * shmob_drm_crtc_start - Configure and start the LCDC - * @scrtc: the SH Mobile CRTC - * - * Configure and start the LCDC device. External devices (clocks, MERAM, panels, - * ...) are not touched by this function. - */ -static void shmob_drm_crtc_start(struct shmob_drm_crtc *scrtc) -{ - struct drm_crtc *crtc = &scrtc->crtc; - struct shmob_drm_device *sdev = crtc->dev->dev_private; - const struct shmob_drm_interface_data *idata = &sdev->pdata->iface; - const struct shmob_drm_format_info *format; - struct drm_device *dev = sdev->ddev; - struct drm_plane *plane; - u32 value; - int ret; - - if (scrtc->started) - return; - - format = shmob_drm_format_info(crtc->primary->fb->format->format); - if (WARN_ON(format == NULL)) - return; - - /* Enable clocks before accessing the hardware. */ - ret = shmob_drm_clk_on(sdev); - if (ret < 0) - return; - - /* Reset and enable the LCDC. */ - lcdc_write(sdev, LDCNT2R, lcdc_read(sdev, LDCNT2R) | LDCNT2R_BR); - lcdc_wait_bit(sdev, LDCNT2R, LDCNT2R_BR, 0); - lcdc_write(sdev, LDCNT2R, LDCNT2R_ME); - - /* Stop the LCDC first and disable all interrupts. */ - shmob_drm_crtc_start_stop(scrtc, false); - lcdc_write(sdev, LDINTR, 0); - - /* Configure power supply, dot clocks and start them. */ - lcdc_write(sdev, LDPMR, 0); - - value = sdev->lddckr; - if (idata->clk_div) { - /* FIXME: sh7724 can only use 42, 48, 54 and 60 for the divider - * denominator. - */ - lcdc_write(sdev, LDDCKPAT1R, 0); - lcdc_write(sdev, LDDCKPAT2R, (1 << (idata->clk_div / 2)) - 1); - - if (idata->clk_div == 1) - value |= LDDCKR_MOSEL; - else - value |= idata->clk_div; - } - - lcdc_write(sdev, LDDCKR, value); - lcdc_write(sdev, LDDCKSTPR, 0); - lcdc_wait_bit(sdev, LDDCKSTPR, ~0, 0); - - /* TODO: Setup SYS panel */ - - /* Setup geometry, format, frame buffer memory and operation mode. */ - shmob_drm_crtc_setup_geometry(scrtc); - - /* TODO: Handle YUV colorspaces. Hardcode REC709 for now. */ - lcdc_write(sdev, LDDFR, format->lddfr | LDDFR_CF1); - lcdc_write(sdev, LDMLSR, scrtc->line_size); - lcdc_write(sdev, LDSA1R, scrtc->dma[0]); - if (format->yuv) - lcdc_write(sdev, LDSA2R, scrtc->dma[1]); - lcdc_write(sdev, LDSM1R, 0); - - /* Word and long word swap. */ - switch (format->fourcc) { - case DRM_FORMAT_RGB565: - case DRM_FORMAT_NV21: - case DRM_FORMAT_NV61: - case DRM_FORMAT_NV42: - value = LDDDSR_LS | LDDDSR_WS; - break; - case DRM_FORMAT_RGB888: - case DRM_FORMAT_NV12: - case DRM_FORMAT_NV16: - case DRM_FORMAT_NV24: - value = LDDDSR_LS | LDDDSR_WS | LDDDSR_BS; - break; - case DRM_FORMAT_ARGB8888: - default: - value = LDDDSR_LS; - break; - } - lcdc_write(sdev, LDDDSR, value); - - /* Setup planes. */ - drm_for_each_legacy_plane(plane, dev) { - if (plane->crtc == crtc) - shmob_drm_plane_setup(plane); - } - - /* Enable the display output. */ - lcdc_write(sdev, LDCNT1R, LDCNT1R_DE); - - shmob_drm_crtc_start_stop(scrtc, true); - - scrtc->started = true; -} - -static void shmob_drm_crtc_stop(struct shmob_drm_crtc *scrtc) -{ - struct drm_crtc *crtc = &scrtc->crtc; - struct shmob_drm_device *sdev = crtc->dev->dev_private; - - if (!scrtc->started) - return; - - /* Stop the LCDC. */ - shmob_drm_crtc_start_stop(scrtc, false); - - /* Disable the display output. */ - lcdc_write(sdev, LDCNT1R, 0); - - /* Stop clocks. */ - shmob_drm_clk_off(sdev); - - scrtc->started = false; -} - -void shmob_drm_crtc_suspend(struct shmob_drm_crtc *scrtc) -{ - shmob_drm_crtc_stop(scrtc); -} - -void shmob_drm_crtc_resume(struct shmob_drm_crtc *scrtc) -{ - if (scrtc->dpms != DRM_MODE_DPMS_ON) - return; - - shmob_drm_crtc_start(scrtc); -} - -static void shmob_drm_crtc_compute_base(struct shmob_drm_crtc *scrtc, - int x, int y) -{ - struct drm_crtc *crtc = &scrtc->crtc; - struct drm_framebuffer *fb = crtc->primary->fb; - struct drm_gem_dma_object *gem; - unsigned int bpp; - - bpp = scrtc->format->yuv ? 8 : scrtc->format->bpp; - gem = drm_fb_dma_get_gem_obj(fb, 0); - scrtc->dma[0] = gem->dma_addr + fb->offsets[0] - + y * fb->pitches[0] + x * bpp / 8; - - if (scrtc->format->yuv) { - bpp = scrtc->format->bpp - 8; - gem = drm_fb_dma_get_gem_obj(fb, 1); - scrtc->dma[1] = gem->dma_addr + fb->offsets[1] - + y / (bpp == 4 ? 2 : 1) * fb->pitches[1] - + x * (bpp == 16 ? 2 : 1); - } -} - -static void shmob_drm_crtc_update_base(struct shmob_drm_crtc *scrtc) -{ - struct drm_crtc *crtc = &scrtc->crtc; - struct shmob_drm_device *sdev = crtc->dev->dev_private; - - shmob_drm_crtc_compute_base(scrtc, crtc->x, crtc->y); - - lcdc_write_mirror(sdev, LDSA1R, scrtc->dma[0]); - if (scrtc->format->yuv) - lcdc_write_mirror(sdev, LDSA2R, scrtc->dma[1]); - - lcdc_write(sdev, LDRCNTR, lcdc_read(sdev, LDRCNTR) ^ LDRCNTR_MRS); -} - -#define to_shmob_crtc(c) container_of(c, struct shmob_drm_crtc, crtc) - -static void shmob_drm_crtc_dpms(struct drm_crtc *crtc, int mode) -{ - struct shmob_drm_crtc *scrtc = to_shmob_crtc(crtc); - - if (scrtc->dpms == mode) - return; - - if (mode == DRM_MODE_DPMS_ON) - shmob_drm_crtc_start(scrtc); - else - shmob_drm_crtc_stop(scrtc); - - scrtc->dpms = mode; -} - -static void shmob_drm_crtc_mode_prepare(struct drm_crtc *crtc) -{ - shmob_drm_crtc_dpms(crtc, DRM_MODE_DPMS_OFF); -} - -static int shmob_drm_crtc_mode_set(struct drm_crtc *crtc, - struct drm_display_mode *mode, - struct drm_display_mode *adjusted_mode, - int x, int y, - struct drm_framebuffer *old_fb) -{ - struct shmob_drm_crtc *scrtc = to_shmob_crtc(crtc); - struct shmob_drm_device *sdev = crtc->dev->dev_private; - const struct shmob_drm_format_info *format; - - format = shmob_drm_format_info(crtc->primary->fb->format->format); - if (format == NULL) { - dev_dbg(sdev->dev, "mode_set: unsupported format %08x\n", - crtc->primary->fb->format->format); - return -EINVAL; - } - - scrtc->format = format; - scrtc->line_size = crtc->primary->fb->pitches[0]; - - shmob_drm_crtc_compute_base(scrtc, x, y); - - return 0; -} - -static void shmob_drm_crtc_mode_commit(struct drm_crtc *crtc) -{ - shmob_drm_crtc_dpms(crtc, DRM_MODE_DPMS_ON); -} - -static int shmob_drm_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, - struct drm_framebuffer *old_fb) -{ - shmob_drm_crtc_update_base(to_shmob_crtc(crtc)); - - return 0; -} - -static const struct drm_crtc_helper_funcs crtc_helper_funcs = { - .dpms = shmob_drm_crtc_dpms, - .prepare = shmob_drm_crtc_mode_prepare, - .commit = shmob_drm_crtc_mode_commit, - .mode_set = shmob_drm_crtc_mode_set, - .mode_set_base = shmob_drm_crtc_mode_set_base, -}; - -void shmob_drm_crtc_finish_page_flip(struct shmob_drm_crtc *scrtc) -{ - struct drm_pending_vblank_event *event; - struct drm_device *dev = scrtc->crtc.dev; - unsigned long flags; - - spin_lock_irqsave(&dev->event_lock, flags); - event = scrtc->event; - scrtc->event = NULL; - if (event) { - drm_crtc_send_vblank_event(&scrtc->crtc, event); - drm_crtc_vblank_put(&scrtc->crtc); - } - spin_unlock_irqrestore(&dev->event_lock, flags); -} - -static int shmob_drm_crtc_page_flip(struct drm_crtc *crtc, - struct drm_framebuffer *fb, - struct drm_pending_vblank_event *event, - uint32_t page_flip_flags, - struct drm_modeset_acquire_ctx *ctx) -{ - struct shmob_drm_crtc *scrtc = to_shmob_crtc(crtc); - struct drm_device *dev = scrtc->crtc.dev; - unsigned long flags; - - spin_lock_irqsave(&dev->event_lock, flags); - if (scrtc->event != NULL) { - spin_unlock_irqrestore(&dev->event_lock, flags); - return -EBUSY; - } - spin_unlock_irqrestore(&dev->event_lock, flags); - - crtc->primary->fb = fb; - shmob_drm_crtc_update_base(scrtc); - - if (event) { - event->pipe = 0; - drm_crtc_vblank_get(&scrtc->crtc); - spin_lock_irqsave(&dev->event_lock, flags); - scrtc->event = event; - spin_unlock_irqrestore(&dev->event_lock, flags); - } - - return 0; -} - -static void shmob_drm_crtc_enable_vblank(struct shmob_drm_device *sdev, - bool enable) -{ - unsigned long flags; - u32 ldintr; - - /* Be careful not to acknowledge any pending interrupt. */ - spin_lock_irqsave(&sdev->irq_lock, flags); - ldintr = lcdc_read(sdev, LDINTR) | LDINTR_STATUS_MASK; - if (enable) - ldintr |= LDINTR_VEE; - else - ldintr &= ~LDINTR_VEE; - lcdc_write(sdev, LDINTR, ldintr); - spin_unlock_irqrestore(&sdev->irq_lock, flags); -} - -static int shmob_drm_enable_vblank(struct drm_crtc *crtc) -{ - struct shmob_drm_device *sdev = crtc->dev->dev_private; - - shmob_drm_crtc_enable_vblank(sdev, true); - - return 0; -} - -static void shmob_drm_disable_vblank(struct drm_crtc *crtc) -{ - struct shmob_drm_device *sdev = crtc->dev->dev_private; - - shmob_drm_crtc_enable_vblank(sdev, false); -} - -static const struct drm_crtc_funcs crtc_funcs = { - .destroy = drm_crtc_cleanup, - .set_config = drm_crtc_helper_set_config, - .page_flip = shmob_drm_crtc_page_flip, - .enable_vblank = shmob_drm_enable_vblank, - .disable_vblank = shmob_drm_disable_vblank, -}; - -int shmob_drm_crtc_create(struct shmob_drm_device *sdev) -{ - struct drm_crtc *crtc = &sdev->crtc.crtc; - int ret; - - sdev->crtc.dpms = DRM_MODE_DPMS_OFF; - - ret = drm_crtc_init(sdev->ddev, crtc, &crtc_funcs); - if (ret < 0) - return ret; - - drm_crtc_helper_add(crtc, &crtc_helper_funcs); - - return 0; -} - -/* ----------------------------------------------------------------------------- - * Encoder - */ - -#define to_shmob_encoder(e) \ - container_of(e, struct shmob_drm_encoder, encoder) - -static void shmob_drm_encoder_dpms(struct drm_encoder *encoder, int mode) -{ - struct shmob_drm_encoder *senc = to_shmob_encoder(encoder); - struct shmob_drm_device *sdev = encoder->dev->dev_private; - struct shmob_drm_connector *scon = &sdev->connector; - - if (senc->dpms == mode) - return; - - shmob_drm_backlight_dpms(scon, mode); - - senc->dpms = mode; -} - -static bool shmob_drm_encoder_mode_fixup(struct drm_encoder *encoder, - const struct drm_display_mode *mode, - struct drm_display_mode *adjusted_mode) -{ - struct drm_device *dev = encoder->dev; - struct shmob_drm_device *sdev = dev->dev_private; - struct drm_connector *connector = &sdev->connector.connector; - const struct drm_display_mode *panel_mode; - - if (list_empty(&connector->modes)) { - dev_dbg(dev->dev, "mode_fixup: empty modes list\n"); - return false; - } - - /* The flat panel mode is fixed, just copy it to the adjusted mode. */ - panel_mode = list_first_entry(&connector->modes, - struct drm_display_mode, head); - drm_mode_copy(adjusted_mode, panel_mode); - - return true; -} - -static void shmob_drm_encoder_mode_prepare(struct drm_encoder *encoder) -{ - /* No-op, everything is handled in the CRTC code. */ -} - -static void shmob_drm_encoder_mode_set(struct drm_encoder *encoder, - struct drm_display_mode *mode, - struct drm_display_mode *adjusted_mode) -{ - /* No-op, everything is handled in the CRTC code. */ -} - -static void shmob_drm_encoder_mode_commit(struct drm_encoder *encoder) -{ - /* No-op, everything is handled in the CRTC code. */ -} - -static const struct drm_encoder_helper_funcs encoder_helper_funcs = { - .dpms = shmob_drm_encoder_dpms, - .mode_fixup = shmob_drm_encoder_mode_fixup, - .prepare = shmob_drm_encoder_mode_prepare, - .commit = shmob_drm_encoder_mode_commit, - .mode_set = shmob_drm_encoder_mode_set, -}; - -int shmob_drm_encoder_create(struct shmob_drm_device *sdev) -{ - struct drm_encoder *encoder = &sdev->encoder.encoder; - int ret; - - sdev->encoder.dpms = DRM_MODE_DPMS_OFF; - - encoder->possible_crtcs = 1; - - ret = drm_simple_encoder_init(sdev->ddev, encoder, - DRM_MODE_ENCODER_LVDS); - if (ret < 0) - return ret; - - drm_encoder_helper_add(encoder, &encoder_helper_funcs); - - return 0; -} - -/* ----------------------------------------------------------------------------- - * Connector - */ - -#define to_shmob_connector(c) \ - container_of(c, struct shmob_drm_connector, connector) - -static int shmob_drm_connector_get_modes(struct drm_connector *connector) -{ - struct shmob_drm_device *sdev = connector->dev->dev_private; - struct drm_display_mode *mode; - - mode = drm_mode_create(connector->dev); - if (mode == NULL) - return 0; - - mode->type = DRM_MODE_TYPE_PREFERRED | DRM_MODE_TYPE_DRIVER; - mode->clock = sdev->pdata->panel.mode.clock; - mode->hdisplay = sdev->pdata->panel.mode.hdisplay; - mode->hsync_start = sdev->pdata->panel.mode.hsync_start; - mode->hsync_end = sdev->pdata->panel.mode.hsync_end; - mode->htotal = sdev->pdata->panel.mode.htotal; - mode->vdisplay = sdev->pdata->panel.mode.vdisplay; - mode->vsync_start = sdev->pdata->panel.mode.vsync_start; - mode->vsync_end = sdev->pdata->panel.mode.vsync_end; - mode->vtotal = sdev->pdata->panel.mode.vtotal; - mode->flags = sdev->pdata->panel.mode.flags; - - drm_mode_set_name(mode); - drm_mode_probed_add(connector, mode); - - connector->display_info.width_mm = sdev->pdata->panel.width_mm; - connector->display_info.height_mm = sdev->pdata->panel.height_mm; - - return 1; -} - -static struct drm_encoder * -shmob_drm_connector_best_encoder(struct drm_connector *connector) -{ - struct shmob_drm_connector *scon = to_shmob_connector(connector); - - return scon->encoder; -} - -static const struct drm_connector_helper_funcs connector_helper_funcs = { - .get_modes = shmob_drm_connector_get_modes, - .best_encoder = shmob_drm_connector_best_encoder, -}; - -static void shmob_drm_connector_destroy(struct drm_connector *connector) -{ - struct shmob_drm_connector *scon = to_shmob_connector(connector); - - shmob_drm_backlight_exit(scon); - drm_connector_unregister(connector); - drm_connector_cleanup(connector); -} - -static const struct drm_connector_funcs connector_funcs = { - .dpms = drm_helper_connector_dpms, - .fill_modes = drm_helper_probe_single_connector_modes, - .destroy = shmob_drm_connector_destroy, -}; - -int shmob_drm_connector_create(struct shmob_drm_device *sdev, - struct drm_encoder *encoder) -{ - struct drm_connector *connector = &sdev->connector.connector; - int ret; - - sdev->connector.encoder = encoder; - - connector->display_info.width_mm = sdev->pdata->panel.width_mm; - connector->display_info.height_mm = sdev->pdata->panel.height_mm; - - ret = drm_connector_init(sdev->ddev, connector, &connector_funcs, - DRM_MODE_CONNECTOR_LVDS); - if (ret < 0) - return ret; - - drm_connector_helper_add(connector, &connector_helper_funcs); - - ret = shmob_drm_backlight_init(&sdev->connector); - if (ret < 0) - goto err_cleanup; - - ret = drm_connector_attach_encoder(connector, encoder); - if (ret < 0) - goto err_backlight; - - drm_helper_connector_dpms(connector, DRM_MODE_DPMS_OFF); - drm_object_property_set_value(&connector->base, - sdev->ddev->mode_config.dpms_property, DRM_MODE_DPMS_OFF); - - return 0; - -err_backlight: - shmob_drm_backlight_exit(&sdev->connector); -err_cleanup: - drm_connector_cleanup(connector); - return ret; -} diff --git a/drivers/gpu/drm/shmobile/shmob_drm_crtc.h b/drivers/gpu/drm/shmobile/shmob_drm_crtc.h deleted file mode 100644 index 21718843f46d3d..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_crtc.h +++ /dev/null @@ -1,55 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm_crtc.h -- SH Mobile DRM CRTCs - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_CRTC_H__ -#define __SHMOB_DRM_CRTC_H__ - -#include -#include -#include - -struct backlight_device; -struct drm_pending_vblank_event; -struct shmob_drm_device; -struct shmob_drm_format_info; - -struct shmob_drm_crtc { - struct drm_crtc crtc; - - struct drm_pending_vblank_event *event; - int dpms; - - const struct shmob_drm_format_info *format; - unsigned long dma[2]; - unsigned int line_size; - bool started; -}; - -struct shmob_drm_encoder { - struct drm_encoder encoder; - int dpms; -}; - -struct shmob_drm_connector { - struct drm_connector connector; - struct drm_encoder *encoder; - - struct backlight_device *backlight; -}; - -int shmob_drm_crtc_create(struct shmob_drm_device *sdev); -void shmob_drm_crtc_finish_page_flip(struct shmob_drm_crtc *scrtc); -void shmob_drm_crtc_suspend(struct shmob_drm_crtc *scrtc); -void shmob_drm_crtc_resume(struct shmob_drm_crtc *scrtc); - -int shmob_drm_encoder_create(struct shmob_drm_device *sdev); -int shmob_drm_connector_create(struct shmob_drm_device *sdev, - struct drm_encoder *encoder); - -#endif /* __SHMOB_DRM_CRTC_H__ */ diff --git a/drivers/gpu/drm/shmobile/shmob_drm_drv.c b/drivers/gpu/drm/shmobile/shmob_drm_drv.c deleted file mode 100644 index 3d511fa3891364..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_drv.c +++ /dev/null @@ -1,303 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * shmob_drm_drv.c -- SH Mobile DRM driver - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include "shmob_drm_drv.h" -#include "shmob_drm_kms.h" -#include "shmob_drm_plane.h" -#include "shmob_drm_regs.h" - -/* ----------------------------------------------------------------------------- - * Hardware initialization - */ - -static int shmob_drm_init_interface(struct shmob_drm_device *sdev) -{ - static const u32 ldmt1r[] = { - [SHMOB_DRM_IFACE_RGB8] = LDMT1R_MIFTYP_RGB8, - [SHMOB_DRM_IFACE_RGB9] = LDMT1R_MIFTYP_RGB9, - [SHMOB_DRM_IFACE_RGB12A] = LDMT1R_MIFTYP_RGB12A, - [SHMOB_DRM_IFACE_RGB12B] = LDMT1R_MIFTYP_RGB12B, - [SHMOB_DRM_IFACE_RGB16] = LDMT1R_MIFTYP_RGB16, - [SHMOB_DRM_IFACE_RGB18] = LDMT1R_MIFTYP_RGB18, - [SHMOB_DRM_IFACE_RGB24] = LDMT1R_MIFTYP_RGB24, - [SHMOB_DRM_IFACE_YUV422] = LDMT1R_MIFTYP_YCBCR, - [SHMOB_DRM_IFACE_SYS8A] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS8A, - [SHMOB_DRM_IFACE_SYS8B] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS8B, - [SHMOB_DRM_IFACE_SYS8C] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS8C, - [SHMOB_DRM_IFACE_SYS8D] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS8D, - [SHMOB_DRM_IFACE_SYS9] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS9, - [SHMOB_DRM_IFACE_SYS12] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS12, - [SHMOB_DRM_IFACE_SYS16A] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS16A, - [SHMOB_DRM_IFACE_SYS16B] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS16B, - [SHMOB_DRM_IFACE_SYS16C] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS16C, - [SHMOB_DRM_IFACE_SYS18] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS18, - [SHMOB_DRM_IFACE_SYS24] = LDMT1R_IFM | LDMT1R_MIFTYP_SYS24, - }; - - if (sdev->pdata->iface.interface >= ARRAY_SIZE(ldmt1r)) { - dev_err(sdev->dev, "invalid interface type %u\n", - sdev->pdata->iface.interface); - return -EINVAL; - } - - sdev->ldmt1r = ldmt1r[sdev->pdata->iface.interface]; - return 0; -} - -static int shmob_drm_setup_clocks(struct shmob_drm_device *sdev, - enum shmob_drm_clk_source clksrc) -{ - struct clk *clk; - char *clkname; - - switch (clksrc) { - case SHMOB_DRM_CLK_BUS: - clkname = "bus_clk"; - sdev->lddckr = LDDCKR_ICKSEL_BUS; - break; - case SHMOB_DRM_CLK_PERIPHERAL: - clkname = "peripheral_clk"; - sdev->lddckr = LDDCKR_ICKSEL_MIPI; - break; - case SHMOB_DRM_CLK_EXTERNAL: - clkname = NULL; - sdev->lddckr = LDDCKR_ICKSEL_HDMI; - break; - default: - return -EINVAL; - } - - clk = devm_clk_get(sdev->dev, clkname); - if (IS_ERR(clk)) { - dev_err(sdev->dev, "cannot get dot clock %s\n", clkname); - return PTR_ERR(clk); - } - - sdev->clock = clk; - return 0; -} - -/* ----------------------------------------------------------------------------- - * DRM operations - */ - -static irqreturn_t shmob_drm_irq(int irq, void *arg) -{ - struct drm_device *dev = arg; - struct shmob_drm_device *sdev = dev->dev_private; - unsigned long flags; - u32 status; - - /* Acknowledge interrupts. Putting interrupt enable and interrupt flag - * bits in the same register is really brain-dead design and requires - * taking a spinlock. - */ - spin_lock_irqsave(&sdev->irq_lock, flags); - status = lcdc_read(sdev, LDINTR); - lcdc_write(sdev, LDINTR, status ^ LDINTR_STATUS_MASK); - spin_unlock_irqrestore(&sdev->irq_lock, flags); - - if (status & LDINTR_VES) { - drm_handle_vblank(dev, 0); - shmob_drm_crtc_finish_page_flip(&sdev->crtc); - } - - return IRQ_HANDLED; -} - -DEFINE_DRM_GEM_DMA_FOPS(shmob_drm_fops); - -static const struct drm_driver shmob_drm_driver = { - .driver_features = DRIVER_GEM | DRIVER_MODESET, - DRM_GEM_DMA_DRIVER_OPS, - .fops = &shmob_drm_fops, - .name = "shmob-drm", - .desc = "Renesas SH Mobile DRM", - .date = "20120424", - .major = 1, - .minor = 0, -}; - -/* ----------------------------------------------------------------------------- - * Power management - */ - -#ifdef CONFIG_PM_SLEEP -static int shmob_drm_pm_suspend(struct device *dev) -{ - struct shmob_drm_device *sdev = dev_get_drvdata(dev); - - drm_kms_helper_poll_disable(sdev->ddev); - shmob_drm_crtc_suspend(&sdev->crtc); - - return 0; -} - -static int shmob_drm_pm_resume(struct device *dev) -{ - struct shmob_drm_device *sdev = dev_get_drvdata(dev); - - drm_modeset_lock_all(sdev->ddev); - shmob_drm_crtc_resume(&sdev->crtc); - drm_modeset_unlock_all(sdev->ddev); - - drm_kms_helper_poll_enable(sdev->ddev); - return 0; -} -#endif - -static const struct dev_pm_ops shmob_drm_pm_ops = { - SET_SYSTEM_SLEEP_PM_OPS(shmob_drm_pm_suspend, shmob_drm_pm_resume) -}; - -/* ----------------------------------------------------------------------------- - * Platform driver - */ - -static int shmob_drm_remove(struct platform_device *pdev) -{ - struct shmob_drm_device *sdev = platform_get_drvdata(pdev); - struct drm_device *ddev = sdev->ddev; - - drm_dev_unregister(ddev); - drm_kms_helper_poll_fini(ddev); - free_irq(sdev->irq, ddev); - drm_dev_put(ddev); - - return 0; -} - -static int shmob_drm_probe(struct platform_device *pdev) -{ - struct shmob_drm_platform_data *pdata = pdev->dev.platform_data; - struct shmob_drm_device *sdev; - struct drm_device *ddev; - unsigned int i; - int ret; - - if (pdata == NULL) { - dev_err(&pdev->dev, "no platform data\n"); - return -EINVAL; - } - - /* - * Allocate and initialize the driver private data, I/O resources and - * clocks. - */ - sdev = devm_kzalloc(&pdev->dev, sizeof(*sdev), GFP_KERNEL); - if (sdev == NULL) - return -ENOMEM; - - sdev->dev = &pdev->dev; - sdev->pdata = pdata; - spin_lock_init(&sdev->irq_lock); - - platform_set_drvdata(pdev, sdev); - - sdev->mmio = devm_platform_ioremap_resource(pdev, 0); - if (IS_ERR(sdev->mmio)) - return PTR_ERR(sdev->mmio); - - ret = shmob_drm_setup_clocks(sdev, pdata->clk_source); - if (ret < 0) - return ret; - - ret = shmob_drm_init_interface(sdev); - if (ret < 0) - return ret; - - /* Allocate and initialize the DRM device. */ - ddev = drm_dev_alloc(&shmob_drm_driver, &pdev->dev); - if (IS_ERR(ddev)) - return PTR_ERR(ddev); - - sdev->ddev = ddev; - ddev->dev_private = sdev; - - ret = shmob_drm_modeset_init(sdev); - if (ret < 0) { - dev_err(&pdev->dev, "failed to initialize mode setting\n"); - goto err_free_drm_dev; - } - - for (i = 0; i < 4; ++i) { - ret = shmob_drm_plane_create(sdev, i); - if (ret < 0) { - dev_err(&pdev->dev, "failed to create plane %u\n", i); - goto err_modeset_cleanup; - } - } - - ret = drm_vblank_init(ddev, 1); - if (ret < 0) { - dev_err(&pdev->dev, "failed to initialize vblank\n"); - goto err_modeset_cleanup; - } - - ret = platform_get_irq(pdev, 0); - if (ret < 0) - goto err_modeset_cleanup; - sdev->irq = ret; - - ret = request_irq(sdev->irq, shmob_drm_irq, 0, ddev->driver->name, - ddev); - if (ret < 0) { - dev_err(&pdev->dev, "failed to install IRQ handler\n"); - goto err_modeset_cleanup; - } - - /* - * Register the DRM device with the core and the connectors with - * sysfs. - */ - ret = drm_dev_register(ddev, 0); - if (ret < 0) - goto err_irq_uninstall; - - return 0; - -err_irq_uninstall: - free_irq(sdev->irq, ddev); -err_modeset_cleanup: - drm_kms_helper_poll_fini(ddev); -err_free_drm_dev: - drm_dev_put(ddev); - - return ret; -} - -static struct platform_driver shmob_drm_platform_driver = { - .probe = shmob_drm_probe, - .remove = shmob_drm_remove, - .driver = { - .name = "shmob-drm", - .pm = &shmob_drm_pm_ops, - }, -}; - -drm_module_platform_driver(shmob_drm_platform_driver); - -MODULE_AUTHOR("Laurent Pinchart "); -MODULE_DESCRIPTION("Renesas SH Mobile DRM Driver"); -MODULE_LICENSE("GPL"); diff --git a/drivers/gpu/drm/shmobile/shmob_drm_drv.h b/drivers/gpu/drm/shmobile/shmob_drm_drv.h deleted file mode 100644 index 4964ddd5ab7472..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_drv.h +++ /dev/null @@ -1,42 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm.h -- SH Mobile DRM driver - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_DRV_H__ -#define __SHMOB_DRM_DRV_H__ - -#include -#include -#include - -#include "shmob_drm_crtc.h" - -struct clk; -struct device; -struct drm_device; - -struct shmob_drm_device { - struct device *dev; - const struct shmob_drm_platform_data *pdata; - - void __iomem *mmio; - struct clk *clock; - u32 lddckr; - u32 ldmt1r; - - unsigned int irq; - spinlock_t irq_lock; /* Protects hardware LDINTR register */ - - struct drm_device *ddev; - - struct shmob_drm_crtc crtc; - struct shmob_drm_encoder encoder; - struct shmob_drm_connector connector; -}; - -#endif /* __SHMOB_DRM_DRV_H__ */ diff --git a/drivers/gpu/drm/shmobile/shmob_drm_kms.c b/drivers/gpu/drm/shmobile/shmob_drm_kms.c deleted file mode 100644 index 60a2c8d8a0d947..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_kms.c +++ /dev/null @@ -1,150 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * shmob_drm_kms.c -- SH Mobile DRM Mode Setting - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#include -#include -#include -#include -#include -#include - -#include "shmob_drm_crtc.h" -#include "shmob_drm_drv.h" -#include "shmob_drm_kms.h" -#include "shmob_drm_regs.h" - -/* ----------------------------------------------------------------------------- - * Format helpers - */ - -static const struct shmob_drm_format_info shmob_drm_format_infos[] = { - { - .fourcc = DRM_FORMAT_RGB565, - .bpp = 16, - .yuv = false, - .lddfr = LDDFR_PKF_RGB16, - }, { - .fourcc = DRM_FORMAT_RGB888, - .bpp = 24, - .yuv = false, - .lddfr = LDDFR_PKF_RGB24, - }, { - .fourcc = DRM_FORMAT_ARGB8888, - .bpp = 32, - .yuv = false, - .lddfr = LDDFR_PKF_ARGB32, - }, { - .fourcc = DRM_FORMAT_NV12, - .bpp = 12, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_420, - }, { - .fourcc = DRM_FORMAT_NV21, - .bpp = 12, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_420, - }, { - .fourcc = DRM_FORMAT_NV16, - .bpp = 16, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_422, - }, { - .fourcc = DRM_FORMAT_NV61, - .bpp = 16, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_422, - }, { - .fourcc = DRM_FORMAT_NV24, - .bpp = 24, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_444, - }, { - .fourcc = DRM_FORMAT_NV42, - .bpp = 24, - .yuv = true, - .lddfr = LDDFR_CC | LDDFR_YF_444, - }, -}; - -const struct shmob_drm_format_info *shmob_drm_format_info(u32 fourcc) -{ - unsigned int i; - - for (i = 0; i < ARRAY_SIZE(shmob_drm_format_infos); ++i) { - if (shmob_drm_format_infos[i].fourcc == fourcc) - return &shmob_drm_format_infos[i]; - } - - return NULL; -} - -/* ----------------------------------------------------------------------------- - * Frame buffer - */ - -static struct drm_framebuffer * -shmob_drm_fb_create(struct drm_device *dev, struct drm_file *file_priv, - const struct drm_mode_fb_cmd2 *mode_cmd) -{ - const struct shmob_drm_format_info *format; - - format = shmob_drm_format_info(mode_cmd->pixel_format); - if (format == NULL) { - dev_dbg(dev->dev, "unsupported pixel format %08x\n", - mode_cmd->pixel_format); - return ERR_PTR(-EINVAL); - } - - if (mode_cmd->pitches[0] & 7 || mode_cmd->pitches[0] >= 65536) { - dev_dbg(dev->dev, "invalid pitch value %u\n", - mode_cmd->pitches[0]); - return ERR_PTR(-EINVAL); - } - - if (format->yuv) { - unsigned int chroma_cpp = format->bpp == 24 ? 2 : 1; - - if (mode_cmd->pitches[1] != mode_cmd->pitches[0] * chroma_cpp) { - dev_dbg(dev->dev, - "luma and chroma pitches do not match\n"); - return ERR_PTR(-EINVAL); - } - } - - return drm_gem_fb_create(dev, file_priv, mode_cmd); -} - -static const struct drm_mode_config_funcs shmob_drm_mode_config_funcs = { - .fb_create = shmob_drm_fb_create, -}; - -int shmob_drm_modeset_init(struct shmob_drm_device *sdev) -{ - int ret; - - ret = drmm_mode_config_init(sdev->ddev); - if (ret) - return ret; - - shmob_drm_crtc_create(sdev); - shmob_drm_encoder_create(sdev); - shmob_drm_connector_create(sdev, &sdev->encoder.encoder); - - drm_kms_helper_poll_init(sdev->ddev); - - sdev->ddev->mode_config.min_width = 0; - sdev->ddev->mode_config.min_height = 0; - sdev->ddev->mode_config.max_width = 4095; - sdev->ddev->mode_config.max_height = 4095; - sdev->ddev->mode_config.funcs = &shmob_drm_mode_config_funcs; - - drm_helper_disable_unused_functions(sdev->ddev); - - return 0; -} diff --git a/drivers/gpu/drm/shmobile/shmob_drm_kms.h b/drivers/gpu/drm/shmobile/shmob_drm_kms.h deleted file mode 100644 index 0347b1fd2338a8..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_kms.h +++ /dev/null @@ -1,29 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm_kms.h -- SH Mobile DRM Mode Setting - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_KMS_H__ -#define __SHMOB_DRM_KMS_H__ - -#include - -struct drm_gem_dma_object; -struct shmob_drm_device; - -struct shmob_drm_format_info { - u32 fourcc; - unsigned int bpp; - bool yuv; - u32 lddfr; -}; - -const struct shmob_drm_format_info *shmob_drm_format_info(u32 fourcc); - -int shmob_drm_modeset_init(struct shmob_drm_device *sdev); - -#endif /* __SHMOB_DRM_KMS_H__ */ diff --git a/drivers/gpu/drm/shmobile/shmob_drm_plane.c b/drivers/gpu/drm/shmobile/shmob_drm_plane.c deleted file mode 100644 index 6c5f0cbe7d95b9..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_plane.c +++ /dev/null @@ -1,261 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * shmob_drm_plane.c -- SH Mobile DRM Planes - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#include -#include -#include -#include -#include -#include - -#include "shmob_drm_drv.h" -#include "shmob_drm_kms.h" -#include "shmob_drm_plane.h" -#include "shmob_drm_regs.h" - -struct shmob_drm_plane { - struct drm_plane plane; - unsigned int index; - unsigned int alpha; - - const struct shmob_drm_format_info *format; - unsigned long dma[2]; - - unsigned int src_x; - unsigned int src_y; - unsigned int crtc_x; - unsigned int crtc_y; - unsigned int crtc_w; - unsigned int crtc_h; -}; - -#define to_shmob_plane(p) container_of(p, struct shmob_drm_plane, plane) - -static void shmob_drm_plane_compute_base(struct shmob_drm_plane *splane, - struct drm_framebuffer *fb, - int x, int y) -{ - struct drm_gem_dma_object *gem; - unsigned int bpp; - - bpp = splane->format->yuv ? 8 : splane->format->bpp; - gem = drm_fb_dma_get_gem_obj(fb, 0); - splane->dma[0] = gem->dma_addr + fb->offsets[0] - + y * fb->pitches[0] + x * bpp / 8; - - if (splane->format->yuv) { - bpp = splane->format->bpp - 8; - gem = drm_fb_dma_get_gem_obj(fb, 1); - splane->dma[1] = gem->dma_addr + fb->offsets[1] - + y / (bpp == 4 ? 2 : 1) * fb->pitches[1] - + x * (bpp == 16 ? 2 : 1); - } -} - -static void __shmob_drm_plane_setup(struct shmob_drm_plane *splane, - struct drm_framebuffer *fb) -{ - struct shmob_drm_device *sdev = splane->plane.dev->dev_private; - u32 format; - - /* TODO: Support ROP3 mode */ - format = LDBBSIFR_EN | (splane->alpha << LDBBSIFR_LAY_SHIFT); - - switch (splane->format->fourcc) { - case DRM_FORMAT_RGB565: - case DRM_FORMAT_NV21: - case DRM_FORMAT_NV61: - case DRM_FORMAT_NV42: - format |= LDBBSIFR_SWPL | LDBBSIFR_SWPW; - break; - case DRM_FORMAT_RGB888: - case DRM_FORMAT_NV12: - case DRM_FORMAT_NV16: - case DRM_FORMAT_NV24: - format |= LDBBSIFR_SWPL | LDBBSIFR_SWPW | LDBBSIFR_SWPB; - break; - case DRM_FORMAT_ARGB8888: - default: - format |= LDBBSIFR_SWPL; - break; - } - - switch (splane->format->fourcc) { - case DRM_FORMAT_RGB565: - format |= LDBBSIFR_AL_1 | LDBBSIFR_RY | LDBBSIFR_RPKF_RGB16; - break; - case DRM_FORMAT_RGB888: - format |= LDBBSIFR_AL_1 | LDBBSIFR_RY | LDBBSIFR_RPKF_RGB24; - break; - case DRM_FORMAT_ARGB8888: - format |= LDBBSIFR_AL_PK | LDBBSIFR_RY | LDDFR_PKF_ARGB32; - break; - case DRM_FORMAT_NV12: - case DRM_FORMAT_NV21: - format |= LDBBSIFR_AL_1 | LDBBSIFR_CHRR_420; - break; - case DRM_FORMAT_NV16: - case DRM_FORMAT_NV61: - format |= LDBBSIFR_AL_1 | LDBBSIFR_CHRR_422; - break; - case DRM_FORMAT_NV24: - case DRM_FORMAT_NV42: - format |= LDBBSIFR_AL_1 | LDBBSIFR_CHRR_444; - break; - } - -#define plane_reg_dump(sdev, splane, reg) \ - dev_dbg(sdev->ddev->dev, "%s(%u): %s 0x%08x 0x%08x\n", __func__, \ - splane->index, #reg, \ - lcdc_read(sdev, reg(splane->index)), \ - lcdc_read(sdev, reg(splane->index) + LCDC_SIDE_B_OFFSET)) - - plane_reg_dump(sdev, splane, LDBnBSIFR); - plane_reg_dump(sdev, splane, LDBnBSSZR); - plane_reg_dump(sdev, splane, LDBnBLOCR); - plane_reg_dump(sdev, splane, LDBnBSMWR); - plane_reg_dump(sdev, splane, LDBnBSAYR); - plane_reg_dump(sdev, splane, LDBnBSACR); - - lcdc_write(sdev, LDBCR, LDBCR_UPC(splane->index)); - dev_dbg(sdev->ddev->dev, "%s(%u): %s 0x%08x\n", __func__, splane->index, - "LDBCR", lcdc_read(sdev, LDBCR)); - - lcdc_write(sdev, LDBnBSIFR(splane->index), format); - - lcdc_write(sdev, LDBnBSSZR(splane->index), - (splane->crtc_h << LDBBSSZR_BVSS_SHIFT) | - (splane->crtc_w << LDBBSSZR_BHSS_SHIFT)); - lcdc_write(sdev, LDBnBLOCR(splane->index), - (splane->crtc_y << LDBBLOCR_CVLC_SHIFT) | - (splane->crtc_x << LDBBLOCR_CHLC_SHIFT)); - lcdc_write(sdev, LDBnBSMWR(splane->index), - fb->pitches[0] << LDBBSMWR_BSMW_SHIFT); - - shmob_drm_plane_compute_base(splane, fb, splane->src_x, splane->src_y); - - lcdc_write(sdev, LDBnBSAYR(splane->index), splane->dma[0]); - if (splane->format->yuv) - lcdc_write(sdev, LDBnBSACR(splane->index), splane->dma[1]); - - lcdc_write(sdev, LDBCR, - LDBCR_UPF(splane->index) | LDBCR_UPD(splane->index)); - dev_dbg(sdev->ddev->dev, "%s(%u): %s 0x%08x\n", __func__, splane->index, - "LDBCR", lcdc_read(sdev, LDBCR)); - - plane_reg_dump(sdev, splane, LDBnBSIFR); - plane_reg_dump(sdev, splane, LDBnBSSZR); - plane_reg_dump(sdev, splane, LDBnBLOCR); - plane_reg_dump(sdev, splane, LDBnBSMWR); - plane_reg_dump(sdev, splane, LDBnBSAYR); - plane_reg_dump(sdev, splane, LDBnBSACR); -} - -void shmob_drm_plane_setup(struct drm_plane *plane) -{ - struct shmob_drm_plane *splane = to_shmob_plane(plane); - - if (plane->fb == NULL) - return; - - __shmob_drm_plane_setup(splane, plane->fb); -} - -static int -shmob_drm_plane_update(struct drm_plane *plane, struct drm_crtc *crtc, - struct drm_framebuffer *fb, int crtc_x, int crtc_y, - unsigned int crtc_w, unsigned int crtc_h, - uint32_t src_x, uint32_t src_y, - uint32_t src_w, uint32_t src_h, - struct drm_modeset_acquire_ctx *ctx) -{ - struct shmob_drm_plane *splane = to_shmob_plane(plane); - struct shmob_drm_device *sdev = plane->dev->dev_private; - const struct shmob_drm_format_info *format; - - format = shmob_drm_format_info(fb->format->format); - if (format == NULL) { - dev_dbg(sdev->dev, "update_plane: unsupported format %08x\n", - fb->format->format); - return -EINVAL; - } - - if (src_w >> 16 != crtc_w || src_h >> 16 != crtc_h) { - dev_dbg(sdev->dev, "%s: scaling not supported\n", __func__); - return -EINVAL; - } - - splane->format = format; - - splane->src_x = src_x >> 16; - splane->src_y = src_y >> 16; - splane->crtc_x = crtc_x; - splane->crtc_y = crtc_y; - splane->crtc_w = crtc_w; - splane->crtc_h = crtc_h; - - __shmob_drm_plane_setup(splane, fb); - return 0; -} - -static int shmob_drm_plane_disable(struct drm_plane *plane, - struct drm_modeset_acquire_ctx *ctx) -{ - struct shmob_drm_plane *splane = to_shmob_plane(plane); - struct shmob_drm_device *sdev = plane->dev->dev_private; - - splane->format = NULL; - - lcdc_write(sdev, LDBnBSIFR(splane->index), 0); - return 0; -} - -static void shmob_drm_plane_destroy(struct drm_plane *plane) -{ - drm_plane_force_disable(plane); - drm_plane_cleanup(plane); -} - -static const struct drm_plane_funcs shmob_drm_plane_funcs = { - .update_plane = shmob_drm_plane_update, - .disable_plane = shmob_drm_plane_disable, - .destroy = shmob_drm_plane_destroy, -}; - -static const uint32_t formats[] = { - DRM_FORMAT_RGB565, - DRM_FORMAT_RGB888, - DRM_FORMAT_ARGB8888, - DRM_FORMAT_NV12, - DRM_FORMAT_NV21, - DRM_FORMAT_NV16, - DRM_FORMAT_NV61, - DRM_FORMAT_NV24, - DRM_FORMAT_NV42, -}; - -int shmob_drm_plane_create(struct shmob_drm_device *sdev, unsigned int index) -{ - struct shmob_drm_plane *splane; - int ret; - - splane = devm_kzalloc(sdev->dev, sizeof(*splane), GFP_KERNEL); - if (splane == NULL) - return -ENOMEM; - - splane->index = index; - splane->alpha = 255; - - ret = drm_universal_plane_init(sdev->ddev, &splane->plane, 1, - &shmob_drm_plane_funcs, - formats, ARRAY_SIZE(formats), NULL, - DRM_PLANE_TYPE_OVERLAY, NULL); - - return ret; -} diff --git a/drivers/gpu/drm/shmobile/shmob_drm_plane.h b/drivers/gpu/drm/shmobile/shmob_drm_plane.h deleted file mode 100644 index e72b21a4288fc2..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_plane.h +++ /dev/null @@ -1,19 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm_plane.h -- SH Mobile DRM Planes - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_PLANE_H__ -#define __SHMOB_DRM_PLANE_H__ - -struct drm_plane; -struct shmob_drm_device; - -int shmob_drm_plane_create(struct shmob_drm_device *sdev, unsigned int index); -void shmob_drm_plane_setup(struct drm_plane *plane); - -#endif /* __SHMOB_DRM_PLANE_H__ */ diff --git a/drivers/gpu/drm/shmobile/shmob_drm_regs.h b/drivers/gpu/drm/shmobile/shmob_drm_regs.h deleted file mode 100644 index 058533685c4cd0..00000000000000 --- a/drivers/gpu/drm/shmobile/shmob_drm_regs.h +++ /dev/null @@ -1,310 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * shmob_drm_regs.h -- SH Mobile DRM registers - * - * Copyright (C) 2012 Renesas Electronics Corporation - * - * Laurent Pinchart (laurent.pinchart@ideasonboard.com) - */ - -#ifndef __SHMOB_DRM_REGS_H__ -#define __SHMOB_DRM_REGS_H__ - -#include -#include - -#include "shmob_drm_drv.h" - -/* Register definitions */ -#define LDDCKPAT1R 0x400 -#define LDDCKPAT2R 0x404 -#define LDDCKR 0x410 -#define LDDCKR_ICKSEL_BUS (0 << 16) -#define LDDCKR_ICKSEL_MIPI (1 << 16) -#define LDDCKR_ICKSEL_HDMI (2 << 16) -#define LDDCKR_ICKSEL_EXT (3 << 16) -#define LDDCKR_ICKSEL_MASK (7 << 16) -#define LDDCKR_MOSEL (1 << 6) -#define LDDCKSTPR 0x414 -#define LDDCKSTPR_DCKSTS (1 << 16) -#define LDDCKSTPR_DCKSTP (1 << 0) -#define LDMT1R 0x418 -#define LDMT1R_VPOL (1 << 28) -#define LDMT1R_HPOL (1 << 27) -#define LDMT1R_DWPOL (1 << 26) -#define LDMT1R_DIPOL (1 << 25) -#define LDMT1R_DAPOL (1 << 24) -#define LDMT1R_HSCNT (1 << 17) -#define LDMT1R_DWCNT (1 << 16) -#define LDMT1R_IFM (1 << 12) -#define LDMT1R_MIFTYP_RGB8 (0x0 << 0) -#define LDMT1R_MIFTYP_RGB9 (0x4 << 0) -#define LDMT1R_MIFTYP_RGB12A (0x5 << 0) -#define LDMT1R_MIFTYP_RGB12B (0x6 << 0) -#define LDMT1R_MIFTYP_RGB16 (0x7 << 0) -#define LDMT1R_MIFTYP_RGB18 (0xa << 0) -#define LDMT1R_MIFTYP_RGB24 (0xb << 0) -#define LDMT1R_MIFTYP_YCBCR (0xf << 0) -#define LDMT1R_MIFTYP_SYS8A (0x0 << 0) -#define LDMT1R_MIFTYP_SYS8B (0x1 << 0) -#define LDMT1R_MIFTYP_SYS8C (0x2 << 0) -#define LDMT1R_MIFTYP_SYS8D (0x3 << 0) -#define LDMT1R_MIFTYP_SYS9 (0x4 << 0) -#define LDMT1R_MIFTYP_SYS12 (0x5 << 0) -#define LDMT1R_MIFTYP_SYS16A (0x7 << 0) -#define LDMT1R_MIFTYP_SYS16B (0x8 << 0) -#define LDMT1R_MIFTYP_SYS16C (0x9 << 0) -#define LDMT1R_MIFTYP_SYS18 (0xa << 0) -#define LDMT1R_MIFTYP_SYS24 (0xb << 0) -#define LDMT1R_MIFTYP_MASK (0xf << 0) -#define LDMT2R 0x41c -#define LDMT2R_CSUP_MASK (7 << 26) -#define LDMT2R_CSUP_SHIFT 26 -#define LDMT2R_RSV (1 << 25) -#define LDMT2R_VSEL (1 << 24) -#define LDMT2R_WCSC_MASK (0xff << 16) -#define LDMT2R_WCSC_SHIFT 16 -#define LDMT2R_WCEC_MASK (0xff << 8) -#define LDMT2R_WCEC_SHIFT 8 -#define LDMT2R_WCLW_MASK (0xff << 0) -#define LDMT2R_WCLW_SHIFT 0 -#define LDMT3R 0x420 -#define LDMT3R_RDLC_MASK (0x3f << 24) -#define LDMT3R_RDLC_SHIFT 24 -#define LDMT3R_RCSC_MASK (0xff << 16) -#define LDMT3R_RCSC_SHIFT 16 -#define LDMT3R_RCEC_MASK (0xff << 8) -#define LDMT3R_RCEC_SHIFT 8 -#define LDMT3R_RCLW_MASK (0xff << 0) -#define LDMT3R_RCLW_SHIFT 0 -#define LDDFR 0x424 -#define LDDFR_CF1 (1 << 18) -#define LDDFR_CF0 (1 << 17) -#define LDDFR_CC (1 << 16) -#define LDDFR_YF_420 (0 << 8) -#define LDDFR_YF_422 (1 << 8) -#define LDDFR_YF_444 (2 << 8) -#define LDDFR_YF_MASK (3 << 8) -#define LDDFR_PKF_ARGB32 (0x00 << 0) -#define LDDFR_PKF_RGB16 (0x03 << 0) -#define LDDFR_PKF_RGB24 (0x0b << 0) -#define LDDFR_PKF_MASK (0x1f << 0) -#define LDSM1R 0x428 -#define LDSM1R_OS (1 << 0) -#define LDSM2R 0x42c -#define LDSM2R_OSTRG (1 << 0) -#define LDSA1R 0x430 -#define LDSA2R 0x434 -#define LDMLSR 0x438 -#define LDWBFR 0x43c -#define LDWBCNTR 0x440 -#define LDWBAR 0x444 -#define LDHCNR 0x448 -#define LDHSYNR 0x44c -#define LDVLNR 0x450 -#define LDVSYNR 0x454 -#define LDHPDR 0x458 -#define LDVPDR 0x45c -#define LDPMR 0x460 -#define LDPMR_LPS (3 << 0) -#define LDINTR 0x468 -#define LDINTR_FE (1 << 10) -#define LDINTR_VSE (1 << 9) -#define LDINTR_VEE (1 << 8) -#define LDINTR_FS (1 << 2) -#define LDINTR_VSS (1 << 1) -#define LDINTR_VES (1 << 0) -#define LDINTR_STATUS_MASK (0xff << 0) -#define LDSR 0x46c -#define LDSR_MSS (1 << 10) -#define LDSR_MRS (1 << 8) -#define LDSR_AS (1 << 1) -#define LDCNT1R 0x470 -#define LDCNT1R_DE (1 << 0) -#define LDCNT2R 0x474 -#define LDCNT2R_BR (1 << 8) -#define LDCNT2R_MD (1 << 3) -#define LDCNT2R_SE (1 << 2) -#define LDCNT2R_ME (1 << 1) -#define LDCNT2R_DO (1 << 0) -#define LDRCNTR 0x478 -#define LDRCNTR_SRS (1 << 17) -#define LDRCNTR_SRC (1 << 16) -#define LDRCNTR_MRS (1 << 1) -#define LDRCNTR_MRC (1 << 0) -#define LDDDSR 0x47c -#define LDDDSR_LS (1 << 2) -#define LDDDSR_WS (1 << 1) -#define LDDDSR_BS (1 << 0) -#define LDHAJR 0x4a0 - -#define LDDWD0R 0x800 -#define LDDWDxR_WDACT (1 << 28) -#define LDDWDxR_RSW (1 << 24) -#define LDDRDR 0x840 -#define LDDRDR_RSR (1 << 24) -#define LDDRDR_DRD_MASK (0x3ffff << 0) -#define LDDWAR 0x900 -#define LDDWAR_WA (1 << 0) -#define LDDRAR 0x904 -#define LDDRAR_RA (1 << 0) - -#define LDBCR 0xb00 -#define LDBCR_UPC(n) (1 << ((n) + 16)) -#define LDBCR_UPF(n) (1 << ((n) + 8)) -#define LDBCR_UPD(n) (1 << ((n) + 0)) -#define LDBnBSIFR(n) (0xb20 + (n) * 0x20 + 0x00) -#define LDBBSIFR_EN (1 << 31) -#define LDBBSIFR_VS (1 << 29) -#define LDBBSIFR_BRSEL (1 << 28) -#define LDBBSIFR_MX (1 << 27) -#define LDBBSIFR_MY (1 << 26) -#define LDBBSIFR_CV3 (3 << 24) -#define LDBBSIFR_CV2 (2 << 24) -#define LDBBSIFR_CV1 (1 << 24) -#define LDBBSIFR_CV0 (0 << 24) -#define LDBBSIFR_CV_MASK (3 << 24) -#define LDBBSIFR_LAY_MASK (0xff << 16) -#define LDBBSIFR_LAY_SHIFT 16 -#define LDBBSIFR_ROP3_MASK (0xff << 16) -#define LDBBSIFR_ROP3_SHIFT 16 -#define LDBBSIFR_AL_PL8 (3 << 14) -#define LDBBSIFR_AL_PL1 (2 << 14) -#define LDBBSIFR_AL_PK (1 << 14) -#define LDBBSIFR_AL_1 (0 << 14) -#define LDBBSIFR_AL_MASK (3 << 14) -#define LDBBSIFR_SWPL (1 << 10) -#define LDBBSIFR_SWPW (1 << 9) -#define LDBBSIFR_SWPB (1 << 8) -#define LDBBSIFR_RY (1 << 7) -#define LDBBSIFR_CHRR_420 (2 << 0) -#define LDBBSIFR_CHRR_422 (1 << 0) -#define LDBBSIFR_CHRR_444 (0 << 0) -#define LDBBSIFR_RPKF_ARGB32 (0x00 << 0) -#define LDBBSIFR_RPKF_RGB16 (0x03 << 0) -#define LDBBSIFR_RPKF_RGB24 (0x0b << 0) -#define LDBBSIFR_RPKF_MASK (0x1f << 0) -#define LDBnBSSZR(n) (0xb20 + (n) * 0x20 + 0x04) -#define LDBBSSZR_BVSS_MASK (0xfff << 16) -#define LDBBSSZR_BVSS_SHIFT 16 -#define LDBBSSZR_BHSS_MASK (0xfff << 0) -#define LDBBSSZR_BHSS_SHIFT 0 -#define LDBnBLOCR(n) (0xb20 + (n) * 0x20 + 0x08) -#define LDBBLOCR_CVLC_MASK (0xfff << 16) -#define LDBBLOCR_CVLC_SHIFT 16 -#define LDBBLOCR_CHLC_MASK (0xfff << 0) -#define LDBBLOCR_CHLC_SHIFT 0 -#define LDBnBSMWR(n) (0xb20 + (n) * 0x20 + 0x0c) -#define LDBBSMWR_BSMWA_MASK (0xffff << 16) -#define LDBBSMWR_BSMWA_SHIFT 16 -#define LDBBSMWR_BSMW_MASK (0xffff << 0) -#define LDBBSMWR_BSMW_SHIFT 0 -#define LDBnBSAYR(n) (0xb20 + (n) * 0x20 + 0x10) -#define LDBBSAYR_FG1A_MASK (0xff << 24) -#define LDBBSAYR_FG1A_SHIFT 24 -#define LDBBSAYR_FG1R_MASK (0xff << 16) -#define LDBBSAYR_FG1R_SHIFT 16 -#define LDBBSAYR_FG1G_MASK (0xff << 8) -#define LDBBSAYR_FG1G_SHIFT 8 -#define LDBBSAYR_FG1B_MASK (0xff << 0) -#define LDBBSAYR_FG1B_SHIFT 0 -#define LDBnBSACR(n) (0xb20 + (n) * 0x20 + 0x14) -#define LDBBSACR_FG2A_MASK (0xff << 24) -#define LDBBSACR_FG2A_SHIFT 24 -#define LDBBSACR_FG2R_MASK (0xff << 16) -#define LDBBSACR_FG2R_SHIFT 16 -#define LDBBSACR_FG2G_MASK (0xff << 8) -#define LDBBSACR_FG2G_SHIFT 8 -#define LDBBSACR_FG2B_MASK (0xff << 0) -#define LDBBSACR_FG2B_SHIFT 0 -#define LDBnBSAAR(n) (0xb20 + (n) * 0x20 + 0x18) -#define LDBBSAAR_AP_MASK (0xff << 24) -#define LDBBSAAR_AP_SHIFT 24 -#define LDBBSAAR_R_MASK (0xff << 16) -#define LDBBSAAR_R_SHIFT 16 -#define LDBBSAAR_GY_MASK (0xff << 8) -#define LDBBSAAR_GY_SHIFT 8 -#define LDBBSAAR_B_MASK (0xff << 0) -#define LDBBSAAR_B_SHIFT 0 -#define LDBnBPPCR(n) (0xb20 + (n) * 0x20 + 0x1c) -#define LDBBPPCR_AP_MASK (0xff << 24) -#define LDBBPPCR_AP_SHIFT 24 -#define LDBBPPCR_R_MASK (0xff << 16) -#define LDBBPPCR_R_SHIFT 16 -#define LDBBPPCR_GY_MASK (0xff << 8) -#define LDBBPPCR_GY_SHIFT 8 -#define LDBBPPCR_B_MASK (0xff << 0) -#define LDBBPPCR_B_SHIFT 0 -#define LDBnBBGCL(n) (0xb10 + (n) * 0x04) -#define LDBBBGCL_BGA_MASK (0xff << 24) -#define LDBBBGCL_BGA_SHIFT 24 -#define LDBBBGCL_BGR_MASK (0xff << 16) -#define LDBBBGCL_BGR_SHIFT 16 -#define LDBBBGCL_BGG_MASK (0xff << 8) -#define LDBBBGCL_BGG_SHIFT 8 -#define LDBBBGCL_BGB_MASK (0xff << 0) -#define LDBBBGCL_BGB_SHIFT 0 - -#define LCDC_SIDE_B_OFFSET 0x1000 -#define LCDC_MIRROR_OFFSET 0x2000 - -static inline bool lcdc_is_banked(u32 reg) -{ - switch (reg) { - case LDMT1R: - case LDMT2R: - case LDMT3R: - case LDDFR: - case LDSM1R: - case LDSA1R: - case LDSA2R: - case LDMLSR: - case LDWBFR: - case LDWBCNTR: - case LDWBAR: - case LDHCNR: - case LDHSYNR: - case LDVLNR: - case LDVSYNR: - case LDHPDR: - case LDVPDR: - case LDHAJR: - return true; - default: - return reg >= LDBnBBGCL(0) && reg <= LDBnBPPCR(3); - } -} - -static inline void lcdc_write_mirror(struct shmob_drm_device *sdev, u32 reg, - u32 data) -{ - iowrite32(data, sdev->mmio + reg + LCDC_MIRROR_OFFSET); -} - -static inline void lcdc_write(struct shmob_drm_device *sdev, u32 reg, u32 data) -{ - iowrite32(data, sdev->mmio + reg); - if (lcdc_is_banked(reg)) - iowrite32(data, sdev->mmio + reg + LCDC_SIDE_B_OFFSET); -} - -static inline u32 lcdc_read(struct shmob_drm_device *sdev, u32 reg) -{ - return ioread32(sdev->mmio + reg); -} - -static inline int lcdc_wait_bit(struct shmob_drm_device *sdev, u32 reg, - u32 mask, u32 until) -{ - unsigned long timeout = jiffies + msecs_to_jiffies(5); - - while ((lcdc_read(sdev, reg) & mask) != until) { - if (time_after(jiffies, timeout)) - return -ETIMEDOUT; - cpu_relax(); - } - - return 0; -} - -#endif /* __SHMOB_DRM_REGS_H__ */ From patchwork Fri Jan 13 06:23:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 1725709 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=emEz7Xil; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NtWbf1zynz23g9 for ; Fri, 13 Jan 2023 17:24:30 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=1ew7fu4Uem8GS4IYaIluWRt5yAfZYTbSHcsxcyUaLnw=; b=emEz7Xilwh8oMP daibh6CX1ouWZtz3wYBmczKdK4o7VHtHvaUflQ8luE3zcd5iRLN25NXDhR3fta6aN8xR1WdO6Kie/ 036Px7dkKSLSDyrzn73E60u1QtcOq3S5+rizfn0k9C8zxWxL7WpNrX4fa7ntZRml3n2WSYWMqKrbb LdU3t3SMefqlCxEA1Rd09ULuGJikLsmFyekFBtNFQ8MFe8hkBYnae6MOn/74axGr0vToFqR+Grb36 3rCudSApWYjQgL5uiW9rayMLElRICAvZ7xnwUwZ7K1H4GpXJ/yI+NpjK2zGgZVsvAa9nEknY2+xfJ PyXasjJ/jGZWofVtO8hQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTp-000lRf-Bj; Fri, 13 Jan 2023 06:23:57 +0000 Received: from [2001:4bb8:181:656b:9509:7d20:8d39:f895] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTf-000lNa-NO; Fri, 13 Jan 2023 06:23:48 +0000 From: Christoph Hellwig To: Yoshinori Sato , Rich Felker , Arnd Bergmann , Greg Kroah-Hartman Cc: Laurent Pinchart , Kieran Bingham , Geert Uytterhoeven , linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org, linux-arch@vger.kernel.org, dmaengine@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, linux-i2c@vger.kernel.org, linux-input@vger.kernel.org, linux-media@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, linux-rtc@vger.kernel.org, linux-spi@vger.kernel.org, linux-serial@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, alsa-devel@alsa-project.org, linux-sh@vger.kernel.org Subject: [PATCH 02/22] usb: remove the dead USB_OHCI_SH option Date: Fri, 13 Jan 2023 07:23:19 +0100 Message-Id: <20230113062339.1909087-3-hch@lst.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230113062339.1909087-1-hch@lst.de> References: <20230113062339.1909087-1-hch@lst.de> MIME-Version: 1.0 X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org USB_OHCI_SH is a dummy option that never builds any code, remove it. Signed-off-by: Christoph Hellwig Acked-by: Greg Kroah-Hartman --- drivers/usb/host/Kconfig | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig index 8d799d23c476e1..ca5f657c092cf4 100644 --- a/drivers/usb/host/Kconfig +++ b/drivers/usb/host/Kconfig @@ -548,17 +548,6 @@ config USB_OHCI_HCD_SSB If unsure, say N. -config USB_OHCI_SH - bool "OHCI support for SuperH USB controller (DEPRECATED)" - depends on SUPERH || COMPILE_TEST - select USB_OHCI_HCD_PLATFORM - help - This option is deprecated now and the driver was removed, use - USB_OHCI_HCD_PLATFORM instead. - - Enables support for the on-chip OHCI controller on the SuperH. - If you use the PCI OHCI controller, this option is not necessary. - config USB_OHCI_EXYNOS tristate "OHCI support for Samsung S5P/Exynos SoC Series" depends on ARCH_S5PV210 || ARCH_EXYNOS || COMPILE_TEST From patchwork Fri Jan 13 06:23:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 1725720 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=mN/BOfHh; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NtWcp6jytz23dq for ; Fri, 13 Jan 2023 17:25:30 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ZlVvgnuP5F4LA1HUJDyf+jHyXc00I81qtWS7NOl2bnc=; b=mN/BOfHh8kv5pY BtrlIRH9aweQ8rkMLEgXkd1OseVL+scJatKSUkZtplzeMheMOQohgS1H/QNy6Q7i4MnK+qp5ENjOR e1Hn5BI1hjKhIep/Je+ZYKX5sdbeMR8oxBw+LH0Hcy2T9xBVvHsVbvy27QJDzFNGKZNR2v73ghFC4 LJ+DQNbxLtV4L5Mu0LkthOsGocNZQqDo1UcMRKvprsk+BVlsWtJiIgJ0B4KbKnnHUKRL9CWuHKTuK /8FeKBfS+s61BB9N5cnzBL5DtywiPKWgvNaYFTJvpPFgZyNjs4FqOemgou3oBaF0KV5oSqNhE673Y zV2/Z0dQnWslLkkQ8XFg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTu-000lSz-9v; Fri, 13 Jan 2023 06:24:04 +0000 Received: from [2001:4bb8:181:656b:9509:7d20:8d39:f895] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1pGDTi-000lOW-Ec; Fri, 13 Jan 2023 06:23:57 +0000 From: Christoph Hellwig To: Yoshinori Sato , Rich Felker , Arnd Bergmann , Greg Kroah-Hartman Cc: Laurent Pinchart , Kieran Bingham , Geert Uytterhoeven , linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org, linux-arch@vger.kernel.org, dmaengine@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, linux-i2c@vger.kernel.org, linux-input@vger.kernel.org, linux-media@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, linux-rtc@vger.kernel.org, linux-spi@vger.kernel.org, linux-serial@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, alsa-devel@alsa-project.org, linux-sh@vger.kernel.org Subject: [PATCH 03/22] remove arch/sh Date: Fri, 13 Jan 2023 07:23:20 +0100 Message-Id: <20230113062339.1909087-4-hch@lst.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230113062339.1909087-1-hch@lst.de> References: <20230113062339.1909087-1-hch@lst.de> MIME-Version: 1.0 X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org The Linux SH port has been mostly abandoned for years, with the last minor maintainer updated being in November 2021. Drop it as it drags maintainance of the rest of the kernel down. Signed-off-by: Christoph Hellwig --- Documentation/arch.rst | 1 - Documentation/sh/booting.rst | 12 - Documentation/sh/features.rst | 3 - Documentation/sh/index.rst | 56 - Documentation/sh/new-machine.rst | 277 --- Documentation/sh/register-banks.rst | 40 - MAINTAINERS | 10 - arch/sh/Kbuild | 7 - arch/sh/Kconfig | 793 -------- arch/sh/Kconfig.cpu | 100 - arch/sh/Kconfig.debug | 78 - arch/sh/Makefile | 215 --- arch/sh/boards/Kconfig | 400 ---- arch/sh/boards/Makefile | 20 - arch/sh/boards/board-apsh4a3a.c | 182 -- arch/sh/boards/board-apsh4ad0a.c | 132 -- arch/sh/boards/board-edosk7705.c | 79 - arch/sh/boards/board-edosk7760.c | 178 -- arch/sh/boards/board-espt.c | 105 -- arch/sh/boards/board-magicpanelr2.c | 390 ---- arch/sh/boards/board-polaris.c | 156 -- arch/sh/boards/board-secureedge5410.c | 75 - arch/sh/boards/board-sh2007.c | 146 -- arch/sh/boards/board-sh7757lcr.c | 604 ------- arch/sh/boards/board-sh7785lcr.c | 384 ---- arch/sh/boards/board-shmin.c | 35 - arch/sh/boards/board-titan.c | 21 - arch/sh/boards/board-urquell.c | 218 --- arch/sh/boards/mach-ap325rxa/Makefile | 3 - arch/sh/boards/mach-ap325rxa/sdram.S | 66 - arch/sh/boards/mach-ap325rxa/setup.c | 573 ------ arch/sh/boards/mach-dreamcast/Makefile | 7 - arch/sh/boards/mach-dreamcast/irq.c | 155 -- arch/sh/boards/mach-dreamcast/rtc.c | 96 - arch/sh/boards/mach-dreamcast/setup.c | 39 - arch/sh/boards/mach-ecovec24/Makefile | 10 - arch/sh/boards/mach-ecovec24/sdram.S | 108 -- arch/sh/boards/mach-ecovec24/setup.c | 1521 ---------------- arch/sh/boards/mach-highlander/Kconfig | 26 - arch/sh/boards/mach-highlander/Makefile | 12 - arch/sh/boards/mach-highlander/irq-r7780mp.c | 71 - arch/sh/boards/mach-highlander/irq-r7780rp.c | 64 - arch/sh/boards/mach-highlander/irq-r7785rp.c | 83 - .../boards/mach-highlander/pinmux-r7785rp.c | 17 - arch/sh/boards/mach-highlander/psw.c | 119 -- arch/sh/boards/mach-highlander/setup.c | 416 ----- arch/sh/boards/mach-hp6xx/Makefile | 8 - arch/sh/boards/mach-hp6xx/hp6xx_apm.c | 109 -- arch/sh/boards/mach-hp6xx/pm.c | 156 -- arch/sh/boards/mach-hp6xx/pm_wakeup.S | 39 - arch/sh/boards/mach-hp6xx/setup.c | 172 -- arch/sh/boards/mach-kfr2r09/Makefile | 5 - arch/sh/boards/mach-kfr2r09/lcd_wqvga.c | 275 --- arch/sh/boards/mach-kfr2r09/sdram.S | 77 - arch/sh/boards/mach-kfr2r09/setup.c | 649 ------- arch/sh/boards/mach-landisk/Makefile | 6 - arch/sh/boards/mach-landisk/gio.c | 164 -- arch/sh/boards/mach-landisk/irq.c | 63 - arch/sh/boards/mach-landisk/psw.c | 140 -- arch/sh/boards/mach-landisk/setup.c | 102 -- arch/sh/boards/mach-lboxre2/Makefile | 6 - arch/sh/boards/mach-lboxre2/irq.c | 27 - arch/sh/boards/mach-lboxre2/setup.c | 79 - arch/sh/boards/mach-microdev/Makefile | 6 - arch/sh/boards/mach-microdev/fdc37c93xapm.c | 157 -- arch/sh/boards/mach-microdev/io.c | 123 -- arch/sh/boards/mach-microdev/irq.c | 150 -- arch/sh/boards/mach-microdev/setup.c | 197 -- arch/sh/boards/mach-migor/Kconfig | 16 - arch/sh/boards/mach-migor/Makefile | 3 - arch/sh/boards/mach-migor/lcd_qvga.c | 163 -- arch/sh/boards/mach-migor/sdram.S | 66 - arch/sh/boards/mach-migor/setup.c | 649 ------- arch/sh/boards/mach-r2d/Kconfig | 24 - arch/sh/boards/mach-r2d/Makefile | 6 - arch/sh/boards/mach-r2d/irq.c | 156 -- arch/sh/boards/mach-r2d/setup.c | 305 ---- arch/sh/boards/mach-rsk/Kconfig | 29 - arch/sh/boards/mach-rsk/Makefile | 5 - arch/sh/boards/mach-rsk/devices-rsk7203.c | 137 -- arch/sh/boards/mach-rsk/devices-rsk7264.c | 55 - arch/sh/boards/mach-rsk/devices-rsk7269.c | 57 - arch/sh/boards/mach-rsk/setup.c | 84 - arch/sh/boards/mach-sdk7780/Kconfig | 17 - arch/sh/boards/mach-sdk7780/Makefile | 6 - arch/sh/boards/mach-sdk7780/irq.c | 43 - arch/sh/boards/mach-sdk7780/setup.c | 96 - arch/sh/boards/mach-sdk7786/Makefile | 5 - arch/sh/boards/mach-sdk7786/fpga.c | 69 - arch/sh/boards/mach-sdk7786/gpio.c | 46 - arch/sh/boards/mach-sdk7786/irq.c | 45 - arch/sh/boards/mach-sdk7786/nmi.c | 80 - arch/sh/boards/mach-sdk7786/setup.c | 266 --- arch/sh/boards/mach-sdk7786/sram.c | 69 - arch/sh/boards/mach-se/7206/Makefile | 6 - arch/sh/boards/mach-se/7206/irq.c | 151 -- arch/sh/boards/mach-se/7206/setup.c | 96 - arch/sh/boards/mach-se/7343/Makefile | 6 - arch/sh/boards/mach-se/7343/irq.c | 123 -- arch/sh/boards/mach-se/7343/setup.c | 182 -- arch/sh/boards/mach-se/770x/Makefile | 6 - arch/sh/boards/mach-se/770x/irq.c | 109 -- arch/sh/boards/mach-se/770x/setup.c | 205 --- arch/sh/boards/mach-se/7721/Makefile | 2 - arch/sh/boards/mach-se/7721/irq.c | 42 - arch/sh/boards/mach-se/7721/setup.c | 92 - arch/sh/boards/mach-se/7722/Makefile | 11 - arch/sh/boards/mach-se/7722/irq.c | 116 -- arch/sh/boards/mach-se/7722/setup.c | 190 -- arch/sh/boards/mach-se/7724/Makefile | 11 - arch/sh/boards/mach-se/7724/irq.c | 143 -- arch/sh/boards/mach-se/7724/sdram.S | 128 -- arch/sh/boards/mach-se/7724/setup.c | 986 ---------- arch/sh/boards/mach-se/7751/Makefile | 6 - arch/sh/boards/mach-se/7751/irq.c | 51 - arch/sh/boards/mach-se/7751/setup.c | 60 - arch/sh/boards/mach-se/7780/Makefile | 11 - arch/sh/boards/mach-se/7780/irq.c | 65 - arch/sh/boards/mach-se/7780/setup.c | 111 -- arch/sh/boards/mach-se/Makefile | 11 - arch/sh/boards/mach-se/board-se7619.c | 27 - arch/sh/boards/mach-sh03/Makefile | 7 - arch/sh/boards/mach-sh03/rtc.c | 143 -- arch/sh/boards/mach-sh03/setup.c | 97 - arch/sh/boards/mach-sh7763rdp/Makefile | 2 - arch/sh/boards/mach-sh7763rdp/irq.c | 42 - arch/sh/boards/mach-sh7763rdp/setup.c | 213 --- arch/sh/boards/mach-x3proto/Makefile | 4 - arch/sh/boards/mach-x3proto/gpio.c | 136 -- arch/sh/boards/mach-x3proto/ilsel.c | 156 -- arch/sh/boards/mach-x3proto/setup.c | 270 --- arch/sh/boards/of-generic.c | 172 -- arch/sh/boot/.gitignore | 5 - arch/sh/boot/Makefile | 115 -- arch/sh/boot/compressed/.gitignore | 2 - arch/sh/boot/compressed/Makefile | 66 - arch/sh/boot/compressed/ashiftrt.S | 2 - arch/sh/boot/compressed/ashldi3.c | 2 - arch/sh/boot/compressed/ashlsi3.S | 2 - arch/sh/boot/compressed/ashrsi3.S | 2 - arch/sh/boot/compressed/cache.c | 13 - arch/sh/boot/compressed/head_32.S | 126 -- arch/sh/boot/compressed/head_64.S | 159 -- arch/sh/boot/compressed/lshrsi3.S | 2 - arch/sh/boot/compressed/misc.c | 146 -- arch/sh/boot/compressed/vmlinux.scr | 10 - arch/sh/boot/dts/Makefile | 2 - arch/sh/boot/dts/j2_mimas_v2.dts | 99 - arch/sh/boot/romimage/Makefile | 30 - arch/sh/boot/romimage/head.S | 85 - arch/sh/boot/romimage/mmcif-sh7724.c | 78 - arch/sh/boot/romimage/vmlinux.scr | 8 - arch/sh/cchips/Kconfig | 46 - arch/sh/cchips/hd6446x/Makefile | 4 - arch/sh/cchips/hd6446x/hd64461.c | 112 -- arch/sh/configs/ap325rxa_defconfig | 103 -- arch/sh/configs/apsh4a3a_defconfig | 91 - arch/sh/configs/apsh4ad0a_defconfig | 122 -- arch/sh/configs/dreamcast_defconfig | 72 - arch/sh/configs/ecovec24-romimage_defconfig | 58 - arch/sh/configs/ecovec24_defconfig | 132 -- arch/sh/configs/edosk7705_defconfig | 35 - arch/sh/configs/edosk7760_defconfig | 114 -- arch/sh/configs/espt_defconfig | 114 -- arch/sh/configs/hp6xx_defconfig | 60 - arch/sh/configs/j2_defconfig | 42 - arch/sh/configs/kfr2r09-romimage_defconfig | 53 - arch/sh/configs/kfr2r09_defconfig | 84 - arch/sh/configs/landisk_defconfig | 115 -- arch/sh/configs/lboxre2_defconfig | 62 - arch/sh/configs/magicpanelr2_defconfig | 90 - arch/sh/configs/microdev_defconfig | 43 - arch/sh/configs/migor_defconfig | 94 - arch/sh/configs/polaris_defconfig | 83 - arch/sh/configs/r7780mp_defconfig | 109 -- arch/sh/configs/r7785rp_defconfig | 107 -- arch/sh/configs/rsk7201_defconfig | 63 - arch/sh/configs/rsk7203_defconfig | 121 -- arch/sh/configs/rsk7264_defconfig | 71 - arch/sh/configs/rsk7269_defconfig | 56 - arch/sh/configs/rts7751r2d1_defconfig | 91 - arch/sh/configs/rts7751r2dplus_defconfig | 96 - arch/sh/configs/sdk7780_defconfig | 139 -- arch/sh/configs/sdk7786_defconfig | 217 --- arch/sh/configs/se7206_defconfig | 108 -- arch/sh/configs/se7343_defconfig | 96 - arch/sh/configs/se7619_defconfig | 43 - arch/sh/configs/se7705_defconfig | 54 - arch/sh/configs/se7712_defconfig | 101 -- arch/sh/configs/se7721_defconfig | 127 -- arch/sh/configs/se7722_defconfig | 56 - arch/sh/configs/se7724_defconfig | 132 -- arch/sh/configs/se7750_defconfig | 55 - arch/sh/configs/se7751_defconfig | 46 - arch/sh/configs/se7780_defconfig | 106 -- arch/sh/configs/secureedge5410_defconfig | 53 - arch/sh/configs/sh03_defconfig | 126 -- arch/sh/configs/sh2007_defconfig | 199 -- arch/sh/configs/sh7710voipgw_defconfig | 55 - arch/sh/configs/sh7724_generic_defconfig | 41 - arch/sh/configs/sh7757lcr_defconfig | 85 - arch/sh/configs/sh7763rdp_defconfig | 116 -- arch/sh/configs/sh7770_generic_defconfig | 43 - arch/sh/configs/sh7785lcr_32bit_defconfig | 149 -- arch/sh/configs/sh7785lcr_defconfig | 117 -- arch/sh/configs/shmin_defconfig | 52 - arch/sh/configs/shx3_defconfig | 103 -- arch/sh/configs/titan_defconfig | 272 --- arch/sh/configs/ul2_defconfig | 84 - arch/sh/configs/urquell_defconfig | 147 -- arch/sh/drivers/Kconfig | 20 - arch/sh/drivers/Makefile | 11 - arch/sh/drivers/dma/Kconfig | 74 - arch/sh/drivers/dma/Makefile | 9 - arch/sh/drivers/dma/dma-api.c | 417 ----- arch/sh/drivers/dma/dma-g2.c | 197 -- arch/sh/drivers/dma/dma-pvr2.c | 102 -- arch/sh/drivers/dma/dma-sh.c | 414 ----- arch/sh/drivers/dma/dma-sysfs.c | 164 -- arch/sh/drivers/dma/dmabrg.c | 196 -- arch/sh/drivers/heartbeat.c | 152 -- arch/sh/drivers/pci/Makefile | 27 - arch/sh/drivers/pci/common.c | 159 -- arch/sh/drivers/pci/fixups-dreamcast.c | 84 - arch/sh/drivers/pci/fixups-landisk.c | 57 - arch/sh/drivers/pci/fixups-r7780rp.c | 18 - arch/sh/drivers/pci/fixups-rts7751r2d.c | 64 - arch/sh/drivers/pci/fixups-sdk7780.c | 40 - arch/sh/drivers/pci/fixups-sdk7786.c | 64 - arch/sh/drivers/pci/fixups-se7751.c | 113 -- arch/sh/drivers/pci/fixups-sh03.c | 33 - arch/sh/drivers/pci/fixups-snapgear.c | 37 - arch/sh/drivers/pci/fixups-titan.c | 36 - arch/sh/drivers/pci/ops-dreamcast.c | 79 - arch/sh/drivers/pci/ops-sh4.c | 105 -- arch/sh/drivers/pci/ops-sh7786.c | 168 -- arch/sh/drivers/pci/pci-dreamcast.c | 97 - arch/sh/drivers/pci/pci-sh4.h | 182 -- arch/sh/drivers/pci/pci-sh7751.c | 179 -- arch/sh/drivers/pci/pci-sh7751.h | 126 -- arch/sh/drivers/pci/pci-sh7780.c | 407 ----- arch/sh/drivers/pci/pci-sh7780.h | 43 - arch/sh/drivers/pci/pci.c | 298 --- arch/sh/drivers/pci/pcie-sh7786.c | 609 ------- arch/sh/drivers/pci/pcie-sh7786.h | 577 ------ arch/sh/drivers/platform_early.c | 340 ---- arch/sh/drivers/push-switch.c | 136 -- arch/sh/drivers/superhyway/Makefile | 7 - arch/sh/drivers/superhyway/ops-sh4-202.c | 168 -- arch/sh/include/asm/Kbuild | 5 - arch/sh/include/asm/adc.h | 12 - arch/sh/include/asm/addrspace.h | 63 - arch/sh/include/asm/alignment.h | 22 - arch/sh/include/asm/asm-offsets.h | 2 - arch/sh/include/asm/atomic-grb.h | 86 - arch/sh/include/asm/atomic-irq.h | 72 - arch/sh/include/asm/atomic-llsc.h | 88 - arch/sh/include/asm/atomic.h | 38 - arch/sh/include/asm/barrier.h | 45 - arch/sh/include/asm/bitops-cas.h | 94 - arch/sh/include/asm/bitops-grb.h | 173 -- arch/sh/include/asm/bitops-llsc.h | 147 -- arch/sh/include/asm/bitops-op32.h | 143 -- arch/sh/include/asm/bitops.h | 72 - arch/sh/include/asm/bl_bit.h | 2 - arch/sh/include/asm/bl_bit_32.h | 34 - arch/sh/include/asm/bug.h | 121 -- arch/sh/include/asm/bugs.h | 74 - arch/sh/include/asm/cache.h | 46 - arch/sh/include/asm/cache_insns.h | 2 - arch/sh/include/asm/cache_insns_32.h | 22 - arch/sh/include/asm/cacheflush.h | 106 -- arch/sh/include/asm/checksum.h | 2 - arch/sh/include/asm/checksum_32.h | 203 --- arch/sh/include/asm/clock.h | 17 - arch/sh/include/asm/cmpxchg-cas.h | 25 - arch/sh/include/asm/cmpxchg-grb.h | 95 - arch/sh/include/asm/cmpxchg-irq.h | 54 - arch/sh/include/asm/cmpxchg-llsc.h | 53 - arch/sh/include/asm/cmpxchg-xchg.h | 50 - arch/sh/include/asm/cmpxchg.h | 74 - arch/sh/include/asm/device.h | 17 - arch/sh/include/asm/dma-register.h | 50 - arch/sh/include/asm/dma.h | 140 -- arch/sh/include/asm/dmabrg.h | 24 - arch/sh/include/asm/dwarf.h | 417 ----- arch/sh/include/asm/elf.h | 211 --- arch/sh/include/asm/entry-macros.S | 123 -- arch/sh/include/asm/extable.h | 7 - arch/sh/include/asm/fb.h | 20 - arch/sh/include/asm/fixmap.h | 86 - arch/sh/include/asm/flat.h | 33 - arch/sh/include/asm/fpu.h | 69 - arch/sh/include/asm/freq.h | 12 - arch/sh/include/asm/ftrace.h | 48 - arch/sh/include/asm/futex-cas.h | 35 - arch/sh/include/asm/futex-irq.h | 25 - arch/sh/include/asm/futex-llsc.h | 42 - arch/sh/include/asm/futex.h | 72 - arch/sh/include/asm/gpio.h | 50 - arch/sh/include/asm/hardirq.h | 11 - arch/sh/include/asm/hd64461.h | 252 --- arch/sh/include/asm/heartbeat.h | 19 - arch/sh/include/asm/hugetlb.h | 38 - arch/sh/include/asm/hw_breakpoint.h | 70 - arch/sh/include/asm/hw_irq.h | 36 - arch/sh/include/asm/i2c-sh7760.h | 21 - arch/sh/include/asm/io.h | 294 --- arch/sh/include/asm/io_generic.h | 19 - arch/sh/include/asm/io_noioport.h | 86 - arch/sh/include/asm/io_trapped.h | 59 - arch/sh/include/asm/irq.h | 58 - arch/sh/include/asm/irqflags.h | 10 - arch/sh/include/asm/kdebug.h | 19 - arch/sh/include/asm/kexec.h | 72 - arch/sh/include/asm/kgdb.h | 38 - arch/sh/include/asm/kprobes.h | 57 - arch/sh/include/asm/linkage.h | 8 - arch/sh/include/asm/machvec.h | 41 - arch/sh/include/asm/mmiowb.h | 12 - arch/sh/include/asm/mmu.h | 107 -- arch/sh/include/asm/mmu_context.h | 178 -- arch/sh/include/asm/mmu_context_32.h | 51 - arch/sh/include/asm/mmzone.h | 45 - arch/sh/include/asm/module.h | 14 - arch/sh/include/asm/page.h | 186 -- arch/sh/include/asm/pci.h | 91 - arch/sh/include/asm/perf_event.h | 30 - arch/sh/include/asm/pgalloc.h | 40 - arch/sh/include/asm/pgtable-2level.h | 24 - arch/sh/include/asm/pgtable-3level.h | 59 - arch/sh/include/asm/pgtable.h | 150 -- arch/sh/include/asm/pgtable_32.h | 462 ----- arch/sh/include/asm/platform_early.h | 61 - arch/sh/include/asm/posix_types.h | 2 - arch/sh/include/asm/processor.h | 173 -- arch/sh/include/asm/processor_32.h | 202 --- arch/sh/include/asm/ptrace.h | 139 -- arch/sh/include/asm/ptrace_32.h | 14 - arch/sh/include/asm/push-switch.h | 32 - arch/sh/include/asm/reboot.h | 22 - arch/sh/include/asm/romimage-macros.h | 74 - arch/sh/include/asm/rtc.h | 15 - arch/sh/include/asm/seccomp.h | 21 - arch/sh/include/asm/sections.h | 12 - arch/sh/include/asm/setup.h | 25 - arch/sh/include/asm/sfp-machine.h | 80 - arch/sh/include/asm/sh7760fb.h | 198 -- arch/sh/include/asm/sh_bios.h | 28 - arch/sh/include/asm/shmparam.h | 19 - arch/sh/include/asm/siu.h | 20 - arch/sh/include/asm/smc37c93x.h | 191 -- arch/sh/include/asm/smp-ops.h | 52 - arch/sh/include/asm/smp.h | 83 - arch/sh/include/asm/sparsemem.h | 12 - arch/sh/include/asm/spi.h | 14 - arch/sh/include/asm/spinlock-cas.h | 89 - arch/sh/include/asm/spinlock-llsc.h | 198 -- arch/sh/include/asm/spinlock.h | 19 - arch/sh/include/asm/spinlock_types.h | 22 - arch/sh/include/asm/sram.h | 39 - arch/sh/include/asm/stackprotector.h | 21 - arch/sh/include/asm/stacktrace.h | 21 - arch/sh/include/asm/string.h | 2 - arch/sh/include/asm/string_32.h | 102 -- arch/sh/include/asm/suspend.h | 97 - arch/sh/include/asm/switch_to.h | 7 - arch/sh/include/asm/switch_to_32.h | 131 -- arch/sh/include/asm/syscall.h | 9 - arch/sh/include/asm/syscall_32.h | 69 - arch/sh/include/asm/syscalls.h | 14 - arch/sh/include/asm/syscalls_32.h | 27 - arch/sh/include/asm/thread_info.h | 171 -- arch/sh/include/asm/timex.h | 24 - arch/sh/include/asm/tlb.h | 29 - arch/sh/include/asm/tlbflush.h | 52 - arch/sh/include/asm/topology.h | 28 - arch/sh/include/asm/traps.h | 18 - arch/sh/include/asm/traps_32.h | 61 - arch/sh/include/asm/types.h | 16 - arch/sh/include/asm/uaccess.h | 133 -- arch/sh/include/asm/uaccess_32.h | 227 --- arch/sh/include/asm/uncached.h | 59 - arch/sh/include/asm/unistd.h | 31 - arch/sh/include/asm/unwinder.h | 32 - arch/sh/include/asm/user.h | 55 - arch/sh/include/asm/vermagic.h | 30 - arch/sh/include/asm/vga.h | 7 - arch/sh/include/asm/vmalloc.h | 4 - arch/sh/include/asm/vmlinux.lds.h | 18 - arch/sh/include/asm/watchdog.h | 159 -- arch/sh/include/asm/word-at-a-time.h | 54 - arch/sh/include/cpu-common/cpu/addrspace.h | 16 - arch/sh/include/cpu-common/cpu/mmu_context.h | 13 - arch/sh/include/cpu-common/cpu/pfc.h | 18 - arch/sh/include/cpu-common/cpu/rtc.h | 9 - arch/sh/include/cpu-common/cpu/sigcontext.h | 18 - arch/sh/include/cpu-common/cpu/timer.h | 7 - arch/sh/include/cpu-sh2/cpu/cache.h | 40 - arch/sh/include/cpu-sh2/cpu/freq.h | 15 - arch/sh/include/cpu-sh2/cpu/watchdog.h | 66 - arch/sh/include/cpu-sh2a/cpu/addrspace.h | 11 - arch/sh/include/cpu-sh2a/cpu/cache.h | 40 - arch/sh/include/cpu-sh2a/cpu/freq.h | 13 - arch/sh/include/cpu-sh2a/cpu/rtc.h | 9 - arch/sh/include/cpu-sh2a/cpu/sh7203.h | 144 -- arch/sh/include/cpu-sh2a/cpu/sh7264.h | 169 -- arch/sh/include/cpu-sh2a/cpu/sh7269.h | 213 --- arch/sh/include/cpu-sh2a/cpu/watchdog.h | 2 - arch/sh/include/cpu-sh3/cpu/adc.h | 29 - arch/sh/include/cpu-sh3/cpu/cache.h | 40 - arch/sh/include/cpu-sh3/cpu/dac.h | 42 - arch/sh/include/cpu-sh3/cpu/dma-register.h | 38 - arch/sh/include/cpu-sh3/cpu/dma.h | 19 - arch/sh/include/cpu-sh3/cpu/freq.h | 24 - arch/sh/include/cpu-sh3/cpu/gpio.h | 78 - arch/sh/include/cpu-sh3/cpu/mmu_context.h | 42 - arch/sh/include/cpu-sh3/cpu/serial.h | 11 - arch/sh/include/cpu-sh3/cpu/sh7720.h | 175 -- arch/sh/include/cpu-sh3/cpu/watchdog.h | 22 - arch/sh/include/cpu-sh4/cpu/addrspace.h | 41 - arch/sh/include/cpu-sh4/cpu/cache.h | 41 - arch/sh/include/cpu-sh4/cpu/dma-register.h | 98 - arch/sh/include/cpu-sh4/cpu/dma.h | 18 - arch/sh/include/cpu-sh4/cpu/fpu.h | 30 - arch/sh/include/cpu-sh4/cpu/freq.h | 74 - arch/sh/include/cpu-sh4/cpu/mmu_context.h | 79 - arch/sh/include/cpu-sh4/cpu/rtc.h | 14 - arch/sh/include/cpu-sh4/cpu/sh7722.h | 252 --- arch/sh/include/cpu-sh4/cpu/sh7723.h | 285 --- arch/sh/include/cpu-sh4/cpu/sh7724.h | 319 ---- arch/sh/include/cpu-sh4/cpu/sh7734.h | 307 ---- arch/sh/include/cpu-sh4/cpu/sh7757.h | 290 --- arch/sh/include/cpu-sh4/cpu/sh7785.h | 260 --- arch/sh/include/cpu-sh4/cpu/sh7786.h | 138 -- arch/sh/include/cpu-sh4/cpu/shx3.h | 65 - arch/sh/include/cpu-sh4/cpu/sigcontext.h | 25 - arch/sh/include/cpu-sh4/cpu/sq.h | 33 - arch/sh/include/cpu-sh4/cpu/watchdog.h | 41 - arch/sh/include/cpu-sh4a/cpu/dma.h | 72 - arch/sh/include/cpu-sh4a/cpu/serial.h | 8 - arch/sh/include/mach-common/mach/highlander.h | 208 --- arch/sh/include/mach-common/mach/hp6xx.h | 59 - arch/sh/include/mach-common/mach/lboxre2.h | 24 - .../include/mach-common/mach/magicpanelr2.h | 64 - .../sh/include/mach-common/mach/mangle-port.h | 46 - arch/sh/include/mach-common/mach/microdev.h | 69 - arch/sh/include/mach-common/mach/r2d.h | 71 - arch/sh/include/mach-common/mach/romimage.h | 12 - arch/sh/include/mach-common/mach/sdk7780.h | 79 - .../include/mach-common/mach/secureedge5410.h | 47 - arch/sh/include/mach-common/mach/sh2007.h | 118 -- arch/sh/include/mach-common/mach/sh7763rdp.h | 50 - arch/sh/include/mach-common/mach/sh7785lcr.h | 58 - arch/sh/include/mach-common/mach/shmin.h | 10 - arch/sh/include/mach-common/mach/titan.h | 20 - arch/sh/include/mach-common/mach/urquell.h | 69 - arch/sh/include/mach-dreamcast/mach/dma.h | 29 - arch/sh/include/mach-dreamcast/mach/maple.h | 38 - arch/sh/include/mach-dreamcast/mach/pci.h | 24 - arch/sh/include/mach-dreamcast/mach/sysasic.h | 46 - .../mach-ecovec24/mach/partner-jet-setup.txt | 82 - arch/sh/include/mach-ecovec24/mach/romimage.h | 48 - arch/sh/include/mach-kfr2r09/mach/kfr2r09.h | 24 - .../mach-kfr2r09/mach/partner-jet-setup.txt | 144 -- arch/sh/include/mach-kfr2r09/mach/romimage.h | 31 - arch/sh/include/mach-landisk/mach/gio.h | 38 - .../mach-landisk/mach/iodata_landisk.h | 46 - arch/sh/include/mach-migor/mach/migor.h | 16 - arch/sh/include/mach-sdk7786/mach/fpga.h | 156 -- arch/sh/include/mach-sdk7786/mach/irq.h | 8 - arch/sh/include/mach-se/mach/mrshpc.h | 53 - arch/sh/include/mach-se/mach/se.h | 120 -- arch/sh/include/mach-se/mach/se7206.h | 14 - arch/sh/include/mach-se/mach/se7343.h | 143 -- arch/sh/include/mach-se/mach/se7721.h | 68 - arch/sh/include/mach-se/mach/se7722.h | 98 - arch/sh/include/mach-se/mach/se7724.h | 69 - arch/sh/include/mach-se/mach/se7751.h | 75 - arch/sh/include/mach-se/mach/se7780.h | 106 -- arch/sh/include/mach-sh03/mach/io.h | 26 - arch/sh/include/mach-sh03/mach/sh03.h | 19 - arch/sh/include/mach-x3proto/mach/hardware.h | 13 - arch/sh/include/mach-x3proto/mach/ilsel.h | 46 - arch/sh/include/uapi/asm/Kbuild | 4 - arch/sh/include/uapi/asm/auxvec.h | 39 - arch/sh/include/uapi/asm/byteorder.h | 11 - arch/sh/include/uapi/asm/cachectl.h | 20 - arch/sh/include/uapi/asm/cpu-features.h | 28 - arch/sh/include/uapi/asm/hw_breakpoint.h | 5 - arch/sh/include/uapi/asm/ioctls.h | 116 -- arch/sh/include/uapi/asm/posix_types.h | 2 - arch/sh/include/uapi/asm/posix_types_32.h | 23 - arch/sh/include/uapi/asm/ptrace.h | 30 - arch/sh/include/uapi/asm/ptrace_32.h | 78 - arch/sh/include/uapi/asm/sigcontext.h | 25 - arch/sh/include/uapi/asm/signal.h | 18 - arch/sh/include/uapi/asm/sockios.h | 18 - arch/sh/include/uapi/asm/stat.h | 78 - arch/sh/include/uapi/asm/swab.h | 50 - arch/sh/include/uapi/asm/unistd.h | 2 - arch/sh/kernel/.gitignore | 2 - arch/sh/kernel/Makefile | 49 - arch/sh/kernel/asm-offsets.c | 60 - arch/sh/kernel/cpu/Makefile | 21 - arch/sh/kernel/cpu/adc.c | 37 - arch/sh/kernel/cpu/clock-cpg.c | 78 - arch/sh/kernel/cpu/clock.c | 52 - arch/sh/kernel/cpu/fpu.c | 92 - arch/sh/kernel/cpu/init.c | 366 ---- arch/sh/kernel/cpu/irq/Makefile | 6 - arch/sh/kernel/cpu/irq/imask.c | 85 - arch/sh/kernel/cpu/irq/ipr.c | 80 - arch/sh/kernel/cpu/pfc.c | 25 - arch/sh/kernel/cpu/proc.c | 151 -- arch/sh/kernel/cpu/sh2/Makefile | 12 - arch/sh/kernel/cpu/sh2/clock-sh7619.c | 74 - arch/sh/kernel/cpu/sh2/entry.S | 373 ---- arch/sh/kernel/cpu/sh2/ex.S | 44 - arch/sh/kernel/cpu/sh2/probe.c | 71 - arch/sh/kernel/cpu/sh2/setup-sh7619.c | 205 --- arch/sh/kernel/cpu/sh2/smp-j2.c | 136 -- arch/sh/kernel/cpu/sh2a/Makefile | 25 - arch/sh/kernel/cpu/sh2a/clock-sh7201.c | 82 - arch/sh/kernel/cpu/sh2a/clock-sh7203.c | 78 - arch/sh/kernel/cpu/sh2a/clock-sh7206.c | 80 - arch/sh/kernel/cpu/sh2a/clock-sh7264.c | 157 -- arch/sh/kernel/cpu/sh2a/clock-sh7269.c | 181 -- arch/sh/kernel/cpu/sh2a/entry.S | 247 --- arch/sh/kernel/cpu/sh2a/ex.S | 70 - arch/sh/kernel/cpu/sh2a/fpu.c | 572 ------ arch/sh/kernel/cpu/sh2a/opcode_helper.c | 51 - arch/sh/kernel/cpu/sh2a/pinmux-sh7203.c | 27 - arch/sh/kernel/cpu/sh2a/pinmux-sh7264.c | 27 - arch/sh/kernel/cpu/sh2a/pinmux-sh7269.c | 28 - arch/sh/kernel/cpu/sh2a/probe.c | 57 - arch/sh/kernel/cpu/sh2a/setup-mxg.c | 175 -- arch/sh/kernel/cpu/sh2a/setup-sh7201.c | 418 ----- arch/sh/kernel/cpu/sh2a/setup-sh7203.c | 355 ---- arch/sh/kernel/cpu/sh2a/setup-sh7206.c | 291 --- arch/sh/kernel/cpu/sh2a/setup-sh7264.c | 552 ------ arch/sh/kernel/cpu/sh2a/setup-sh7269.c | 568 ------ arch/sh/kernel/cpu/sh3/Makefile | 34 - arch/sh/kernel/cpu/sh3/clock-sh3.c | 86 - arch/sh/kernel/cpu/sh3/clock-sh7705.c | 81 - arch/sh/kernel/cpu/sh3/clock-sh7706.c | 81 - arch/sh/kernel/cpu/sh3/clock-sh7709.c | 82 - arch/sh/kernel/cpu/sh3/clock-sh7710.c | 75 - arch/sh/kernel/cpu/sh3/clock-sh7712.c | 68 - arch/sh/kernel/cpu/sh3/entry.S | 509 ------ arch/sh/kernel/cpu/sh3/ex.S | 56 - arch/sh/kernel/cpu/sh3/pinmux-sh7720.c | 27 - arch/sh/kernel/cpu/sh3/probe.c | 108 -- arch/sh/kernel/cpu/sh3/serial-sh770x.c | 34 - arch/sh/kernel/cpu/sh3/serial-sh7710.c | 21 - arch/sh/kernel/cpu/sh3/serial-sh7720.c | 38 - arch/sh/kernel/cpu/sh3/setup-sh3.c | 69 - arch/sh/kernel/cpu/sh3/setup-sh7705.c | 190 -- arch/sh/kernel/cpu/sh3/setup-sh770x.c | 246 --- arch/sh/kernel/cpu/sh3/setup-sh7710.c | 189 -- arch/sh/kernel/cpu/sh3/setup-sh7720.c | 286 --- arch/sh/kernel/cpu/sh3/swsusp.S | 144 -- arch/sh/kernel/cpu/sh4/Makefile | 37 - arch/sh/kernel/cpu/sh4/clock-sh4-202.c | 174 -- arch/sh/kernel/cpu/sh4/clock-sh4.c | 77 - arch/sh/kernel/cpu/sh4/fpu.c | 425 ----- arch/sh/kernel/cpu/sh4/perf_event.c | 265 --- arch/sh/kernel/cpu/sh4/probe.c | 260 --- arch/sh/kernel/cpu/sh4/setup-sh4-202.c | 139 -- arch/sh/kernel/cpu/sh4/setup-sh7750.c | 359 ---- arch/sh/kernel/cpu/sh4/setup-sh7760.c | 297 --- arch/sh/kernel/cpu/sh4/softfloat.c | 930 ---------- arch/sh/kernel/cpu/sh4/sq.c | 414 ----- arch/sh/kernel/cpu/sh4a/Makefile | 53 - arch/sh/kernel/cpu/sh4a/clock-sh7343.c | 277 --- arch/sh/kernel/cpu/sh4a/clock-sh7366.c | 270 --- arch/sh/kernel/cpu/sh4a/clock-sh7722.c | 253 --- arch/sh/kernel/cpu/sh4a/clock-sh7723.c | 301 ---- arch/sh/kernel/cpu/sh4a/clock-sh7724.c | 367 ---- arch/sh/kernel/cpu/sh4a/clock-sh7734.c | 256 --- arch/sh/kernel/cpu/sh4a/clock-sh7757.c | 152 -- arch/sh/kernel/cpu/sh4a/clock-sh7763.c | 116 -- arch/sh/kernel/cpu/sh4a/clock-sh7770.c | 70 - arch/sh/kernel/cpu/sh4a/clock-sh7780.c | 122 -- arch/sh/kernel/cpu/sh4a/clock-sh7785.c | 174 -- arch/sh/kernel/cpu/sh4a/clock-sh7786.c | 189 -- arch/sh/kernel/cpu/sh4a/clock-shx3.c | 148 -- arch/sh/kernel/cpu/sh4a/intc-shx3.c | 31 - arch/sh/kernel/cpu/sh4a/perf_event.c | 299 --- arch/sh/kernel/cpu/sh4a/pinmux-sh7722.c | 21 - arch/sh/kernel/cpu/sh4a/pinmux-sh7723.c | 27 - arch/sh/kernel/cpu/sh4a/pinmux-sh7724.c | 32 - arch/sh/kernel/cpu/sh4a/pinmux-sh7734.c | 32 - arch/sh/kernel/cpu/sh4a/pinmux-sh7757.c | 32 - arch/sh/kernel/cpu/sh4a/pinmux-sh7785.c | 27 - arch/sh/kernel/cpu/sh4a/pinmux-sh7786.c | 32 - arch/sh/kernel/cpu/sh4a/pinmux-shx3.c | 26 - arch/sh/kernel/cpu/sh4a/serial-sh7722.c | 24 - arch/sh/kernel/cpu/sh4a/setup-sh7343.c | 444 ----- arch/sh/kernel/cpu/sh4a/setup-sh7366.c | 388 ---- arch/sh/kernel/cpu/sh4a/setup-sh7722.c | 666 ------- arch/sh/kernel/cpu/sh4a/setup-sh7723.c | 644 ------- arch/sh/kernel/cpu/sh4a/setup-sh7724.c | 1288 ------------- arch/sh/kernel/cpu/sh4a/setup-sh7734.c | 621 ------- arch/sh/kernel/cpu/sh4a/setup-sh7757.c | 1242 ------------- arch/sh/kernel/cpu/sh4a/setup-sh7763.c | 455 ----- arch/sh/kernel/cpu/sh4a/setup-sh7770.c | 571 ------ arch/sh/kernel/cpu/sh4a/setup-sh7780.c | 505 ------ arch/sh/kernel/cpu/sh4a/setup-sh7785.c | 608 ------- arch/sh/kernel/cpu/sh4a/setup-sh7786.c | 841 --------- arch/sh/kernel/cpu/sh4a/setup-shx3.c | 396 ---- arch/sh/kernel/cpu/sh4a/smp-shx3.c | 146 -- arch/sh/kernel/cpu/sh4a/ubc.c | 130 -- arch/sh/kernel/cpu/shmobile/Makefile | 8 - arch/sh/kernel/cpu/shmobile/cpuidle.c | 95 - arch/sh/kernel/cpu/shmobile/pm.c | 153 -- arch/sh/kernel/cpu/shmobile/sleep.S | 402 ----- arch/sh/kernel/crash_dump.c | 27 - arch/sh/kernel/debugtraps.S | 38 - arch/sh/kernel/disassemble.c | 572 ------ arch/sh/kernel/dma-coherent.c | 33 - arch/sh/kernel/dumpstack.c | 156 -- arch/sh/kernel/dwarf.c | 1206 ------------- arch/sh/kernel/entry-common.S | 400 ---- arch/sh/kernel/ftrace.c | 365 ---- arch/sh/kernel/head_32.S | 365 ---- arch/sh/kernel/hw_breakpoint.c | 408 ----- arch/sh/kernel/idle.c | 57 - arch/sh/kernel/io.c | 111 -- arch/sh/kernel/io_trapped.c | 291 --- arch/sh/kernel/iomap.c | 162 -- arch/sh/kernel/ioport.c | 41 - arch/sh/kernel/irq.c | 249 --- arch/sh/kernel/irq_32.c | 54 - arch/sh/kernel/kdebugfs.c | 14 - arch/sh/kernel/kgdb.c | 378 ---- arch/sh/kernel/kprobes.c | 452 ----- arch/sh/kernel/machine_kexec.c | 204 --- arch/sh/kernel/machvec.c | 122 -- arch/sh/kernel/module.c | 104 -- arch/sh/kernel/nmi_debug.c | 75 - arch/sh/kernel/perf_callchain.c | 32 - arch/sh/kernel/perf_event.c | 363 ---- arch/sh/kernel/process.c | 77 - arch/sh/kernel/process_32.c | 197 -- arch/sh/kernel/ptrace.c | 34 - arch/sh/kernel/ptrace_32.c | 487 ----- arch/sh/kernel/reboot.c | 96 - arch/sh/kernel/relocate_kernel.S | 230 --- arch/sh/kernel/return_address.c | 56 - arch/sh/kernel/setup.c | 356 ---- arch/sh/kernel/sh_bios.c | 169 -- arch/sh/kernel/sh_ksyms_32.c | 118 -- arch/sh/kernel/signal_32.c | 507 ------ arch/sh/kernel/smp.c | 471 ----- arch/sh/kernel/stacktrace.c | 79 - arch/sh/kernel/swsusp.c | 35 - arch/sh/kernel/sys_sh.c | 96 - arch/sh/kernel/sys_sh32.c | 61 - arch/sh/kernel/syscalls/Makefile | 32 - arch/sh/kernel/syscalls/syscall.tbl | 455 ----- arch/sh/kernel/syscalls_32.S | 17 - arch/sh/kernel/time.c | 45 - arch/sh/kernel/topology.c | 74 - arch/sh/kernel/traps.c | 204 --- arch/sh/kernel/traps_32.c | 795 -------- arch/sh/kernel/unwinder.c | 165 -- arch/sh/kernel/vmlinux.lds.S | 82 - arch/sh/kernel/vsyscall/.gitignore | 2 - arch/sh/kernel/vsyscall/Makefile | 36 - arch/sh/kernel/vsyscall/vsyscall-note.S | 26 - arch/sh/kernel/vsyscall/vsyscall-sigreturn.S | 75 - arch/sh/kernel/vsyscall/vsyscall-syscall.S | 11 - arch/sh/kernel/vsyscall/vsyscall-trapa.S | 40 - arch/sh/kernel/vsyscall/vsyscall.c | 93 - arch/sh/kernel/vsyscall/vsyscall.lds.S | 85 - arch/sh/lib/Makefile | 32 - arch/sh/lib/__clear_user.S | 109 -- arch/sh/lib/ashiftrt.S | 128 -- arch/sh/lib/ashldi3.c | 30 - arch/sh/lib/ashlsi3.S | 189 -- arch/sh/lib/ashrdi3.c | 32 - arch/sh/lib/ashrsi3.S | 179 -- arch/sh/lib/checksum.S | 365 ---- arch/sh/lib/copy_page.S | 390 ---- arch/sh/lib/delay.c | 54 - arch/sh/lib/div64-generic.c | 20 - arch/sh/lib/div64.S | 47 - arch/sh/lib/io.c | 79 - arch/sh/lib/libgcc.h | 27 - arch/sh/lib/lshrdi3.c | 30 - arch/sh/lib/lshrsi3.S | 188 -- arch/sh/lib/mcount.S | 287 --- arch/sh/lib/memchr.S | 27 - arch/sh/lib/memcpy-sh4.S | 800 -------- arch/sh/lib/memcpy.S | 228 --- arch/sh/lib/memmove.S | 255 --- arch/sh/lib/memset-sh4.S | 108 -- arch/sh/lib/memset.S | 59 - arch/sh/lib/movmem.S | 217 --- arch/sh/lib/strlen.S | 71 - arch/sh/lib/udiv_qrnnd.S | 60 - arch/sh/lib/udivsi3.S | 66 - arch/sh/lib/udivsi3_i4i-Os.S | 128 -- arch/sh/lib/udivsi3_i4i.S | 645 ------- arch/sh/math-emu/Makefile | 2 - arch/sh/math-emu/math.c | 506 ------ arch/sh/math-emu/sfp-util.h | 73 - arch/sh/mm/Kconfig | 254 --- arch/sh/mm/Makefile | 45 - arch/sh/mm/alignment.c | 189 -- arch/sh/mm/asids-debugfs.c | 59 - arch/sh/mm/cache-debugfs.c | 109 -- arch/sh/mm/cache-j2.c | 64 - arch/sh/mm/cache-sh2.c | 90 - arch/sh/mm/cache-sh2a.c | 188 -- arch/sh/mm/cache-sh3.c | 102 -- arch/sh/mm/cache-sh4.c | 390 ---- arch/sh/mm/cache-sh7705.c | 194 -- arch/sh/mm/cache-shx3.c | 44 - arch/sh/mm/cache.c | 360 ---- arch/sh/mm/consistent.c | 65 - arch/sh/mm/extable_32.c | 24 - arch/sh/mm/fault.c | 504 ------ arch/sh/mm/flush-sh4.c | 111 -- arch/sh/mm/hugetlbpage.c | 82 - arch/sh/mm/init.c | 424 ----- arch/sh/mm/ioremap.c | 192 -- arch/sh/mm/ioremap.h | 23 - arch/sh/mm/ioremap_fixed.c | 135 -- arch/sh/mm/kmap.c | 65 - arch/sh/mm/mmap.c | 184 -- arch/sh/mm/nommu.c | 98 - arch/sh/mm/numa.c | 56 - arch/sh/mm/pgtable.c | 57 - arch/sh/mm/pmb.c | 887 --------- arch/sh/mm/sram.c | 35 - arch/sh/mm/tlb-debugfs.c | 160 -- arch/sh/mm/tlb-pteaex.c | 106 -- arch/sh/mm/tlb-sh3.c | 95 - arch/sh/mm/tlb-sh4.c | 108 -- arch/sh/mm/tlb-urb.c | 93 - arch/sh/mm/tlbex_32.c | 82 - arch/sh/mm/tlbflush_32.c | 137 -- arch/sh/mm/uncached.c | 44 - arch/sh/tools/Makefile | 16 - arch/sh/tools/gen-mach-types | 48 - arch/sh/tools/mach-types | 67 - drivers/clocksource/sh_cmt.c | 8 - drivers/clocksource/sh_mtu2.c | 8 - drivers/clocksource/sh_tmu.c | 8 - drivers/i2c/busses/Kconfig | 4 +- drivers/media/platform/renesas/Kconfig | 2 +- drivers/mmc/host/Kconfig | 6 +- drivers/mmc/host/sh_mmcif.c | 21 +- drivers/net/ethernet/8390/Kconfig | 2 +- drivers/net/ethernet/renesas/Kconfig | 2 +- drivers/net/ethernet/smsc/Kconfig | 4 +- drivers/rtc/Kconfig | 4 +- drivers/rtc/rtc-sh.c | 18 +- drivers/spi/Kconfig | 4 +- drivers/tty/serial/Kconfig | 3 +- drivers/tty/serial/sh-sci.c | 57 - drivers/tty/vt/keyboard.c | 2 +- drivers/usb/renesas_usbhs/Kconfig | 2 +- drivers/video/console/Kconfig | 2 +- drivers/video/logo/Kconfig | 15 - drivers/video/logo/Makefile | 3 - drivers/video/logo/logo.c | 12 - drivers/video/logo/logo_superh_clut224.ppm | 1604 ----------------- drivers/video/logo/logo_superh_vga16.ppm | 1604 ----------------- fs/Kconfig.binfmt | 2 +- fs/minix/Kconfig | 2 +- include/linux/cpuhotplug.h | 1 - include/linux/sh_intc.h | 4 - init/Kconfig | 2 +- kernel/sysctl.c | 3 +- lib/Kconfig.debug | 2 +- lib/math/div64.c | 4 +- lib/test_user_copy.c | 3 +- scripts/coccinelle/misc/cond_no_effect.cocci | 13 +- scripts/head-object-list.txt | 1 - sound/soc/sh/Kconfig | 4 +- tools/include/asm/barrier.h | 2 - tools/perf/util/dwarf-regs.c | 1 - 785 files changed, 36 insertions(+), 97715 deletions(-) delete mode 100644 Documentation/sh/booting.rst delete mode 100644 Documentation/sh/features.rst delete mode 100644 Documentation/sh/index.rst delete mode 100644 Documentation/sh/new-machine.rst delete mode 100644 Documentation/sh/register-banks.rst delete mode 100644 arch/sh/Kbuild delete mode 100644 arch/sh/Kconfig delete mode 100644 arch/sh/Kconfig.cpu delete mode 100644 arch/sh/Kconfig.debug delete mode 100644 arch/sh/Makefile delete mode 100644 arch/sh/boards/Kconfig delete mode 100644 arch/sh/boards/Makefile delete mode 100644 arch/sh/boards/board-apsh4a3a.c delete mode 100644 arch/sh/boards/board-apsh4ad0a.c delete mode 100644 arch/sh/boards/board-edosk7705.c delete mode 100644 arch/sh/boards/board-edosk7760.c delete mode 100644 arch/sh/boards/board-espt.c delete mode 100644 arch/sh/boards/board-magicpanelr2.c delete mode 100644 arch/sh/boards/board-polaris.c delete mode 100644 arch/sh/boards/board-secureedge5410.c delete mode 100644 arch/sh/boards/board-sh2007.c delete mode 100644 arch/sh/boards/board-sh7757lcr.c delete mode 100644 arch/sh/boards/board-sh7785lcr.c delete mode 100644 arch/sh/boards/board-shmin.c delete mode 100644 arch/sh/boards/board-titan.c delete mode 100644 arch/sh/boards/board-urquell.c delete mode 100644 arch/sh/boards/mach-ap325rxa/Makefile delete mode 100644 arch/sh/boards/mach-ap325rxa/sdram.S delete mode 100644 arch/sh/boards/mach-ap325rxa/setup.c delete mode 100644 arch/sh/boards/mach-dreamcast/Makefile delete mode 100644 arch/sh/boards/mach-dreamcast/irq.c delete mode 100644 arch/sh/boards/mach-dreamcast/rtc.c delete mode 100644 arch/sh/boards/mach-dreamcast/setup.c delete mode 100644 arch/sh/boards/mach-ecovec24/Makefile delete mode 100644 arch/sh/boards/mach-ecovec24/sdram.S delete mode 100644 arch/sh/boards/mach-ecovec24/setup.c delete mode 100644 arch/sh/boards/mach-highlander/Kconfig delete mode 100644 arch/sh/boards/mach-highlander/Makefile delete mode 100644 arch/sh/boards/mach-highlander/irq-r7780mp.c delete mode 100644 arch/sh/boards/mach-highlander/irq-r7780rp.c delete mode 100644 arch/sh/boards/mach-highlander/irq-r7785rp.c delete mode 100644 arch/sh/boards/mach-highlander/pinmux-r7785rp.c delete mode 100644 arch/sh/boards/mach-highlander/psw.c delete mode 100644 arch/sh/boards/mach-highlander/setup.c delete mode 100644 arch/sh/boards/mach-hp6xx/Makefile delete mode 100644 arch/sh/boards/mach-hp6xx/hp6xx_apm.c delete mode 100644 arch/sh/boards/mach-hp6xx/pm.c delete mode 100644 arch/sh/boards/mach-hp6xx/pm_wakeup.S delete mode 100644 arch/sh/boards/mach-hp6xx/setup.c delete mode 100644 arch/sh/boards/mach-kfr2r09/Makefile delete mode 100644 arch/sh/boards/mach-kfr2r09/lcd_wqvga.c delete mode 100644 arch/sh/boards/mach-kfr2r09/sdram.S delete mode 100644 arch/sh/boards/mach-kfr2r09/setup.c delete mode 100644 arch/sh/boards/mach-landisk/Makefile delete mode 100644 arch/sh/boards/mach-landisk/gio.c delete mode 100644 arch/sh/boards/mach-landisk/irq.c delete mode 100644 arch/sh/boards/mach-landisk/psw.c delete mode 100644 arch/sh/boards/mach-landisk/setup.c delete mode 100644 arch/sh/boards/mach-lboxre2/Makefile delete mode 100644 arch/sh/boards/mach-lboxre2/irq.c delete mode 100644 arch/sh/boards/mach-lboxre2/setup.c delete mode 100644 arch/sh/boards/mach-microdev/Makefile delete mode 100644 arch/sh/boards/mach-microdev/fdc37c93xapm.c delete mode 100644 arch/sh/boards/mach-microdev/io.c delete mode 100644 arch/sh/boards/mach-microdev/irq.c delete mode 100644 arch/sh/boards/mach-microdev/setup.c delete mode 100644 arch/sh/boards/mach-migor/Kconfig delete mode 100644 arch/sh/boards/mach-migor/Makefile delete mode 100644 arch/sh/boards/mach-migor/lcd_qvga.c delete mode 100644 arch/sh/boards/mach-migor/sdram.S delete mode 100644 arch/sh/boards/mach-migor/setup.c delete mode 100644 arch/sh/boards/mach-r2d/Kconfig delete mode 100644 arch/sh/boards/mach-r2d/Makefile delete mode 100644 arch/sh/boards/mach-r2d/irq.c delete mode 100644 arch/sh/boards/mach-r2d/setup.c delete mode 100644 arch/sh/boards/mach-rsk/Kconfig delete mode 100644 arch/sh/boards/mach-rsk/Makefile delete mode 100644 arch/sh/boards/mach-rsk/devices-rsk7203.c delete mode 100644 arch/sh/boards/mach-rsk/devices-rsk7264.c delete mode 100644 arch/sh/boards/mach-rsk/devices-rsk7269.c delete mode 100644 arch/sh/boards/mach-rsk/setup.c delete mode 100644 arch/sh/boards/mach-sdk7780/Kconfig delete mode 100644 arch/sh/boards/mach-sdk7780/Makefile delete mode 100644 arch/sh/boards/mach-sdk7780/irq.c delete mode 100644 arch/sh/boards/mach-sdk7780/setup.c delete mode 100644 arch/sh/boards/mach-sdk7786/Makefile delete mode 100644 arch/sh/boards/mach-sdk7786/fpga.c delete mode 100644 arch/sh/boards/mach-sdk7786/gpio.c delete mode 100644 arch/sh/boards/mach-sdk7786/irq.c delete mode 100644 arch/sh/boards/mach-sdk7786/nmi.c delete mode 100644 arch/sh/boards/mach-sdk7786/setup.c delete mode 100644 arch/sh/boards/mach-sdk7786/sram.c delete mode 100644 arch/sh/boards/mach-se/7206/Makefile delete mode 100644 arch/sh/boards/mach-se/7206/irq.c delete mode 100644 arch/sh/boards/mach-se/7206/setup.c delete mode 100644 arch/sh/boards/mach-se/7343/Makefile delete mode 100644 arch/sh/boards/mach-se/7343/irq.c delete mode 100644 arch/sh/boards/mach-se/7343/setup.c delete mode 100644 arch/sh/boards/mach-se/770x/Makefile delete mode 100644 arch/sh/boards/mach-se/770x/irq.c delete mode 100644 arch/sh/boards/mach-se/770x/setup.c delete mode 100644 arch/sh/boards/mach-se/7721/Makefile delete mode 100644 arch/sh/boards/mach-se/7721/irq.c delete mode 100644 arch/sh/boards/mach-se/7721/setup.c delete mode 100644 arch/sh/boards/mach-se/7722/Makefile delete mode 100644 arch/sh/boards/mach-se/7722/irq.c delete mode 100644 arch/sh/boards/mach-se/7722/setup.c delete mode 100644 arch/sh/boards/mach-se/7724/Makefile delete mode 100644 arch/sh/boards/mach-se/7724/irq.c delete mode 100644 arch/sh/boards/mach-se/7724/sdram.S delete mode 100644 arch/sh/boards/mach-se/7724/setup.c delete mode 100644 arch/sh/boards/mach-se/7751/Makefile delete mode 100644 arch/sh/boards/mach-se/7751/irq.c delete mode 100644 arch/sh/boards/mach-se/7751/setup.c delete mode 100644 arch/sh/boards/mach-se/7780/Makefile delete mode 100644 arch/sh/boards/mach-se/7780/irq.c delete mode 100644 arch/sh/boards/mach-se/7780/setup.c delete mode 100644 arch/sh/boards/mach-se/Makefile delete mode 100644 arch/sh/boards/mach-se/board-se7619.c delete mode 100644 arch/sh/boards/mach-sh03/Makefile delete mode 100644 arch/sh/boards/mach-sh03/rtc.c delete mode 100644 arch/sh/boards/mach-sh03/setup.c delete mode 100644 arch/sh/boards/mach-sh7763rdp/Makefile delete mode 100644 arch/sh/boards/mach-sh7763rdp/irq.c delete mode 100644 arch/sh/boards/mach-sh7763rdp/setup.c delete mode 100644 arch/sh/boards/mach-x3proto/Makefile delete mode 100644 arch/sh/boards/mach-x3proto/gpio.c delete mode 100644 arch/sh/boards/mach-x3proto/ilsel.c delete mode 100644 arch/sh/boards/mach-x3proto/setup.c delete mode 100644 arch/sh/boards/of-generic.c delete mode 100644 arch/sh/boot/.gitignore delete mode 100644 arch/sh/boot/Makefile delete mode 100644 arch/sh/boot/compressed/.gitignore delete mode 100644 arch/sh/boot/compressed/Makefile delete mode 100644 arch/sh/boot/compressed/ashiftrt.S delete mode 100644 arch/sh/boot/compressed/ashldi3.c delete mode 100644 arch/sh/boot/compressed/ashlsi3.S delete mode 100644 arch/sh/boot/compressed/ashrsi3.S delete mode 100644 arch/sh/boot/compressed/cache.c delete mode 100644 arch/sh/boot/compressed/head_32.S delete mode 100644 arch/sh/boot/compressed/head_64.S delete mode 100644 arch/sh/boot/compressed/lshrsi3.S delete mode 100644 arch/sh/boot/compressed/misc.c delete mode 100644 arch/sh/boot/compressed/vmlinux.scr delete mode 100644 arch/sh/boot/dts/Makefile delete mode 100644 arch/sh/boot/dts/j2_mimas_v2.dts delete mode 100644 arch/sh/boot/romimage/Makefile delete mode 100644 arch/sh/boot/romimage/head.S delete mode 100644 arch/sh/boot/romimage/mmcif-sh7724.c delete mode 100644 arch/sh/boot/romimage/vmlinux.scr delete mode 100644 arch/sh/cchips/Kconfig delete mode 100644 arch/sh/cchips/hd6446x/Makefile delete mode 100644 arch/sh/cchips/hd6446x/hd64461.c delete mode 100644 arch/sh/configs/ap325rxa_defconfig delete mode 100644 arch/sh/configs/apsh4a3a_defconfig delete mode 100644 arch/sh/configs/apsh4ad0a_defconfig delete mode 100644 arch/sh/configs/dreamcast_defconfig delete mode 100644 arch/sh/configs/ecovec24-romimage_defconfig delete mode 100644 arch/sh/configs/ecovec24_defconfig delete mode 100644 arch/sh/configs/edosk7705_defconfig delete mode 100644 arch/sh/configs/edosk7760_defconfig delete mode 100644 arch/sh/configs/espt_defconfig delete mode 100644 arch/sh/configs/hp6xx_defconfig delete mode 100644 arch/sh/configs/j2_defconfig delete mode 100644 arch/sh/configs/kfr2r09-romimage_defconfig delete mode 100644 arch/sh/configs/kfr2r09_defconfig delete mode 100644 arch/sh/configs/landisk_defconfig delete mode 100644 arch/sh/configs/lboxre2_defconfig delete mode 100644 arch/sh/configs/magicpanelr2_defconfig delete mode 100644 arch/sh/configs/microdev_defconfig delete mode 100644 arch/sh/configs/migor_defconfig delete mode 100644 arch/sh/configs/polaris_defconfig delete mode 100644 arch/sh/configs/r7780mp_defconfig delete mode 100644 arch/sh/configs/r7785rp_defconfig delete mode 100644 arch/sh/configs/rsk7201_defconfig delete mode 100644 arch/sh/configs/rsk7203_defconfig delete mode 100644 arch/sh/configs/rsk7264_defconfig delete mode 100644 arch/sh/configs/rsk7269_defconfig delete mode 100644 arch/sh/configs/rts7751r2d1_defconfig delete mode 100644 arch/sh/configs/rts7751r2dplus_defconfig delete mode 100644 arch/sh/configs/sdk7780_defconfig delete mode 100644 arch/sh/configs/sdk7786_defconfig delete mode 100644 arch/sh/configs/se7206_defconfig delete mode 100644 arch/sh/configs/se7343_defconfig delete mode 100644 arch/sh/configs/se7619_defconfig delete mode 100644 arch/sh/configs/se7705_defconfig delete mode 100644 arch/sh/configs/se7712_defconfig delete mode 100644 arch/sh/configs/se7721_defconfig delete mode 100644 arch/sh/configs/se7722_defconfig delete mode 100644 arch/sh/configs/se7724_defconfig delete mode 100644 arch/sh/configs/se7750_defconfig delete mode 100644 arch/sh/configs/se7751_defconfig delete mode 100644 arch/sh/configs/se7780_defconfig delete mode 100644 arch/sh/configs/secureedge5410_defconfig delete mode 100644 arch/sh/configs/sh03_defconfig delete mode 100644 arch/sh/configs/sh2007_defconfig delete mode 100644 arch/sh/configs/sh7710voipgw_defconfig delete mode 100644 arch/sh/configs/sh7724_generic_defconfig delete mode 100644 arch/sh/configs/sh7757lcr_defconfig delete mode 100644 arch/sh/configs/sh7763rdp_defconfig delete mode 100644 arch/sh/configs/sh7770_generic_defconfig delete mode 100644 arch/sh/configs/sh7785lcr_32bit_defconfig delete mode 100644 arch/sh/configs/sh7785lcr_defconfig delete mode 100644 arch/sh/configs/shmin_defconfig delete mode 100644 arch/sh/configs/shx3_defconfig delete mode 100644 arch/sh/configs/titan_defconfig delete mode 100644 arch/sh/configs/ul2_defconfig delete mode 100644 arch/sh/configs/urquell_defconfig delete mode 100644 arch/sh/drivers/Kconfig delete mode 100644 arch/sh/drivers/Makefile delete mode 100644 arch/sh/drivers/dma/Kconfig delete mode 100644 arch/sh/drivers/dma/Makefile delete mode 100644 arch/sh/drivers/dma/dma-api.c delete mode 100644 arch/sh/drivers/dma/dma-g2.c delete mode 100644 arch/sh/drivers/dma/dma-pvr2.c delete mode 100644 arch/sh/drivers/dma/dma-sh.c delete mode 100644 arch/sh/drivers/dma/dma-sysfs.c delete mode 100644 arch/sh/drivers/dma/dmabrg.c delete mode 100644 arch/sh/drivers/heartbeat.c delete mode 100644 arch/sh/drivers/pci/Makefile delete mode 100644 arch/sh/drivers/pci/common.c delete mode 100644 arch/sh/drivers/pci/fixups-dreamcast.c delete mode 100644 arch/sh/drivers/pci/fixups-landisk.c delete mode 100644 arch/sh/drivers/pci/fixups-r7780rp.c delete mode 100644 arch/sh/drivers/pci/fixups-rts7751r2d.c delete mode 100644 arch/sh/drivers/pci/fixups-sdk7780.c delete mode 100644 arch/sh/drivers/pci/fixups-sdk7786.c delete mode 100644 arch/sh/drivers/pci/fixups-se7751.c delete mode 100644 arch/sh/drivers/pci/fixups-sh03.c delete mode 100644 arch/sh/drivers/pci/fixups-snapgear.c delete mode 100644 arch/sh/drivers/pci/fixups-titan.c delete mode 100644 arch/sh/drivers/pci/ops-dreamcast.c delete mode 100644 arch/sh/drivers/pci/ops-sh4.c delete mode 100644 arch/sh/drivers/pci/ops-sh7786.c delete mode 100644 arch/sh/drivers/pci/pci-dreamcast.c delete mode 100644 arch/sh/drivers/pci/pci-sh4.h delete mode 100644 arch/sh/drivers/pci/pci-sh7751.c delete mode 100644 arch/sh/drivers/pci/pci-sh7751.h delete mode 100644 arch/sh/drivers/pci/pci-sh7780.c delete mode 100644 arch/sh/drivers/pci/pci-sh7780.h delete mode 100644 arch/sh/drivers/pci/pci.c delete mode 100644 arch/sh/drivers/pci/pcie-sh7786.c delete mode 100644 arch/sh/drivers/pci/pcie-sh7786.h delete mode 100644 arch/sh/drivers/platform_early.c delete mode 100644 arch/sh/drivers/push-switch.c delete mode 100644 arch/sh/drivers/superhyway/Makefile delete mode 100644 arch/sh/drivers/superhyway/ops-sh4-202.c delete mode 100644 arch/sh/include/asm/Kbuild delete mode 100644 arch/sh/include/asm/adc.h delete mode 100644 arch/sh/include/asm/addrspace.h delete mode 100644 arch/sh/include/asm/alignment.h delete mode 100644 arch/sh/include/asm/asm-offsets.h delete mode 100644 arch/sh/include/asm/atomic-grb.h delete mode 100644 arch/sh/include/asm/atomic-irq.h delete mode 100644 arch/sh/include/asm/atomic-llsc.h delete mode 100644 arch/sh/include/asm/atomic.h delete mode 100644 arch/sh/include/asm/barrier.h delete mode 100644 arch/sh/include/asm/bitops-cas.h delete mode 100644 arch/sh/include/asm/bitops-grb.h delete mode 100644 arch/sh/include/asm/bitops-llsc.h delete mode 100644 arch/sh/include/asm/bitops-op32.h delete mode 100644 arch/sh/include/asm/bitops.h delete mode 100644 arch/sh/include/asm/bl_bit.h delete mode 100644 arch/sh/include/asm/bl_bit_32.h delete mode 100644 arch/sh/include/asm/bug.h delete mode 100644 arch/sh/include/asm/bugs.h delete mode 100644 arch/sh/include/asm/cache.h delete mode 100644 arch/sh/include/asm/cache_insns.h delete mode 100644 arch/sh/include/asm/cache_insns_32.h delete mode 100644 arch/sh/include/asm/cacheflush.h delete mode 100644 arch/sh/include/asm/checksum.h delete mode 100644 arch/sh/include/asm/checksum_32.h delete mode 100644 arch/sh/include/asm/clock.h delete mode 100644 arch/sh/include/asm/cmpxchg-cas.h delete mode 100644 arch/sh/include/asm/cmpxchg-grb.h delete mode 100644 arch/sh/include/asm/cmpxchg-irq.h delete mode 100644 arch/sh/include/asm/cmpxchg-llsc.h delete mode 100644 arch/sh/include/asm/cmpxchg-xchg.h delete mode 100644 arch/sh/include/asm/cmpxchg.h delete mode 100644 arch/sh/include/asm/device.h delete mode 100644 arch/sh/include/asm/dma-register.h delete mode 100644 arch/sh/include/asm/dma.h delete mode 100644 arch/sh/include/asm/dmabrg.h delete mode 100644 arch/sh/include/asm/dwarf.h delete mode 100644 arch/sh/include/asm/elf.h delete mode 100644 arch/sh/include/asm/entry-macros.S delete mode 100644 arch/sh/include/asm/extable.h delete mode 100644 arch/sh/include/asm/fb.h delete mode 100644 arch/sh/include/asm/fixmap.h delete mode 100644 arch/sh/include/asm/flat.h delete mode 100644 arch/sh/include/asm/fpu.h delete mode 100644 arch/sh/include/asm/freq.h delete mode 100644 arch/sh/include/asm/ftrace.h delete mode 100644 arch/sh/include/asm/futex-cas.h delete mode 100644 arch/sh/include/asm/futex-irq.h delete mode 100644 arch/sh/include/asm/futex-llsc.h delete mode 100644 arch/sh/include/asm/futex.h delete mode 100644 arch/sh/include/asm/gpio.h delete mode 100644 arch/sh/include/asm/hardirq.h delete mode 100644 arch/sh/include/asm/hd64461.h delete mode 100644 arch/sh/include/asm/heartbeat.h delete mode 100644 arch/sh/include/asm/hugetlb.h delete mode 100644 arch/sh/include/asm/hw_breakpoint.h delete mode 100644 arch/sh/include/asm/hw_irq.h delete mode 100644 arch/sh/include/asm/i2c-sh7760.h delete mode 100644 arch/sh/include/asm/io.h delete mode 100644 arch/sh/include/asm/io_generic.h delete mode 100644 arch/sh/include/asm/io_noioport.h delete mode 100644 arch/sh/include/asm/io_trapped.h delete mode 100644 arch/sh/include/asm/irq.h delete mode 100644 arch/sh/include/asm/irqflags.h delete mode 100644 arch/sh/include/asm/kdebug.h delete mode 100644 arch/sh/include/asm/kexec.h delete mode 100644 arch/sh/include/asm/kgdb.h delete mode 100644 arch/sh/include/asm/kprobes.h delete mode 100644 arch/sh/include/asm/linkage.h delete mode 100644 arch/sh/include/asm/machvec.h delete mode 100644 arch/sh/include/asm/mmiowb.h delete mode 100644 arch/sh/include/asm/mmu.h delete mode 100644 arch/sh/include/asm/mmu_context.h delete mode 100644 arch/sh/include/asm/mmu_context_32.h delete mode 100644 arch/sh/include/asm/mmzone.h delete mode 100644 arch/sh/include/asm/module.h delete mode 100644 arch/sh/include/asm/page.h delete mode 100644 arch/sh/include/asm/pci.h delete mode 100644 arch/sh/include/asm/perf_event.h delete mode 100644 arch/sh/include/asm/pgalloc.h delete mode 100644 arch/sh/include/asm/pgtable-2level.h delete mode 100644 arch/sh/include/asm/pgtable-3level.h delete mode 100644 arch/sh/include/asm/pgtable.h delete mode 100644 arch/sh/include/asm/pgtable_32.h delete mode 100644 arch/sh/include/asm/platform_early.h delete mode 100644 arch/sh/include/asm/posix_types.h delete mode 100644 arch/sh/include/asm/processor.h delete mode 100644 arch/sh/include/asm/processor_32.h delete mode 100644 arch/sh/include/asm/ptrace.h delete mode 100644 arch/sh/include/asm/ptrace_32.h delete mode 100644 arch/sh/include/asm/push-switch.h delete mode 100644 arch/sh/include/asm/reboot.h delete mode 100644 arch/sh/include/asm/romimage-macros.h delete mode 100644 arch/sh/include/asm/rtc.h delete mode 100644 arch/sh/include/asm/seccomp.h delete mode 100644 arch/sh/include/asm/sections.h delete mode 100644 arch/sh/include/asm/setup.h delete mode 100644 arch/sh/include/asm/sfp-machine.h delete mode 100644 arch/sh/include/asm/sh7760fb.h delete mode 100644 arch/sh/include/asm/sh_bios.h delete mode 100644 arch/sh/include/asm/shmparam.h delete mode 100644 arch/sh/include/asm/siu.h delete mode 100644 arch/sh/include/asm/smc37c93x.h delete mode 100644 arch/sh/include/asm/smp-ops.h delete mode 100644 arch/sh/include/asm/smp.h delete mode 100644 arch/sh/include/asm/sparsemem.h delete mode 100644 arch/sh/include/asm/spi.h delete mode 100644 arch/sh/include/asm/spinlock-cas.h delete mode 100644 arch/sh/include/asm/spinlock-llsc.h delete mode 100644 arch/sh/include/asm/spinlock.h delete mode 100644 arch/sh/include/asm/spinlock_types.h delete mode 100644 arch/sh/include/asm/sram.h delete mode 100644 arch/sh/include/asm/stackprotector.h delete mode 100644 arch/sh/include/asm/stacktrace.h delete mode 100644 arch/sh/include/asm/string.h delete mode 100644 arch/sh/include/asm/string_32.h delete mode 100644 arch/sh/include/asm/suspend.h delete mode 100644 arch/sh/include/asm/switch_to.h delete mode 100644 arch/sh/include/asm/switch_to_32.h delete mode 100644 arch/sh/include/asm/syscall.h delete mode 100644 arch/sh/include/asm/syscall_32.h delete mode 100644 arch/sh/include/asm/syscalls.h delete mode 100644 arch/sh/include/asm/syscalls_32.h delete mode 100644 arch/sh/include/asm/thread_info.h delete mode 100644 arch/sh/include/asm/timex.h delete mode 100644 arch/sh/include/asm/tlb.h delete mode 100644 arch/sh/include/asm/tlbflush.h delete mode 100644 arch/sh/include/asm/topology.h delete mode 100644 arch/sh/include/asm/traps.h delete mode 100644 arch/sh/include/asm/traps_32.h delete mode 100644 arch/sh/include/asm/types.h delete mode 100644 arch/sh/include/asm/uaccess.h delete mode 100644 arch/sh/include/asm/uaccess_32.h delete mode 100644 arch/sh/include/asm/uncached.h delete mode 100644 arch/sh/include/asm/unistd.h delete mode 100644 arch/sh/include/asm/unwinder.h delete mode 100644 arch/sh/include/asm/user.h delete mode 100644 arch/sh/include/asm/vermagic.h delete mode 100644 arch/sh/include/asm/vga.h delete mode 100644 arch/sh/include/asm/vmalloc.h delete mode 100644 arch/sh/include/asm/vmlinux.lds.h delete mode 100644 arch/sh/include/asm/watchdog.h delete mode 100644 arch/sh/include/asm/word-at-a-time.h delete mode 100644 arch/sh/include/cpu-common/cpu/addrspace.h delete mode 100644 arch/sh/include/cpu-common/cpu/mmu_context.h delete mode 100644 arch/sh/include/cpu-common/cpu/pfc.h delete mode 100644 arch/sh/include/cpu-common/cpu/rtc.h delete mode 100644 arch/sh/include/cpu-common/cpu/sigcontext.h delete mode 100644 arch/sh/include/cpu-common/cpu/timer.h delete mode 100644 arch/sh/include/cpu-sh2/cpu/cache.h delete mode 100644 arch/sh/include/cpu-sh2/cpu/freq.h delete mode 100644 arch/sh/include/cpu-sh2/cpu/watchdog.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/addrspace.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/cache.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/freq.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/rtc.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/sh7203.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/sh7264.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/sh7269.h delete mode 100644 arch/sh/include/cpu-sh2a/cpu/watchdog.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/adc.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/cache.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/dac.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/dma-register.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/dma.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/freq.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/gpio.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/mmu_context.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/serial.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/sh7720.h delete mode 100644 arch/sh/include/cpu-sh3/cpu/watchdog.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/addrspace.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/cache.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/dma-register.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/dma.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/fpu.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/freq.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/mmu_context.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/rtc.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7722.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7723.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7724.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7734.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7757.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7785.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sh7786.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/shx3.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sigcontext.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/sq.h delete mode 100644 arch/sh/include/cpu-sh4/cpu/watchdog.h delete mode 100644 arch/sh/include/cpu-sh4a/cpu/dma.h delete mode 100644 arch/sh/include/cpu-sh4a/cpu/serial.h delete mode 100644 arch/sh/include/mach-common/mach/highlander.h delete mode 100644 arch/sh/include/mach-common/mach/hp6xx.h delete mode 100644 arch/sh/include/mach-common/mach/lboxre2.h delete mode 100644 arch/sh/include/mach-common/mach/magicpanelr2.h delete mode 100644 arch/sh/include/mach-common/mach/mangle-port.h delete mode 100644 arch/sh/include/mach-common/mach/microdev.h delete mode 100644 arch/sh/include/mach-common/mach/r2d.h delete mode 100644 arch/sh/include/mach-common/mach/romimage.h delete mode 100644 arch/sh/include/mach-common/mach/sdk7780.h delete mode 100644 arch/sh/include/mach-common/mach/secureedge5410.h delete mode 100644 arch/sh/include/mach-common/mach/sh2007.h delete mode 100644 arch/sh/include/mach-common/mach/sh7763rdp.h delete mode 100644 arch/sh/include/mach-common/mach/sh7785lcr.h delete mode 100644 arch/sh/include/mach-common/mach/shmin.h delete mode 100644 arch/sh/include/mach-common/mach/titan.h delete mode 100644 arch/sh/include/mach-common/mach/urquell.h delete mode 100644 arch/sh/include/mach-dreamcast/mach/dma.h delete mode 100644 arch/sh/include/mach-dreamcast/mach/maple.h delete mode 100644 arch/sh/include/mach-dreamcast/mach/pci.h delete mode 100644 arch/sh/include/mach-dreamcast/mach/sysasic.h delete mode 100644 arch/sh/include/mach-ecovec24/mach/partner-jet-setup.txt delete mode 100644 arch/sh/include/mach-ecovec24/mach/romimage.h delete mode 100644 arch/sh/include/mach-kfr2r09/mach/kfr2r09.h delete mode 100644 arch/sh/include/mach-kfr2r09/mach/partner-jet-setup.txt delete mode 100644 arch/sh/include/mach-kfr2r09/mach/romimage.h delete mode 100644 arch/sh/include/mach-landisk/mach/gio.h delete mode 100644 arch/sh/include/mach-landisk/mach/iodata_landisk.h delete mode 100644 arch/sh/include/mach-migor/mach/migor.h delete mode 100644 arch/sh/include/mach-sdk7786/mach/fpga.h delete mode 100644 arch/sh/include/mach-sdk7786/mach/irq.h delete mode 100644 arch/sh/include/mach-se/mach/mrshpc.h delete mode 100644 arch/sh/include/mach-se/mach/se.h delete mode 100644 arch/sh/include/mach-se/mach/se7206.h delete mode 100644 arch/sh/include/mach-se/mach/se7343.h delete mode 100644 arch/sh/include/mach-se/mach/se7721.h delete mode 100644 arch/sh/include/mach-se/mach/se7722.h delete mode 100644 arch/sh/include/mach-se/mach/se7724.h delete mode 100644 arch/sh/include/mach-se/mach/se7751.h delete mode 100644 arch/sh/include/mach-se/mach/se7780.h delete mode 100644 arch/sh/include/mach-sh03/mach/io.h delete mode 100644 arch/sh/include/mach-sh03/mach/sh03.h delete mode 100644 arch/sh/include/mach-x3proto/mach/hardware.h delete mode 100644 arch/sh/include/mach-x3proto/mach/ilsel.h delete mode 100644 arch/sh/include/uapi/asm/Kbuild delete mode 100644 arch/sh/include/uapi/asm/auxvec.h delete mode 100644 arch/sh/include/uapi/asm/byteorder.h delete mode 100644 arch/sh/include/uapi/asm/cachectl.h delete mode 100644 arch/sh/include/uapi/asm/cpu-features.h delete mode 100644 arch/sh/include/uapi/asm/hw_breakpoint.h delete mode 100644 arch/sh/include/uapi/asm/ioctls.h delete mode 100644 arch/sh/include/uapi/asm/posix_types.h delete mode 100644 arch/sh/include/uapi/asm/posix_types_32.h delete mode 100644 arch/sh/include/uapi/asm/ptrace.h delete mode 100644 arch/sh/include/uapi/asm/ptrace_32.h delete mode 100644 arch/sh/include/uapi/asm/sigcontext.h delete mode 100644 arch/sh/include/uapi/asm/signal.h delete mode 100644 arch/sh/include/uapi/asm/sockios.h delete mode 100644 arch/sh/include/uapi/asm/stat.h delete mode 100644 arch/sh/include/uapi/asm/swab.h delete mode 100644 arch/sh/include/uapi/asm/unistd.h delete mode 100644 arch/sh/kernel/.gitignore delete mode 100644 arch/sh/kernel/Makefile delete mode 100644 arch/sh/kernel/asm-offsets.c delete mode 100644 arch/sh/kernel/cpu/Makefile delete mode 100644 arch/sh/kernel/cpu/adc.c delete mode 100644 arch/sh/kernel/cpu/clock-cpg.c delete mode 100644 arch/sh/kernel/cpu/clock.c delete mode 100644 arch/sh/kernel/cpu/fpu.c delete mode 100644 arch/sh/kernel/cpu/init.c delete mode 100644 arch/sh/kernel/cpu/irq/Makefile delete mode 100644 arch/sh/kernel/cpu/irq/imask.c delete mode 100644 arch/sh/kernel/cpu/irq/ipr.c delete mode 100644 arch/sh/kernel/cpu/pfc.c delete mode 100644 arch/sh/kernel/cpu/proc.c delete mode 100644 arch/sh/kernel/cpu/sh2/Makefile delete mode 100644 arch/sh/kernel/cpu/sh2/clock-sh7619.c delete mode 100644 arch/sh/kernel/cpu/sh2/entry.S delete mode 100644 arch/sh/kernel/cpu/sh2/ex.S delete mode 100644 arch/sh/kernel/cpu/sh2/probe.c delete mode 100644 arch/sh/kernel/cpu/sh2/setup-sh7619.c delete mode 100644 arch/sh/kernel/cpu/sh2/smp-j2.c delete mode 100644 arch/sh/kernel/cpu/sh2a/Makefile delete mode 100644 arch/sh/kernel/cpu/sh2a/clock-sh7201.c delete mode 100644 arch/sh/kernel/cpu/sh2a/clock-sh7203.c delete mode 100644 arch/sh/kernel/cpu/sh2a/clock-sh7206.c delete mode 100644 arch/sh/kernel/cpu/sh2a/clock-sh7264.c delete mode 100644 arch/sh/kernel/cpu/sh2a/clock-sh7269.c delete mode 100644 arch/sh/kernel/cpu/sh2a/entry.S delete mode 100644 arch/sh/kernel/cpu/sh2a/ex.S delete mode 100644 arch/sh/kernel/cpu/sh2a/fpu.c delete mode 100644 arch/sh/kernel/cpu/sh2a/opcode_helper.c delete mode 100644 arch/sh/kernel/cpu/sh2a/pinmux-sh7203.c delete mode 100644 arch/sh/kernel/cpu/sh2a/pinmux-sh7264.c delete mode 100644 arch/sh/kernel/cpu/sh2a/pinmux-sh7269.c delete mode 100644 arch/sh/kernel/cpu/sh2a/probe.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-mxg.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-sh7201.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-sh7203.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-sh7206.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-sh7264.c delete mode 100644 arch/sh/kernel/cpu/sh2a/setup-sh7269.c delete mode 100644 arch/sh/kernel/cpu/sh3/Makefile delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh3.c delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh7705.c delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh7706.c delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh7709.c delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh7710.c delete mode 100644 arch/sh/kernel/cpu/sh3/clock-sh7712.c delete mode 100644 arch/sh/kernel/cpu/sh3/entry.S delete mode 100644 arch/sh/kernel/cpu/sh3/ex.S delete mode 100644 arch/sh/kernel/cpu/sh3/pinmux-sh7720.c delete mode 100644 arch/sh/kernel/cpu/sh3/probe.c delete mode 100644 arch/sh/kernel/cpu/sh3/serial-sh770x.c delete mode 100644 arch/sh/kernel/cpu/sh3/serial-sh7710.c delete mode 100644 arch/sh/kernel/cpu/sh3/serial-sh7720.c delete mode 100644 arch/sh/kernel/cpu/sh3/setup-sh3.c delete mode 100644 arch/sh/kernel/cpu/sh3/setup-sh7705.c delete mode 100644 arch/sh/kernel/cpu/sh3/setup-sh770x.c delete mode 100644 arch/sh/kernel/cpu/sh3/setup-sh7710.c delete mode 100644 arch/sh/kernel/cpu/sh3/setup-sh7720.c delete mode 100644 arch/sh/kernel/cpu/sh3/swsusp.S delete mode 100644 arch/sh/kernel/cpu/sh4/Makefile delete mode 100644 arch/sh/kernel/cpu/sh4/clock-sh4-202.c delete mode 100644 arch/sh/kernel/cpu/sh4/clock-sh4.c delete mode 100644 arch/sh/kernel/cpu/sh4/fpu.c delete mode 100644 arch/sh/kernel/cpu/sh4/perf_event.c delete mode 100644 arch/sh/kernel/cpu/sh4/probe.c delete mode 100644 arch/sh/kernel/cpu/sh4/setup-sh4-202.c delete mode 100644 arch/sh/kernel/cpu/sh4/setup-sh7750.c delete mode 100644 arch/sh/kernel/cpu/sh4/setup-sh7760.c delete mode 100644 arch/sh/kernel/cpu/sh4/softfloat.c delete mode 100644 arch/sh/kernel/cpu/sh4/sq.c delete mode 100644 arch/sh/kernel/cpu/sh4a/Makefile delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7343.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7366.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7722.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7723.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7724.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7734.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7757.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7763.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7770.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7780.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7785.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-sh7786.c delete mode 100644 arch/sh/kernel/cpu/sh4a/clock-shx3.c delete mode 100644 arch/sh/kernel/cpu/sh4a/intc-shx3.c delete mode 100644 arch/sh/kernel/cpu/sh4a/perf_event.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7722.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7723.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7724.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7734.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7757.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7785.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-sh7786.c delete mode 100644 arch/sh/kernel/cpu/sh4a/pinmux-shx3.c delete mode 100644 arch/sh/kernel/cpu/sh4a/serial-sh7722.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7343.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7366.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7722.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7723.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7724.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7734.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7757.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7763.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7770.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7780.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7785.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-sh7786.c delete mode 100644 arch/sh/kernel/cpu/sh4a/setup-shx3.c delete mode 100644 arch/sh/kernel/cpu/sh4a/smp-shx3.c delete mode 100644 arch/sh/kernel/cpu/sh4a/ubc.c delete mode 100644 arch/sh/kernel/cpu/shmobile/Makefile delete mode 100644 arch/sh/kernel/cpu/shmobile/cpuidle.c delete mode 100644 arch/sh/kernel/cpu/shmobile/pm.c delete mode 100644 arch/sh/kernel/cpu/shmobile/sleep.S delete mode 100644 arch/sh/kernel/crash_dump.c delete mode 100644 arch/sh/kernel/debugtraps.S delete mode 100644 arch/sh/kernel/disassemble.c delete mode 100644 arch/sh/kernel/dma-coherent.c delete mode 100644 arch/sh/kernel/dumpstack.c delete mode 100644 arch/sh/kernel/dwarf.c delete mode 100644 arch/sh/kernel/entry-common.S delete mode 100644 arch/sh/kernel/ftrace.c delete mode 100644 arch/sh/kernel/head_32.S delete mode 100644 arch/sh/kernel/hw_breakpoint.c delete mode 100644 arch/sh/kernel/idle.c delete mode 100644 arch/sh/kernel/io.c delete mode 100644 arch/sh/kernel/io_trapped.c delete mode 100644 arch/sh/kernel/iomap.c delete mode 100644 arch/sh/kernel/ioport.c delete mode 100644 arch/sh/kernel/irq.c delete mode 100644 arch/sh/kernel/irq_32.c delete mode 100644 arch/sh/kernel/kdebugfs.c delete mode 100644 arch/sh/kernel/kgdb.c delete mode 100644 arch/sh/kernel/kprobes.c delete mode 100644 arch/sh/kernel/machine_kexec.c delete mode 100644 arch/sh/kernel/machvec.c delete mode 100644 arch/sh/kernel/module.c delete mode 100644 arch/sh/kernel/nmi_debug.c delete mode 100644 arch/sh/kernel/perf_callchain.c delete mode 100644 arch/sh/kernel/perf_event.c delete mode 100644 arch/sh/kernel/process.c delete mode 100644 arch/sh/kernel/process_32.c delete mode 100644 arch/sh/kernel/ptrace.c delete mode 100644 arch/sh/kernel/ptrace_32.c delete mode 100644 arch/sh/kernel/reboot.c delete mode 100644 arch/sh/kernel/relocate_kernel.S delete mode 100644 arch/sh/kernel/return_address.c delete mode 100644 arch/sh/kernel/setup.c delete mode 100644 arch/sh/kernel/sh_bios.c delete mode 100644 arch/sh/kernel/sh_ksyms_32.c delete mode 100644 arch/sh/kernel/signal_32.c delete mode 100644 arch/sh/kernel/smp.c delete mode 100644 arch/sh/kernel/stacktrace.c delete mode 100644 arch/sh/kernel/swsusp.c delete mode 100644 arch/sh/kernel/sys_sh.c delete mode 100644 arch/sh/kernel/sys_sh32.c delete mode 100644 arch/sh/kernel/syscalls/Makefile delete mode 100644 arch/sh/kernel/syscalls/syscall.tbl delete mode 100644 arch/sh/kernel/syscalls_32.S delete mode 100644 arch/sh/kernel/time.c delete mode 100644 arch/sh/kernel/topology.c delete mode 100644 arch/sh/kernel/traps.c delete mode 100644 arch/sh/kernel/traps_32.c delete mode 100644 arch/sh/kernel/unwinder.c delete mode 100644 arch/sh/kernel/vmlinux.lds.S delete mode 100644 arch/sh/kernel/vsyscall/.gitignore delete mode 100644 arch/sh/kernel/vsyscall/Makefile delete mode 100644 arch/sh/kernel/vsyscall/vsyscall-note.S delete mode 100644 arch/sh/kernel/vsyscall/vsyscall-sigreturn.S delete mode 100644 arch/sh/kernel/vsyscall/vsyscall-syscall.S delete mode 100644 arch/sh/kernel/vsyscall/vsyscall-trapa.S delete mode 100644 arch/sh/kernel/vsyscall/vsyscall.c delete mode 100644 arch/sh/kernel/vsyscall/vsyscall.lds.S delete mode 100644 arch/sh/lib/Makefile delete mode 100644 arch/sh/lib/__clear_user.S delete mode 100644 arch/sh/lib/ashiftrt.S delete mode 100644 arch/sh/lib/ashldi3.c delete mode 100644 arch/sh/lib/ashlsi3.S delete mode 100644 arch/sh/lib/ashrdi3.c delete mode 100644 arch/sh/lib/ashrsi3.S delete mode 100644 arch/sh/lib/checksum.S delete mode 100644 arch/sh/lib/copy_page.S delete mode 100644 arch/sh/lib/delay.c delete mode 100644 arch/sh/lib/div64-generic.c delete mode 100644 arch/sh/lib/div64.S delete mode 100644 arch/sh/lib/io.c delete mode 100644 arch/sh/lib/libgcc.h delete mode 100644 arch/sh/lib/lshrdi3.c delete mode 100644 arch/sh/lib/lshrsi3.S delete mode 100644 arch/sh/lib/mcount.S delete mode 100644 arch/sh/lib/memchr.S delete mode 100644 arch/sh/lib/memcpy-sh4.S delete mode 100644 arch/sh/lib/memcpy.S delete mode 100644 arch/sh/lib/memmove.S delete mode 100644 arch/sh/lib/memset-sh4.S delete mode 100644 arch/sh/lib/memset.S delete mode 100644 arch/sh/lib/movmem.S delete mode 100644 arch/sh/lib/strlen.S delete mode 100644 arch/sh/lib/udiv_qrnnd.S delete mode 100644 arch/sh/lib/udivsi3.S delete mode 100644 arch/sh/lib/udivsi3_i4i-Os.S delete mode 100644 arch/sh/lib/udivsi3_i4i.S delete mode 100644 arch/sh/math-emu/Makefile delete mode 100644 arch/sh/math-emu/math.c delete mode 100644 arch/sh/math-emu/sfp-util.h delete mode 100644 arch/sh/mm/Kconfig delete mode 100644 arch/sh/mm/Makefile delete mode 100644 arch/sh/mm/alignment.c delete mode 100644 arch/sh/mm/asids-debugfs.c delete mode 100644 arch/sh/mm/cache-debugfs.c delete mode 100644 arch/sh/mm/cache-j2.c delete mode 100644 arch/sh/mm/cache-sh2.c delete mode 100644 arch/sh/mm/cache-sh2a.c delete mode 100644 arch/sh/mm/cache-sh3.c delete mode 100644 arch/sh/mm/cache-sh4.c delete mode 100644 arch/sh/mm/cache-sh7705.c delete mode 100644 arch/sh/mm/cache-shx3.c delete mode 100644 arch/sh/mm/cache.c delete mode 100644 arch/sh/mm/consistent.c delete mode 100644 arch/sh/mm/extable_32.c delete mode 100644 arch/sh/mm/fault.c delete mode 100644 arch/sh/mm/flush-sh4.c delete mode 100644 arch/sh/mm/hugetlbpage.c delete mode 100644 arch/sh/mm/init.c delete mode 100644 arch/sh/mm/ioremap.c delete mode 100644 arch/sh/mm/ioremap.h delete mode 100644 arch/sh/mm/ioremap_fixed.c delete mode 100644 arch/sh/mm/kmap.c delete mode 100644 arch/sh/mm/mmap.c delete mode 100644 arch/sh/mm/nommu.c delete mode 100644 arch/sh/mm/numa.c delete mode 100644 arch/sh/mm/pgtable.c delete mode 100644 arch/sh/mm/pmb.c delete mode 100644 arch/sh/mm/sram.c delete mode 100644 arch/sh/mm/tlb-debugfs.c delete mode 100644 arch/sh/mm/tlb-pteaex.c delete mode 100644 arch/sh/mm/tlb-sh3.c delete mode 100644 arch/sh/mm/tlb-sh4.c delete mode 100644 arch/sh/mm/tlb-urb.c delete mode 100644 arch/sh/mm/tlbex_32.c delete mode 100644 arch/sh/mm/tlbflush_32.c delete mode 100644 arch/sh/mm/uncached.c delete mode 100644 arch/sh/tools/Makefile delete mode 100644 arch/sh/tools/gen-mach-types delete mode 100644 arch/sh/tools/mach-types delete mode 100644 drivers/video/logo/logo_superh_clut224.ppm delete mode 100644 drivers/video/logo/logo_superh_vga16.ppm diff --git a/Documentation/arch.rst b/Documentation/arch.rst index 41a66a8b38e424..18669458eec4dd 100644 --- a/Documentation/arch.rst +++ b/Documentation/arch.rst @@ -22,7 +22,6 @@ implementation. powerpc/index riscv/index s390/index - sh/index sparc/index x86/index xtensa/index diff --git a/Documentation/sh/booting.rst b/Documentation/sh/booting.rst deleted file mode 100644 index d851c49a01bf07..00000000000000 --- a/Documentation/sh/booting.rst +++ /dev/null @@ -1,12 +0,0 @@ -.. SPDX-License-Identifier: GPL-2.0 - -DeviceTree Booting ------------------- - - Device-tree compatible SH bootloaders are expected to provide the physical - address of the device tree blob in r4. Since legacy bootloaders did not - guarantee any particular initial register state, kernels built to - inter-operate with old bootloaders must either use a builtin DTB or - select a legacy board option (something other than CONFIG_SH_DEVICE_TREE) - that does not use device tree. Support for the latter is being phased out - in favor of device tree. diff --git a/Documentation/sh/features.rst b/Documentation/sh/features.rst deleted file mode 100644 index f722af3b6c9934..00000000000000 --- a/Documentation/sh/features.rst +++ /dev/null @@ -1,3 +0,0 @@ -.. SPDX-License-Identifier: GPL-2.0 - -.. kernel-feat:: $srctree/Documentation/features sh diff --git a/Documentation/sh/index.rst b/Documentation/sh/index.rst deleted file mode 100644 index c64776738cf6b2..00000000000000 --- a/Documentation/sh/index.rst +++ /dev/null @@ -1,56 +0,0 @@ -======================= -SuperH Interfaces Guide -======================= - -:Author: Paul Mundt - -.. toctree:: - :maxdepth: 1 - - booting - new-machine - register-banks - - features - -Memory Management -================= - -SH-4 ----- - -Store Queue API -~~~~~~~~~~~~~~~ - -.. kernel-doc:: arch/sh/kernel/cpu/sh4/sq.c - :export: - -Machine Specific Interfaces -=========================== - -mach-dreamcast --------------- - -.. kernel-doc:: arch/sh/boards/mach-dreamcast/rtc.c - :internal: - -mach-x3proto ------------- - -.. kernel-doc:: arch/sh/boards/mach-x3proto/ilsel.c - :export: - -Busses -====== - -SuperHyway ----------- - -.. kernel-doc:: drivers/sh/superhyway/superhyway.c - :export: - -Maple ------ - -.. kernel-doc:: drivers/sh/maple/maple.c - :export: diff --git a/Documentation/sh/new-machine.rst b/Documentation/sh/new-machine.rst deleted file mode 100644 index e501c52b3b30d2..00000000000000 --- a/Documentation/sh/new-machine.rst +++ /dev/null @@ -1,277 +0,0 @@ -.. SPDX-License-Identifier: GPL-2.0 - -============================= -Adding a new board to LinuxSH -============================= - - Paul Mundt - -This document attempts to outline what steps are necessary to add support -for new boards to the LinuxSH port under the new 2.5 and 2.6 kernels. This -also attempts to outline some of the noticeable changes between the 2.4 -and the 2.5/2.6 SH backend. - -1. New Directory Structure -========================== - -The first thing to note is the new directory structure. Under 2.4, most -of the board-specific code (with the exception of stboards) ended up -in arch/sh/kernel/ directly, with board-specific headers ending up in -include/asm-sh/. For the new kernel, things are broken out by board type, -companion chip type, and CPU type. Looking at a tree view of this directory -hierarchy looks like the following: - -Board-specific code:: - - . - |-- arch - | `-- sh - | `-- boards - | |-- adx - | | `-- board-specific files - | |-- bigsur - | | `-- board-specific files - | | - | ... more boards here ... - | - `-- include - `-- asm-sh - |-- adx - | `-- board-specific headers - |-- bigsur - | `-- board-specific headers - | - .. more boards here ... - -Next, for companion chips:: - - . - `-- arch - `-- sh - `-- cchips - `-- hd6446x - `-- hd64461 - `-- cchip-specific files - -... and so on. Headers for the companion chips are treated the same way as -board-specific headers. Thus, include/asm-sh/hd64461 is home to all of the -hd64461-specific headers. - -Finally, CPU family support is also abstracted:: - - . - |-- arch - | `-- sh - | |-- kernel - | | `-- cpu - | | |-- sh2 - | | | `-- SH-2 generic files - | | |-- sh3 - | | | `-- SH-3 generic files - | | `-- sh4 - | | `-- SH-4 generic files - | `-- mm - | `-- This is also broken out per CPU family, so each family can - | have their own set of cache/tlb functions. - | - `-- include - `-- asm-sh - |-- cpu-sh2 - | `-- SH-2 specific headers - |-- cpu-sh3 - | `-- SH-3 specific headers - `-- cpu-sh4 - `-- SH-4 specific headers - -It should be noted that CPU subtypes are _not_ abstracted. Thus, these still -need to be dealt with by the CPU family specific code. - -2. Adding a New Board -===================== - -The first thing to determine is whether the board you are adding will be -isolated, or whether it will be part of a family of boards that can mostly -share the same board-specific code with minor differences. - -In the first case, this is just a matter of making a directory for your -board in arch/sh/boards/ and adding rules to hook your board in with the -build system (more on this in the next section). However, for board families -it makes more sense to have a common top-level arch/sh/boards/ directory -and then populate that with sub-directories for each member of the family. -Both the Solution Engine and the hp6xx boards are an example of this. - -After you have setup your new arch/sh/boards/ directory, remember that you -should also add a directory in include/asm-sh for headers localized to this -board (if there are going to be more than one). In order to interoperate -seamlessly with the build system, it's best to have this directory the same -as the arch/sh/boards/ directory name, though if your board is again part of -a family, the build system has ways of dealing with this (via incdir-y -overloading), and you can feel free to name the directory after the family -member itself. - -There are a few things that each board is required to have, both in the -arch/sh/boards and the include/asm-sh/ hierarchy. In order to better -explain this, we use some examples for adding an imaginary board. For -setup code, we're required at the very least to provide definitions for -get_system_type() and platform_setup(). For our imaginary board, this -might look something like:: - - /* - * arch/sh/boards/vapor/setup.c - Setup code for imaginary board - */ - #include - - const char *get_system_type(void) - { - return "FooTech Vaporboard"; - } - - int __init platform_setup(void) - { - /* - * If our hardware actually existed, we would do real - * setup here. Though it's also sane to leave this empty - * if there's no real init work that has to be done for - * this board. - */ - - /* Start-up imaginary PCI ... */ - - /* And whatever else ... */ - - return 0; - } - -Our new imaginary board will also have to tie into the machvec in order for it -to be of any use. - -machvec functions fall into a number of categories: - - - I/O functions to IO memory (inb etc) and PCI/main memory (readb etc). - - I/O mapping functions (ioport_map, ioport_unmap, etc). - - a 'heartbeat' function. - - PCI and IRQ initialization routines. - - Consistent allocators (for boards that need special allocators, - particularly for allocating out of some board-specific SRAM for DMA - handles). - -There are machvec functions added and removed over time, so always be sure to -consult include/asm-sh/machvec.h for the current state of the machvec. - -The kernel will automatically wrap in generic routines for undefined function -pointers in the machvec at boot time, as machvec functions are referenced -unconditionally throughout most of the tree. Some boards have incredibly -sparse machvecs (such as the dreamcast and sh03), whereas others must define -virtually everything (rts7751r2d). - -Adding a new machine is relatively trivial (using vapor as an example): - -If the board-specific definitions are quite minimalistic, as is the case for -the vast majority of boards, simply having a single board-specific header is -sufficient. - - - add a new file include/asm-sh/vapor.h which contains prototypes for - any machine specific IO functions prefixed with the machine name, for - example vapor_inb. These will be needed when filling out the machine - vector. - - Note that these prototypes are generated automatically by setting - __IO_PREFIX to something sensible. A typical example would be:: - - #define __IO_PREFIX vapor - #include - - somewhere in the board-specific header. Any boards being ported that still - have a legacy io.h should remove it entirely and switch to the new model. - - - Add machine vector definitions to the board's setup.c. At a bare minimum, - this must be defined as something like:: - - struct sh_machine_vector mv_vapor __initmv = { - .mv_name = "vapor", - }; - ALIAS_MV(vapor) - - - finally add a file arch/sh/boards/vapor/io.c, which contains definitions of - the machine specific io functions (if there are enough to warrant it). - -3. Hooking into the Build System -================================ - -Now that we have the corresponding directories setup, and all of the -board-specific code is in place, it's time to look at how to get the -whole mess to fit into the build system. - -Large portions of the build system are now entirely dynamic, and merely -require the proper entry here and there in order to get things done. - -The first thing to do is to add an entry to arch/sh/Kconfig, under the -"System type" menu:: - - config SH_VAPOR - bool "Vapor" - help - select Vapor if configuring for a FooTech Vaporboard. - -next, this has to be added into arch/sh/Makefile. All boards require a -machdir-y entry in order to be built. This entry needs to be the name of -the board directory as it appears in arch/sh/boards, even if it is in a -sub-directory (in which case, all parent directories below arch/sh/boards/ -need to be listed). For our new board, this entry can look like:: - - machdir-$(CONFIG_SH_VAPOR) += vapor - -provided that we've placed everything in the arch/sh/boards/vapor/ directory. - -Next, the build system assumes that your include/asm-sh directory will also -be named the same. If this is not the case (as is the case with multiple -boards belonging to a common family), then the directory name needs to be -implicitly appended to incdir-y. The existing code manages this for the -Solution Engine and hp6xx boards, so see these for an example. - -Once that is taken care of, it's time to add an entry for the mach type. -This is done by adding an entry to the end of the arch/sh/tools/mach-types -list. The method for doing this is self explanatory, and so we won't waste -space restating it here. After this is done, you will be able to use -implicit checks for your board if you need this somewhere throughout the -common code, such as:: - - /* Make sure we're on the FooTech Vaporboard */ - if (!mach_is_vapor()) - return -ENODEV; - -also note that the mach_is_boardname() check will be implicitly forced to -lowercase, regardless of the fact that the mach-types entries are all -uppercase. You can read the script if you really care, but it's pretty ugly, -so you probably don't want to do that. - -Now all that's left to do is providing a defconfig for your new board. This -way, other people who end up with this board can simply use this config -for reference instead of trying to guess what settings are supposed to be -used on it. - -Also, as soon as you have copied over a sample .config for your new board -(assume arch/sh/configs/vapor_defconfig), you can also use this directly as a -build target, and it will be implicitly listed as such in the help text. - -Looking at the 'make help' output, you should now see something like: - -Architecture specific targets (sh): - - ======================= ============================================= - zImage Compressed kernel image (arch/sh/boot/zImage) - adx_defconfig Build for adx - cqreek_defconfig Build for cqreek - dreamcast_defconfig Build for dreamcast - ... - vapor_defconfig Build for vapor - ======================= ============================================= - -which then allows you to do:: - - $ make ARCH=sh CROSS_COMPILE=sh4-linux- vapor_defconfig vmlinux - -which will in turn copy the defconfig for this board, run it through -oldconfig (prompting you for any new options since the time of creation), -and start you on your way to having a functional kernel for your new -board. diff --git a/Documentation/sh/register-banks.rst b/Documentation/sh/register-banks.rst deleted file mode 100644 index 2bef5c8fcbbc06..00000000000000 --- a/Documentation/sh/register-banks.rst +++ /dev/null @@ -1,40 +0,0 @@ -.. SPDX-License-Identifier: GPL-2.0 - -========================================== -Notes on register bank usage in the kernel -========================================== - -Introduction ------------- - -The SH-3 and SH-4 CPU families traditionally include a single partial register -bank (selected by SR.RB, only r0 ... r7 are banked), whereas other families -may have more full-featured banking or simply no such capabilities at all. - -SR.RB banking -------------- - -In the case of this type of banking, banked registers are mapped directly to -r0 ... r7 if SR.RB is set to the bank we are interested in, otherwise ldc/stc -can still be used to reference the banked registers (as r0_bank ... r7_bank) -when in the context of another bank. The developer must keep the SR.RB value -in mind when writing code that utilizes these banked registers, for obvious -reasons. Userspace is also not able to poke at the bank1 values, so these can -be used rather effectively as scratch registers by the kernel. - -Presently the kernel uses several of these registers. - - - r0_bank, r1_bank (referenced as k0 and k1, used for scratch - registers when doing exception handling). - - - r2_bank (used to track the EXPEVT/INTEVT code) - - - Used by do_IRQ() and friends for doing irq mapping based off - of the interrupt exception vector jump table offset - - - r6_bank (global interrupt mask) - - - The SR.IMASK interrupt handler makes use of this to set the - interrupt priority level (used by local_irq_enable()) - - - r7_bank (current) diff --git a/MAINTAINERS b/MAINTAINERS index e278cd5d0de00e..5899ff135e3deb 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -20067,16 +20067,6 @@ S: Maintained F: Documentation/devicetree/bindings/watchdog/sunplus,sp7021-wdt.yaml F: drivers/watchdog/sunplus_wdt.c -SUPERH -M: Yoshinori Sato -M: Rich Felker -L: linux-sh@vger.kernel.org -S: Maintained -Q: http://patchwork.kernel.org/project/linux-sh/list/ -F: Documentation/sh/ -F: arch/sh/ -F: drivers/sh/ - SUSPEND TO RAM M: "Rafael J. Wysocki" M: Len Brown diff --git a/arch/sh/Kbuild b/arch/sh/Kbuild deleted file mode 100644 index be171880977e5d..00000000000000 --- a/arch/sh/Kbuild +++ /dev/null @@ -1,7 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -obj-y += kernel/ mm/ boards/ -obj-$(CONFIG_SH_FPU_EMU) += math-emu/ -obj-$(CONFIG_USE_BUILTIN_DTB) += boot/dts/ - -# for cleaning -subdir- += boot diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig deleted file mode 100644 index 0665ac0add0b49..00000000000000 --- a/arch/sh/Kconfig +++ /dev/null @@ -1,793 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -config SUPERH - def_bool y - select ARCH_32BIT_OFF_T - select ARCH_ENABLE_MEMORY_HOTPLUG if SPARSEMEM && MMU - select ARCH_ENABLE_MEMORY_HOTREMOVE if SPARSEMEM && MMU - select ARCH_HAVE_CUSTOM_GPIO_H - select ARCH_HAVE_NMI_SAFE_CMPXCHG if (GUSA_RB || CPU_SH4A) - select ARCH_HAS_BINFMT_FLAT if !MMU - select ARCH_HAS_CURRENT_STACK_POINTER - select ARCH_HAS_GIGANTIC_PAGE - select ARCH_HAS_GCOV_PROFILE_ALL - select ARCH_HAS_PTE_SPECIAL - select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST - select ARCH_HIBERNATION_POSSIBLE if MMU - select ARCH_MIGHT_HAVE_PC_PARPORT - select ARCH_WANT_IPC_PARSE_VERSION - select CPU_NO_EFFICIENT_FFS - select DMA_DECLARE_COHERENT - select GENERIC_ATOMIC64 - select GENERIC_CMOS_UPDATE if SH_SH03 || SH_DREAMCAST - select GENERIC_IDLE_POLL_SETUP - select GENERIC_IRQ_SHOW - select GENERIC_PCI_IOMAP if PCI - select GENERIC_SCHED_CLOCK - select GENERIC_SMP_IDLE_THREAD - select GUP_GET_PXX_LOW_HIGH if X2TLB - select HAVE_ARCH_AUDITSYSCALL - select HAVE_ARCH_KGDB - select HAVE_ARCH_SECCOMP_FILTER - select HAVE_ARCH_TRACEHOOK - select HAVE_DEBUG_BUGVERBOSE - select HAVE_DEBUG_KMEMLEAK - select HAVE_DYNAMIC_FTRACE - select HAVE_FAST_GUP if MMU - select HAVE_FUNCTION_GRAPH_TRACER - select HAVE_FUNCTION_TRACER - select HAVE_FTRACE_MCOUNT_RECORD - select HAVE_HW_BREAKPOINT - select HAVE_IOREMAP_PROT if MMU && !X2TLB - select HAVE_KERNEL_BZIP2 - select HAVE_KERNEL_GZIP - select HAVE_KERNEL_LZMA - select HAVE_KERNEL_LZO - select HAVE_KERNEL_XZ - select HAVE_KPROBES - select HAVE_KRETPROBES - select HAVE_MIXED_BREAKPOINTS_REGS - select HAVE_MOD_ARCH_SPECIFIC if DWARF_UNWINDER - select HAVE_NMI - select HAVE_PATA_PLATFORM - select HAVE_PERF_EVENTS - select HAVE_REGS_AND_STACK_ACCESS_API - select HAVE_UID16 - select HAVE_SOFTIRQ_ON_OWN_STACK if IRQSTACKS - select HAVE_STACKPROTECTOR - select HAVE_SYSCALL_TRACEPOINTS - select IRQ_FORCED_THREADING - select MODULES_USE_ELF_RELA - select NEED_SG_DMA_LENGTH - select NO_DMA if !MMU && !DMA_COHERENT - select NO_GENERIC_PCI_IOPORT_MAP if PCI - select OLD_SIGACTION - select OLD_SIGSUSPEND - select PCI_DOMAINS if PCI - select PERF_EVENTS - select PERF_USE_VMALLOC - select RTC_LIB - select SPARSE_IRQ - select TRACE_IRQFLAGS_SUPPORT - help - The SuperH is a RISC processor targeted for use in embedded systems - and consumer electronics; it was also used in the Sega Dreamcast - gaming console. The SuperH port has a home page at - . - -config GENERIC_BUG - def_bool y - depends on BUG - -config GENERIC_HWEIGHT - def_bool y - -config GENERIC_CALIBRATE_DELAY - bool - -config GENERIC_LOCKBREAK - def_bool y - depends on SMP && PREEMPTION - -config ARCH_SUSPEND_POSSIBLE - def_bool n - -config ARCH_HIBERNATION_POSSIBLE - def_bool n - -config SYS_SUPPORTS_APM_EMULATION - bool - select ARCH_SUSPEND_POSSIBLE - -config SYS_SUPPORTS_SMP - bool - -config SYS_SUPPORTS_NUMA - bool - -config STACKTRACE_SUPPORT - def_bool y - -config LOCKDEP_SUPPORT - def_bool y - -config ARCH_HAS_ILOG2_U32 - def_bool n - -config ARCH_HAS_ILOG2_U64 - def_bool n - -config NO_IOPORT_MAP - def_bool !PCI - depends on !SH_SH4202_MICRODEV && !SH_SHMIN && !SH_HP6XX && \ - !SH_SOLUTION_ENGINE - -config IO_TRAPPED - bool - -config SWAP_IO_SPACE - bool - -config DMA_COHERENT - bool - -config DMA_NONCOHERENT - def_bool !NO_DMA && !DMA_COHERENT - select ARCH_HAS_DMA_PREP_COHERENT - select ARCH_HAS_SYNC_DMA_FOR_DEVICE - select DMA_DIRECT_REMAP - -config PGTABLE_LEVELS - default 3 if X2TLB - default 2 - -menu "System type" - -# -# Processor families -# -config CPU_SH2 - bool - select SH_INTC - -config CPU_SH2A - bool - select CPU_SH2 - select UNCACHED_MAPPING - -config CPU_J2 - bool - select CPU_SH2 - select OF - select OF_EARLY_FLATTREE - -config CPU_SH3 - bool - select CPU_HAS_INTEVT - select CPU_HAS_SR_RB - select SH_INTC - select SYS_SUPPORTS_SH_TMU - -config CPU_SH4 - bool - select ARCH_SUPPORTS_HUGETLBFS if MMU - select CPU_HAS_INTEVT - select CPU_HAS_SR_RB - select CPU_HAS_FPU if !CPU_SH4AL_DSP - select SH_INTC - select SYS_SUPPORTS_SH_TMU - -config CPU_SH4A - bool - select CPU_SH4 - -config CPU_SH4AL_DSP - bool - select CPU_SH4A - select CPU_HAS_DSP - -config CPU_SHX2 - bool - -config CPU_SHX3 - bool - select DMA_COHERENT - select SYS_SUPPORTS_SMP - select SYS_SUPPORTS_NUMA - -config ARCH_SHMOBILE - bool - select ARCH_SUSPEND_POSSIBLE - select PM - -config CPU_HAS_PMU - depends on CPU_SH4 || CPU_SH4A - default y - bool - -choice - prompt "Processor sub-type selection" - -# -# Processor subtypes -# - -# SH-2 Processor Support - -config CPU_SUBTYPE_SH7619 - bool "Support SH7619 processor" - select CPU_SH2 - select SYS_SUPPORTS_SH_CMT - -config CPU_SUBTYPE_J2 - bool "Support J2 processor" - select CPU_J2 - select SYS_SUPPORTS_SMP - select GENERIC_CLOCKEVENTS_BROADCAST if SMP - -# SH-2A Processor Support - -config CPU_SUBTYPE_SH7201 - bool "Support SH7201 processor" - select CPU_SH2A - select CPU_HAS_FPU - select SYS_SUPPORTS_SH_MTU2 - -config CPU_SUBTYPE_SH7203 - bool "Support SH7203 processor" - select CPU_SH2A - select CPU_HAS_FPU - select SYS_SUPPORTS_SH_CMT - select SYS_SUPPORTS_SH_MTU2 - select PINCTRL - -config CPU_SUBTYPE_SH7206 - bool "Support SH7206 processor" - select CPU_SH2A - select SYS_SUPPORTS_SH_CMT - select SYS_SUPPORTS_SH_MTU2 - -config CPU_SUBTYPE_SH7263 - bool "Support SH7263 processor" - select CPU_SH2A - select CPU_HAS_FPU - select SYS_SUPPORTS_SH_CMT - select SYS_SUPPORTS_SH_MTU2 - -config CPU_SUBTYPE_SH7264 - bool "Support SH7264 processor" - select CPU_SH2A - select CPU_HAS_FPU - select SYS_SUPPORTS_SH_CMT - select SYS_SUPPORTS_SH_MTU2 - select PINCTRL - -config CPU_SUBTYPE_SH7269 - bool "Support SH7269 processor" - select CPU_SH2A - select CPU_HAS_FPU - select SYS_SUPPORTS_SH_CMT - select SYS_SUPPORTS_SH_MTU2 - select PINCTRL - -config CPU_SUBTYPE_MXG - bool "Support MX-G processor" - select CPU_SH2A - select SYS_SUPPORTS_SH_MTU2 - help - Select MX-G if running on an R8A03022BG part. - -# SH-3 Processor Support - -config CPU_SUBTYPE_SH7705 - bool "Support SH7705 processor" - select CPU_SH3 - -config CPU_SUBTYPE_SH7706 - bool "Support SH7706 processor" - select CPU_SH3 - help - Select SH7706 if you have a 133 Mhz SH-3 HD6417706 CPU. - -config CPU_SUBTYPE_SH7707 - bool "Support SH7707 processor" - select CPU_SH3 - help - Select SH7707 if you have a 60 Mhz SH-3 HD6417707 CPU. - -config CPU_SUBTYPE_SH7708 - bool "Support SH7708 processor" - select CPU_SH3 - help - Select SH7708 if you have a 60 Mhz SH-3 HD6417708S or - if you have a 100 Mhz SH-3 HD6417708R CPU. - -config CPU_SUBTYPE_SH7709 - bool "Support SH7709 processor" - select CPU_SH3 - help - Select SH7709 if you have a 80 Mhz SH-3 HD6417709 CPU. - -config CPU_SUBTYPE_SH7710 - bool "Support SH7710 processor" - select CPU_SH3 - select CPU_HAS_DSP - help - Select SH7710 if you have a SH3-DSP SH7710 CPU. - -config CPU_SUBTYPE_SH7712 - bool "Support SH7712 processor" - select CPU_SH3 - select CPU_HAS_DSP - help - Select SH7712 if you have a SH3-DSP SH7712 CPU. - -config CPU_SUBTYPE_SH7720 - bool "Support SH7720 processor" - select CPU_SH3 - select CPU_HAS_DSP - select SYS_SUPPORTS_SH_CMT - select USB_OHCI_SH if USB_OHCI_HCD - select PINCTRL - help - Select SH7720 if you have a SH3-DSP SH7720 CPU. - -config CPU_SUBTYPE_SH7721 - bool "Support SH7721 processor" - select CPU_SH3 - select CPU_HAS_DSP - select SYS_SUPPORTS_SH_CMT - select USB_OHCI_SH if USB_OHCI_HCD - help - Select SH7721 if you have a SH3-DSP SH7721 CPU. - -# SH-4 Processor Support - -config CPU_SUBTYPE_SH7750 - bool "Support SH7750 processor" - select CPU_SH4 - help - Select SH7750 if you have a 200 Mhz SH-4 HD6417750 CPU. - -config CPU_SUBTYPE_SH7091 - bool "Support SH7091 processor" - select CPU_SH4 - help - Select SH7091 if you have an SH-4 based Sega device (such as - the Dreamcast, Naomi, and Naomi 2). - -config CPU_SUBTYPE_SH7750R - bool "Support SH7750R processor" - select CPU_SH4 - -config CPU_SUBTYPE_SH7750S - bool "Support SH7750S processor" - select CPU_SH4 - -config CPU_SUBTYPE_SH7751 - bool "Support SH7751 processor" - select CPU_SH4 - help - Select SH7751 if you have a 166 Mhz SH-4 HD6417751 CPU, - or if you have a HD6417751R CPU. - -config CPU_SUBTYPE_SH7751R - bool "Support SH7751R processor" - select CPU_SH4 - -config CPU_SUBTYPE_SH7760 - bool "Support SH7760 processor" - select CPU_SH4 - -config CPU_SUBTYPE_SH4_202 - bool "Support SH4-202 processor" - select CPU_SH4 - -# SH-4A Processor Support - -config CPU_SUBTYPE_SH7723 - bool "Support SH7723 processor" - select CPU_SH4A - select CPU_SHX2 - select ARCH_SHMOBILE - select ARCH_SPARSEMEM_ENABLE - select SYS_SUPPORTS_SH_CMT - select PINCTRL - help - Select SH7723 if you have an SH-MobileR2 CPU. - -config CPU_SUBTYPE_SH7724 - bool "Support SH7724 processor" - select CPU_SH4A - select CPU_SHX2 - select ARCH_SHMOBILE - select ARCH_SPARSEMEM_ENABLE - select SYS_SUPPORTS_SH_CMT - select PINCTRL - help - Select SH7724 if you have an SH-MobileR2R CPU. - -config CPU_SUBTYPE_SH7734 - bool "Support SH7734 processor" - select CPU_SH4A - select CPU_SHX2 - select PINCTRL - help - Select SH7734 if you have a SH4A SH7734 CPU. - -config CPU_SUBTYPE_SH7757 - bool "Support SH7757 processor" - select CPU_SH4A - select CPU_SHX2 - select PINCTRL - help - Select SH7757 if you have a SH4A SH7757 CPU. - -config CPU_SUBTYPE_SH7763 - bool "Support SH7763 processor" - select CPU_SH4A - select USB_OHCI_SH if USB_OHCI_HCD - help - Select SH7763 if you have a SH4A SH7763(R5S77631) CPU. - -config CPU_SUBTYPE_SH7770 - bool "Support SH7770 processor" - select CPU_SH4A - -config CPU_SUBTYPE_SH7780 - bool "Support SH7780 processor" - select CPU_SH4A - -config CPU_SUBTYPE_SH7785 - bool "Support SH7785 processor" - select CPU_SH4A - select CPU_SHX2 - select ARCH_SPARSEMEM_ENABLE - select SYS_SUPPORTS_NUMA - select PINCTRL - -config CPU_SUBTYPE_SH7786 - bool "Support SH7786 processor" - select CPU_SH4A - select CPU_SHX3 - select CPU_HAS_PTEAEX - select GENERIC_CLOCKEVENTS_BROADCAST if SMP - select USB_OHCI_SH if USB_OHCI_HCD - select USB_EHCI_SH if USB_EHCI_HCD - select PINCTRL - -config CPU_SUBTYPE_SHX3 - bool "Support SH-X3 processor" - select CPU_SH4A - select CPU_SHX3 - select GENERIC_CLOCKEVENTS_BROADCAST if SMP - select GPIOLIB - select PINCTRL - -# SH4AL-DSP Processor Support - -config CPU_SUBTYPE_SH7343 - bool "Support SH7343 processor" - select CPU_SH4AL_DSP - select ARCH_SHMOBILE - select SYS_SUPPORTS_SH_CMT - -config CPU_SUBTYPE_SH7722 - bool "Support SH7722 processor" - select CPU_SH4AL_DSP - select CPU_SHX2 - select ARCH_SHMOBILE - select ARCH_SPARSEMEM_ENABLE - select SYS_SUPPORTS_NUMA - select SYS_SUPPORTS_SH_CMT - select PINCTRL - -config CPU_SUBTYPE_SH7366 - bool "Support SH7366 processor" - select CPU_SH4AL_DSP - select CPU_SHX2 - select ARCH_SHMOBILE - select ARCH_SPARSEMEM_ENABLE - select SYS_SUPPORTS_NUMA - select SYS_SUPPORTS_SH_CMT - -endchoice - -source "arch/sh/mm/Kconfig" - -source "arch/sh/Kconfig.cpu" - -source "arch/sh/boards/Kconfig" - -menu "Timer and clock configuration" - -config SH_PCLK_FREQ - int "Peripheral clock frequency (in Hz)" - depends on SH_CLK_CPG_LEGACY - default "31250000" if CPU_SUBTYPE_SH7619 - default "33333333" if CPU_SUBTYPE_SH7770 || \ - CPU_SUBTYPE_SH7760 || \ - CPU_SUBTYPE_SH7705 || \ - CPU_SUBTYPE_SH7203 || \ - CPU_SUBTYPE_SH7206 || \ - CPU_SUBTYPE_SH7263 || \ - CPU_SUBTYPE_MXG - default "60000000" if CPU_SUBTYPE_SH7751 || CPU_SUBTYPE_SH7751R - default "66000000" if CPU_SUBTYPE_SH4_202 - default "50000000" - help - This option is used to specify the peripheral clock frequency. - This is necessary for determining the reference clock value on - platforms lacking an RTC. - -config SH_CLK_CPG - def_bool y - -config SH_CLK_CPG_LEGACY - depends on SH_CLK_CPG - def_bool y if !CPU_SUBTYPE_SH7785 && !ARCH_SHMOBILE && \ - !CPU_SHX3 && !CPU_SUBTYPE_SH7757 && \ - !CPU_SUBTYPE_SH7734 && !CPU_SUBTYPE_SH7264 && \ - !CPU_SUBTYPE_SH7269 - -endmenu - -menu "CPU Frequency scaling" -source "drivers/cpufreq/Kconfig" -endmenu - -source "arch/sh/drivers/Kconfig" - -endmenu - -menu "Kernel features" - -source "kernel/Kconfig.hz" - -config KEXEC - bool "kexec system call (EXPERIMENTAL)" - depends on MMU - select KEXEC_CORE - help - kexec is a system call that implements the ability to shutdown your - current kernel, and to start another kernel. It is like a reboot - but it is independent of the system firmware. And like a reboot - you can start any kernel with it, not just Linux. - - The name comes from the similarity to the exec system call. - - It is an ongoing process to be certain the hardware in a machine - is properly shutdown, so do not be surprised if this code does not - initially work for you. As of this writing the exact hardware - interface is strongly in flux, so no good recommendation can be - made. - -config CRASH_DUMP - bool "kernel crash dumps (EXPERIMENTAL)" - depends on BROKEN_ON_SMP - help - Generate crash dump after being started by kexec. - This should be normally only set in special crash dump kernels - which are loaded in the main kernel with kexec-tools into - a specially reserved region and then later executed after - a crash by kdump/kexec. The crash dump kernel must be compiled - to a memory address not used by the main kernel using - PHYSICAL_START. - - For more details see Documentation/admin-guide/kdump/kdump.rst - -config KEXEC_JUMP - bool "kexec jump (EXPERIMENTAL)" - depends on KEXEC && HIBERNATION - help - Jump between original kernel and kexeced kernel and invoke - code via KEXEC - -config PHYSICAL_START - hex "Physical address where the kernel is loaded" if (EXPERT || CRASH_DUMP) - default MEMORY_START - help - This gives the physical address where the kernel is loaded - and is ordinarily the same as MEMORY_START. - - Different values are primarily used in the case of kexec on panic - where the fail safe kernel needs to run at a different address - than the panic-ed kernel. - -config SMP - bool "Symmetric multi-processing support" - depends on SYS_SUPPORTS_SMP - help - This enables support for systems with more than one CPU. If you have - a system with only one CPU, say N. If you have a system with more - than one CPU, say Y. - - If you say N here, the kernel will run on uni- and multiprocessor - machines, but will use only one CPU of a multiprocessor machine. If - you say Y here, the kernel will run on many, but not all, - uniprocessor machines. On a uniprocessor machine, the kernel - will run faster if you say N here. - - People using multiprocessor machines who say Y here should also say - Y to "Enhanced Real Time Clock Support", below. - - See also and the SMP-HOWTO - available at . - - If you don't know what to do here, say N. - -config NR_CPUS - int "Maximum number of CPUs (2-32)" - range 2 32 - depends on SMP - default "4" if CPU_SUBTYPE_SHX3 - default "2" - help - This allows you to specify the maximum number of CPUs which this - kernel will support. The maximum supported value is 32 and the - minimum value which makes sense is 2. - - This is purely to save memory - each supported CPU adds - approximately eight kilobytes to the kernel image. - -config HOTPLUG_CPU - bool "Support for hot-pluggable CPUs (EXPERIMENTAL)" - depends on SMP - help - Say Y here to experiment with turning CPUs off and on. CPUs - can be controlled through /sys/devices/system/cpu. - -config GUSA - def_bool y - depends on !SMP - help - This enables support for gUSA (general UserSpace Atomicity). - This is the default implementation for both UP and non-ll/sc - CPUs, and is used by the libc, amongst others. - - For additional information, design information can be found - in . - - This should only be disabled for special cases where alternate - atomicity implementations exist. - -config GUSA_RB - bool "Implement atomic operations by roll-back (gRB) (EXPERIMENTAL)" - depends on GUSA && CPU_SH3 || (CPU_SH4 && !CPU_SH4A) - help - Enabling this option will allow the kernel to implement some - atomic operations using a software implementation of load-locked/ - store-conditional (LLSC). On machines which do not have hardware - LLSC, this should be more efficient than the other alternative of - disabling interrupts around the atomic sequence. - -config HW_PERF_EVENTS - bool "Enable hardware performance counter support for perf events" - depends on PERF_EVENTS && CPU_HAS_PMU - default y - help - Enable hardware performance counter support for perf events. If - disabled, perf events will use software events only. - -source "drivers/sh/Kconfig" - -endmenu - -menu "Boot options" - -config USE_BUILTIN_DTB - bool "Use builtin DTB" - default n - depends on SH_DEVICE_TREE - help - Link a device tree blob for particular hardware into the kernel, - suppressing use of the DTB pointer provided by the bootloader. - This option should only be used with legacy bootloaders that are - not capable of providing a DTB to the kernel, or for experimental - hardware without stable device tree bindings. - -config BUILTIN_DTB_SOURCE - string "Source file for builtin DTB" - default "" - depends on USE_BUILTIN_DTB - help - Base name (without suffix, relative to arch/sh/boot/dts) for the - a DTS file that will be used to produce the DTB linked into the - kernel. - -config ZERO_PAGE_OFFSET - hex - default "0x00010000" if PAGE_SIZE_64KB || SH_RTS7751R2D || \ - SH_7751_SOLUTION_ENGINE - default "0x00004000" if PAGE_SIZE_16KB || SH_SH03 - default "0x00002000" if PAGE_SIZE_8KB - default "0x00001000" - help - This sets the default offset of zero page. - -config BOOT_LINK_OFFSET - hex - default "0x00210000" if SH_SHMIN - default "0x00810000" if SH_7780_SOLUTION_ENGINE - default "0x009e0000" if SH_TITAN - default "0x01800000" if SH_SDK7780 - default "0x02000000" if SH_EDOSK7760 - default "0x00800000" - help - This option allows you to set the link address offset of the zImage. - This can be useful if you are on a board which has a small amount of - memory. - -config ENTRY_OFFSET - hex - default "0x00001000" if PAGE_SIZE_4KB - default "0x00002000" if PAGE_SIZE_8KB - default "0x00004000" if PAGE_SIZE_16KB - default "0x00010000" if PAGE_SIZE_64KB - default "0x00000000" - -config ROMIMAGE_MMCIF - bool "Include MMCIF loader in romImage (EXPERIMENTAL)" - depends on CPU_SUBTYPE_SH7724 - help - Say Y here to include experimental MMCIF loading code in - romImage. With this enabled it is possible to write the romImage - kernel image to an MMC card and boot the kernel straight from - the reset vector. At reset the processor Mask ROM will load the - first part of the romImage which in turn loads the rest the kernel - image to RAM using the MMCIF hardware block. - -choice - prompt "Kernel command line" - optional - default CMDLINE_OVERWRITE - help - Setting this option allows the kernel command line arguments - to be set. - -config CMDLINE_OVERWRITE - bool "Overwrite bootloader kernel arguments" - help - Given string will overwrite any arguments passed in by - a bootloader. - -config CMDLINE_EXTEND - bool "Extend bootloader kernel arguments" - help - Given string will be concatenated with arguments passed in - by a bootloader. - -endchoice - -config CMDLINE - string "Kernel command line arguments string" - depends on CMDLINE_OVERWRITE || CMDLINE_EXTEND - default "console=ttySC1,115200" - -endmenu - -menu "Bus options" - -config SUPERHYWAY - tristate "SuperHyway Bus support" - depends on CPU_SUBTYPE_SH4_202 - -config MAPLE - bool "Maple Bus support" - depends on SH_DREAMCAST - help - The Maple Bus is SEGA's serial communication bus for peripherals - on the Dreamcast. Without this bus support you won't be able to - get your Dreamcast keyboard etc to work, so most users - probably want to say 'Y' here, unless you are only using the - Dreamcast with a serial line terminal or a remote network - connection. - -endmenu - -menu "Power management options (EXPERIMENTAL)" - -source "kernel/power/Kconfig" - -source "drivers/cpuidle/Kconfig" - -endmenu diff --git a/arch/sh/Kconfig.cpu b/arch/sh/Kconfig.cpu deleted file mode 100644 index fff419f3d7574c..00000000000000 --- a/arch/sh/Kconfig.cpu +++ /dev/null @@ -1,100 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -menu "Processor features" - -choice - prompt "Endianness selection" - default CPU_LITTLE_ENDIAN - help - Some SuperH machines can be configured for either little or big - endian byte order. These modes require different kernels. - -config CPU_LITTLE_ENDIAN - bool "Little Endian" - -config CPU_BIG_ENDIAN - bool "Big Endian" - -endchoice - -config SH_FPU - def_bool y - prompt "FPU support" - depends on CPU_HAS_FPU - help - Selecting this option will enable support for SH processors that - have FPU units (ie, SH77xx). - - This option must be set in order to enable the FPU. - -config SH_FPU_EMU - def_bool n - prompt "FPU emulation support" - depends on !SH_FPU - help - Selecting this option will enable support for software FPU emulation. - Most SH-3 users will want to say Y here, whereas most SH-4 users will - want to say N. - -config SH_DSP - def_bool y - prompt "DSP support" - depends on CPU_HAS_DSP - help - Selecting this option will enable support for SH processors that - have DSP units (ie, SH2-DSP, SH3-DSP, and SH4AL-DSP). - - This option must be set in order to enable the DSP. - -config SH_ADC - def_bool y - prompt "ADC support" - depends on CPU_SH3 - help - Selecting this option will allow the Linux kernel to use SH3 on-chip - ADC module. - - If unsure, say N. - -config SH_STORE_QUEUES - bool "Support for Store Queues" - depends on CPU_SH4 - help - Selecting this option will enable an in-kernel API for manipulating - the store queues integrated in the SH-4 processors. - -config SPECULATIVE_EXECUTION - bool "Speculative subroutine return" - depends on CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785 || CPU_SUBTYPE_SH7786 - help - This enables support for a speculative instruction fetch for - subroutine return. There are various pitfalls associated with - this, as outlined in the SH7780 hardware manual. - - If unsure, say N. - -config CPU_HAS_INTEVT - bool - -config CPU_HAS_IPR_IRQ - bool - -config CPU_HAS_SR_RB - bool - help - This will enable the use of SR.RB register bank usage. Processors - that are lacking this bit must have another method in place for - accomplishing what is taken care of by the banked registers. - - See for further - information on SR.RB and register banking in the kernel in general. - -config CPU_HAS_PTEAEX - bool - -config CPU_HAS_DSP - bool - -config CPU_HAS_FPU - bool - -endmenu diff --git a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug deleted file mode 100644 index 10290e5c1f4387..00000000000000 --- a/arch/sh/Kconfig.debug +++ /dev/null @@ -1,78 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 - -config SH_STANDARD_BIOS - bool "Use LinuxSH standard BIOS" - help - Say Y here if your target has the gdb-sh-stub - package from www.m17n.org (or any conforming standard LinuxSH BIOS) - in FLASH or EPROM. The kernel will use standard BIOS calls during - boot for various housekeeping tasks (including calls to read and - write characters to a system console, get a MAC address from an - on-board Ethernet interface, and shut down the hardware). Note this - does not work with machines with an existing operating system in - mask ROM and no flash (WindowsCE machines fall in this category). - If unsure, say N. - -config STACK_DEBUG - bool "Check for stack overflows" - depends on DEBUG_KERNEL - help - This option will cause messages to be printed if free stack space - drops below a certain limit. Saying Y here will add overhead to - every function call and will therefore incur a major - performance hit. Most users should say N. - -config 4KSTACKS - bool "Use 4Kb for kernel stacks instead of 8Kb" - depends on DEBUG_KERNEL && (MMU || BROKEN) && !PAGE_SIZE_64KB - help - If you say Y here the kernel will use a 4Kb stacksize for the - kernel stack attached to each process/thread. This facilitates - running more threads on a system and also reduces the pressure - on the VM subsystem for higher order allocations. This option - will also use IRQ stacks to compensate for the reduced stackspace. - -config IRQSTACKS - bool "Use separate kernel stacks when processing interrupts" - depends on DEBUG_KERNEL && BROKEN - help - If you say Y here the kernel will use separate kernel stacks - for handling hard and soft interrupts. This can help avoid - overflowing the process kernel stacks. - -config DUMP_CODE - bool "Show disassembly of nearby code in register dumps" - depends on DEBUG_KERNEL - default y if DEBUG_BUGVERBOSE - default n - help - This prints out a code trace of the instructions leading up to - the faulting instruction as a debugging aid. As this does grow - the kernel in size a bit, most users will want to say N here. - - Those looking for more verbose debugging output should say Y. - -config DWARF_UNWINDER - bool "Enable the DWARF unwinder for stacktraces" - depends on DEBUG_KERNEL - select FRAME_POINTER - default n - help - Enabling this option will make stacktraces more accurate, at - the cost of an increase in overall kernel size. - -config SH_NO_BSS_INIT - bool "Avoid zeroing BSS (to speed-up startup on suitable platforms)" - depends on DEBUG_KERNEL - default n - help - If running in painfully slow environments, such as an RTL - simulation or from remote memory via SHdebug, where the memory - can already be guaranteed to ber zeroed on boot, say Y. - - For all other cases, say N. If this option seems perplexing, or - you aren't sure, say N. - -config MCOUNT - def_bool y - depends on STACK_DEBUG || FUNCTION_TRACER diff --git a/arch/sh/Makefile b/arch/sh/Makefile deleted file mode 100644 index 5c8776482530c3..00000000000000 --- a/arch/sh/Makefile +++ /dev/null @@ -1,215 +0,0 @@ -# -# arch/sh/Makefile -# -# Copyright (C) 1999 Kaz Kojima -# Copyright (C) 2002 - 2008 Paul Mundt -# Copyright (C) 2002 M. R. Brown -# -# This file is subject to the terms and conditions of the GNU General Public -# License. See the file "COPYING" in the main directory of this archive -# for more details. -# -ifdef cross_compiling - ifeq ($(CROSS_COMPILE),) - CROSS_COMPILE := $(call cc-cross-prefix, sh-linux- sh-linux-gnu- sh-unknown-linux-gnu-) - endif -endif - -KBUILD_DEFCONFIG := shx3_defconfig - -isa-y := any -isa-$(CONFIG_SH_DSP) := sh -isa-$(CONFIG_CPU_SH2) := sh2 -isa-$(CONFIG_CPU_SH2A) := sh2a -isa-$(CONFIG_CPU_SH3) := sh3 -isa-$(CONFIG_CPU_SH4) := sh4 -isa-$(CONFIG_CPU_SH4A) := sh4a -isa-$(CONFIG_CPU_SH4AL_DSP) := sh4al - -isa-$(CONFIG_SH_DSP) := $(isa-y)-dsp -isa-y := $(isa-y)-up - -cflags-$(CONFIG_CPU_SH2) := $(call cc-option,-m2,) -cflags-$(CONFIG_CPU_J2) += $(call cc-option,-mj2,) -cflags-$(CONFIG_CPU_SH2A) += $(call cc-option,-m2a,) \ - $(call cc-option,-m2a-nofpu,) \ - $(call cc-option,-m4-nofpu,) -cflags-$(CONFIG_CPU_SH3) := $(call cc-option,-m3,) -cflags-$(CONFIG_CPU_SH4) := $(call cc-option,-m4,) \ - $(call cc-option,-mno-implicit-fp,-m4-nofpu) -cflags-$(CONFIG_CPU_SH4A) += $(call cc-option,-m4a,) \ - $(call cc-option,-m4a-nofpu,) -cflags-$(CONFIG_CPU_SH4AL_DSP) += $(call cc-option,-m4al,) - -ifeq ($(cflags-y),) -# -# In the case where we are stuck with a compiler that has been uselessly -# restricted to a particular ISA, a favourite default of newer GCCs when -# extensive multilib targets are not provided, ensure we get the best fit -# regarding FP generation. This is intentionally stupid (albeit many -# orders of magnitude less than GCC's default behaviour), as anything -# with a large number of multilib targets better have been built -# correctly for the target in mind. -# -cflags-y += $(shell $(CC) $(KBUILD_CFLAGS) -print-multi-lib | \ - grep nofpu | sed q | sed -e 's/^/-/;s/;.*$$//') -# At this point, anything goes. -isaflags-y := $(call as-option,-Wa$(comma)-isa=any,) -else -# -# -Wa,-isa= tuning implies -Wa,-dsp for the versions of binutils that -# support it, while -Wa,-dsp by itself limits the range of usable opcodes -# on certain CPU subtypes. Try the ISA variant first, and if that fails, -# fall back on -Wa,-dsp for the old binutils versions. Even without DSP -# opcodes, we always want the best ISA tuning the version of binutils -# will provide. -# -isaflags-y := $(call as-option,-Wa$(comma)-isa=$(isa-y),) - -isaflags-$(CONFIG_SH_DSP) := \ - $(call as-option,-Wa$(comma)-isa=$(isa-y),-Wa$(comma)-dsp) -endif - -cflags-$(CONFIG_CPU_BIG_ENDIAN) += -mb -cflags-$(CONFIG_CPU_LITTLE_ENDIAN) += -ml - -cflags-y += $(call cc-option,-mno-fdpic) -cflags-y += $(isaflags-y) -ffreestanding - -OBJCOPYFLAGS := -O binary -R .note -R .note.gnu.build-id -R .comment \ - -R .stab -R .stabstr -S - -# Give the various platforms the opportunity to set default image types -defaultimage-y := zImage -defaultimage-$(CONFIG_SH_SH7785LCR) := uImage -defaultimage-$(CONFIG_SH_RSK) := uImage -defaultimage-$(CONFIG_SH_URQUELL) := uImage -defaultimage-$(CONFIG_SH_MIGOR) := uImage -defaultimage-$(CONFIG_SH_AP325RXA) := uImage -defaultimage-$(CONFIG_SH_SH7757LCR) := uImage -defaultimage-$(CONFIG_SH_7724_SOLUTION_ENGINE) := uImage -defaultimage-$(CONFIG_SH_7206_SOLUTION_ENGINE) := vmlinux -defaultimage-$(CONFIG_SH_7619_SOLUTION_ENGINE) := vmlinux - -# Set some sensible Kbuild defaults -boot := arch/sh/boot -KBUILD_IMAGE := $(boot)/$(defaultimage-y) - -# -# Choosing incompatible machines durings configuration will result in -# error messages during linking. -# -UTS_MACHINE := sh -LDFLAGS_vmlinux += -e _stext - -ifdef CONFIG_CPU_LITTLE_ENDIAN -ld-bfd := elf32-sh-linux -LDFLAGS_vmlinux += --defsym jiffies=jiffies_64 --oformat $(ld-bfd) -KBUILD_LDFLAGS += -EL -else -ld-bfd := elf32-shbig-linux -LDFLAGS_vmlinux += --defsym jiffies=jiffies_64+4 --oformat $(ld-bfd) -KBUILD_LDFLAGS += -EB -endif - -export ld-bfd - -# Mach groups -machdir-$(CONFIG_SOLUTION_ENGINE) += mach-se -machdir-$(CONFIG_SH_HP6XX) += mach-hp6xx -machdir-$(CONFIG_SH_DREAMCAST) += mach-dreamcast -machdir-$(CONFIG_SH_SH03) += mach-sh03 -machdir-$(CONFIG_SH_RTS7751R2D) += mach-r2d -machdir-$(CONFIG_SH_HIGHLANDER) += mach-highlander -machdir-$(CONFIG_SH_MIGOR) += mach-migor -machdir-$(CONFIG_SH_AP325RXA) += mach-ap325rxa -machdir-$(CONFIG_SH_KFR2R09) += mach-kfr2r09 -machdir-$(CONFIG_SH_ECOVEC) += mach-ecovec24 -machdir-$(CONFIG_SH_SDK7780) += mach-sdk7780 -machdir-$(CONFIG_SH_SDK7786) += mach-sdk7786 -machdir-$(CONFIG_SH_X3PROTO) += mach-x3proto -machdir-$(CONFIG_SH_SH7763RDP) += mach-sh7763rdp -machdir-$(CONFIG_SH_SH4202_MICRODEV) += mach-microdev -machdir-$(CONFIG_SH_LANDISK) += mach-landisk -machdir-$(CONFIG_SH_LBOX_RE2) += mach-lboxre2 -machdir-$(CONFIG_SH_RSK) += mach-rsk - -ifneq ($(machdir-y),) -core-y += $(addprefix arch/sh/boards/, \ - $(filter-out ., $(patsubst %,%/,$(machdir-y)))) -endif - -# Common machine type headers. Not part of the arch/sh/boards/ hierarchy. -machdir-y += mach-common - -# Companion chips -core-$(CONFIG_HD6446X_SERIES) += arch/sh/cchips/hd6446x/ - -# -# CPU header paths -# -# These are ordered by optimization level. A CPU family that is a subset -# of another (ie, SH-2A / SH-2), is picked up first, with increasing -# levels of genericness if nothing more suitable is situated in the -# hierarchy. -# -# As an example, in order of preference, SH-2A > SH-2 > common definitions. -# -cpuincdir-$(CONFIG_CPU_SH2A) += cpu-sh2a -cpuincdir-$(CONFIG_CPU_SH2) += cpu-sh2 -cpuincdir-$(CONFIG_CPU_SH3) += cpu-sh3 -cpuincdir-$(CONFIG_CPU_SH4A) += cpu-sh4a -cpuincdir-$(CONFIG_CPU_SH4) += cpu-sh4 -cpuincdir-y += cpu-common # Must be last - -drivers-y += arch/sh/drivers/ - -cflags-y += $(foreach d, $(cpuincdir-y), -I $(srctree)/arch/sh/include/$(d)) \ - $(foreach d, $(machdir-y), -I $(srctree)/arch/sh/include/$(d)) - -KBUILD_CFLAGS += -pipe $(cflags-y) -KBUILD_CPPFLAGS += $(cflags-y) -KBUILD_AFLAGS += $(cflags-y) - -ifeq ($(CONFIG_MCOUNT),y) - KBUILD_CFLAGS += -pg -endif - -ifeq ($(CONFIG_DWARF_UNWINDER),y) - KBUILD_CFLAGS += -fasynchronous-unwind-tables -endif - -libs-y := arch/sh/lib/ $(libs-y) - -BOOT_TARGETS = uImage uImage.bz2 uImage.gz uImage.lzma uImage.xz uImage.lzo \ - uImage.srec uImage.bin zImage vmlinux.bin vmlinux.srec \ - romImage -PHONY += $(BOOT_TARGETS) - -all: $(notdir $(KBUILD_IMAGE)) - -$(BOOT_TARGETS): vmlinux - $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ - -compressed: zImage - -archprepare: - $(Q)$(MAKE) $(build)=arch/sh/tools include/generated/machtypes.h - -archheaders: - $(Q)$(MAKE) $(build)=arch/sh/kernel/syscalls all - -define archhelp - @echo ' zImage - Compressed kernel image' - @echo ' romImage - Compressed ROM image, if supported' - @echo ' vmlinux.srec - Create an ELF S-record' - @echo ' vmlinux.bin - Create an uncompressed binary image' - @echo '* uImage - Alias to bootable U-Boot image' - @echo ' uImage.srec - Create an S-record for U-Boot' - @echo ' uImage.bin - Kernel-only image for U-Boot (bin)' - @echo '* uImage.gz - Kernel-only image for U-Boot (gzip)' - @echo ' uImage.bz2 - Kernel-only image for U-Boot (bzip2)' - @echo ' uImage.lzma - Kernel-only image for U-Boot (lzma)' - @echo ' uImage.xz - Kernel-only image for U-Boot (xz)' - @echo ' uImage.lzo - Kernel-only image for U-Boot (lzo)' -endef diff --git a/arch/sh/boards/Kconfig b/arch/sh/boards/Kconfig deleted file mode 100644 index 83bcb6d2dacadd..00000000000000 --- a/arch/sh/boards/Kconfig +++ /dev/null @@ -1,400 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -menu "Board support" - -config SOLUTION_ENGINE - bool - -config SH_ALPHA_BOARD - bool - -config SH_CUSTOM_CLK - def_bool y - depends on !SH_DEVICE_TREE - select HAVE_LEGACY_CLK - -config SH_DEVICE_TREE - bool - select OF - select OF_EARLY_FLATTREE - select TIMER_OF - select COMMON_CLK - select GENERIC_CALIBRATE_DELAY - -config SH_JCORE_SOC - bool "J-Core SoC" - select SH_DEVICE_TREE - select CLKSRC_JCORE_PIT - select JCORE_AIC - depends on CPU_J2 - help - Select this option to include drivers core components of the - J-Core SoC, including interrupt controllers and timers. - -config SH_SOLUTION_ENGINE - bool "SolutionEngine" - select SOLUTION_ENGINE - select CPU_HAS_IPR_IRQ - depends on CPU_SUBTYPE_SH7705 || CPU_SUBTYPE_SH7709 || CPU_SUBTYPE_SH7710 || \ - CPU_SUBTYPE_SH7712 || CPU_SUBTYPE_SH7750 || CPU_SUBTYPE_SH7750S || \ - CPU_SUBTYPE_SH7750R - help - Select SolutionEngine if configuring for a Hitachi SH7705, SH7709, - SH7710, SH7712, SH7750, SH7750S or SH7750R evaluation board. - -config SH_7206_SOLUTION_ENGINE - bool "SolutionEngine7206" - select SOLUTION_ENGINE - depends on CPU_SUBTYPE_SH7206 - help - Select 7206 SolutionEngine if configuring for a Hitachi SH7206 - evaluation board. - -config SH_7619_SOLUTION_ENGINE - bool "SolutionEngine7619" - select SOLUTION_ENGINE - depends on CPU_SUBTYPE_SH7619 - help - Select 7619 SolutionEngine if configuring for a Hitachi SH7619 - evaluation board. - -config SH_7721_SOLUTION_ENGINE - bool "SolutionEngine7721" - select SOLUTION_ENGINE - depends on CPU_SUBTYPE_SH7721 - help - Select 7721 SolutionEngine if configuring for a Hitachi SH7721 - evaluation board. - -config SH_7722_SOLUTION_ENGINE - bool "SolutionEngine7722" - select SOLUTION_ENGINE - select GENERIC_IRQ_CHIP - select IRQ_DOMAIN - depends on CPU_SUBTYPE_SH7722 - help - Select 7722 SolutionEngine if configuring for a Hitachi SH772 - evaluation board. - -config SH_7724_SOLUTION_ENGINE - bool "SolutionEngine7724" - select SOLUTION_ENGINE - depends on CPU_SUBTYPE_SH7724 - select GPIOLIB - select SND_SOC_AK4642 if SND_SIMPLE_CARD - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Select 7724 SolutionEngine if configuring for a Hitachi SH7724 - evaluation board. - -config SH_7751_SOLUTION_ENGINE - bool "SolutionEngine7751" - select SOLUTION_ENGINE - select CPU_HAS_IPR_IRQ - depends on CPU_SUBTYPE_SH7751 - help - Select 7751 SolutionEngine if configuring for a Hitachi SH7751 - evaluation board. - -config SH_7780_SOLUTION_ENGINE - bool "SolutionEngine7780" - select SOLUTION_ENGINE - select HAVE_PCI - depends on CPU_SUBTYPE_SH7780 - help - Select 7780 SolutionEngine if configuring for a Renesas SH7780 - evaluation board. - -config SH_7343_SOLUTION_ENGINE - bool "SolutionEngine7343" - select SOLUTION_ENGINE - select GENERIC_IRQ_CHIP - select IRQ_DOMAIN - depends on CPU_SUBTYPE_SH7343 - help - Select 7343 SolutionEngine if configuring for a Hitachi - SH7343 (SH-Mobile 3AS) evaluation board. - -config SH_HP6XX - bool "HP6XX" - select SYS_SUPPORTS_APM_EMULATION - select HD6446X_SERIES - depends on CPU_SUBTYPE_SH7709 - help - Select HP6XX if configuring for a HP jornada HP6xx. - More information (hardware only) at - . - -config SH_DREAMCAST - bool "Dreamcast" - select HAVE_PCI - depends on CPU_SUBTYPE_SH7091 - help - Select Dreamcast if configuring for a SEGA Dreamcast. - More information at - -config SH_SH03 - bool "Interface CTP/PCI-SH03" - depends on CPU_SUBTYPE_SH7751 - select CPU_HAS_IPR_IRQ - select HAVE_PCI - help - CTP/PCI-SH03 is a CPU module computer that is produced - by Interface Corporation. - More information at - -config SH_SECUREEDGE5410 - bool "SecureEdge5410" - depends on CPU_SUBTYPE_SH7751R - select CPU_HAS_IPR_IRQ - select HAVE_PCI - help - Select SecureEdge5410 if configuring for a SnapGear SH board. - This includes both the OEM SecureEdge products as well as the - SME product line. - -config SH_RTS7751R2D - bool "RTS7751R2D" - depends on CPU_SUBTYPE_SH7751R - select HAVE_PCI - select IO_TRAPPED if MMU - help - Select RTS7751R2D if configuring for a Renesas Technology - Sales SH-Graphics board. - -config SH_RSK - bool "Renesas Starter Kit" - depends on CPU_SUBTYPE_SH7201 || CPU_SUBTYPE_SH7203 || \ - CPU_SUBTYPE_SH7264 || CPU_SUBTYPE_SH7269 - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Select this option if configuring for any of the RSK+ MCU - evaluation platforms. - -config SH_SDK7780 - bool "SDK7780R3" - depends on CPU_SUBTYPE_SH7780 - select HAVE_PCI - help - Select SDK7780 if configuring for a Renesas SH7780 SDK7780R3 - evaluation board. - -config SH_SDK7786 - bool "SDK7786" - depends on CPU_SUBTYPE_SH7786 - select HAVE_PCI - select NO_IOPORT_MAP if !PCI - select HAVE_SRAM_POOL - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Select SDK7786 if configuring for a Renesas Technology Europe - SH7786-65nm board. - -config SH_HIGHLANDER - bool "Highlander" - depends on CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785 - select HAVE_PCI - select IO_TRAPPED if MMU - -config SH_SH7757LCR - bool "SH7757LCR" - depends on CPU_SUBTYPE_SH7757 - select GPIOLIB - select REGULATOR_FIXED_VOLTAGE if REGULATOR - -config SH_SH7785LCR - bool "SH7785LCR" - depends on CPU_SUBTYPE_SH7785 - select HAVE_PCI - -config SH_SH7785LCR_29BIT_PHYSMAPS - bool "SH7785LCR 29bit physmaps" - depends on SH_SH7785LCR && 29BIT - default y - help - This board has 2 physical memory maps. It can be changed with - DIP switch(S2-5). If you set the DIP switch for S2-5 = ON, - you can access all on-board device in 29bit address mode. - -config SH_SH7785LCR_PT - bool "SH7785LCR prototype board on 32-bit MMU mode" - depends on SH_SH7785LCR && 32BIT - default n - help - If you use prototype board, this option is enabled. - -config SH_URQUELL - bool "Urquell" - depends on CPU_SUBTYPE_SH7786 - select GPIOLIB - select HAVE_PCI - select NO_IOPORT_MAP if !PCI - -config SH_MIGOR - bool "Migo-R" - depends on CPU_SUBTYPE_SH7722 - select GPIOLIB - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Select Migo-R if configuring for the SH7722 Migo-R platform - by Renesas System Solutions Asia Pte. Ltd. - -config SH_AP325RXA - bool "AP-325RXA" - depends on CPU_SUBTYPE_SH7723 - select GPIOLIB - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Renesas "AP-325RXA" support. - Compatible with ALGO SYSTEM CO.,LTD. "AP-320A" - -config SH_KFR2R09 - bool "KFR2R09" - depends on CPU_SUBTYPE_SH7724 - select GPIOLIB - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - "Kit For R2R for 2009" support. - -config SH_ECOVEC - bool "EcoVec" - depends on CPU_SUBTYPE_SH7724 - select GPIOLIB - select SND_SOC_DA7210 if SND_SIMPLE_CARD - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Renesas "R0P7724LC0011/21RL (EcoVec)" support. - -config SH_SH7763RDP - bool "SH7763RDP" - depends on CPU_SUBTYPE_SH7763 - help - Select SH7763RDP if configuring for a Renesas SH7763 - evaluation board. - -config SH_ESPT - bool "ESPT" - depends on CPU_SUBTYPE_SH7763 - help - Select ESPT if configuring for a Renesas SH7763 - with gigabit ether evaluation board. - -config SH_EDOSK7705 - bool "EDOSK7705" - depends on CPU_SUBTYPE_SH7705 - -config SH_EDOSK7760 - bool "EDOSK7760" - depends on CPU_SUBTYPE_SH7760 - help - Select if configuring for a Renesas EDOSK7760 - evaluation board. - -config SH_SH4202_MICRODEV - bool "SH4-202 MicroDev" - depends on CPU_SUBTYPE_SH4_202 - help - Select SH4-202 MicroDev if configuring for a SuperH MicroDev board - with an SH4-202 CPU. - -config SH_LANDISK - bool "LANDISK" - depends on CPU_SUBTYPE_SH7751R - select HAVE_PCI - help - I-O DATA DEVICE, INC. "LANDISK Series" support. - -config SH_TITAN - bool "TITAN" - depends on CPU_SUBTYPE_SH7751R - select CPU_HAS_IPR_IRQ - select HAVE_PCI - help - Select Titan if you are configuring for a Nimble Microsystems - NetEngine NP51R. - -config SH_SHMIN - bool "SHMIN" - depends on CPU_SUBTYPE_SH7706 - select CPU_HAS_IPR_IRQ - help - Select SHMIN if configuring for the SHMIN board. - -config SH_LBOX_RE2 - bool "L-BOX RE2" - depends on CPU_SUBTYPE_SH7751R - select HAVE_PCI - help - Select L-BOX RE2 if configuring for the NTT COMWARE L-BOX RE2. - -config SH_X3PROTO - bool "SH-X3 Prototype board" - depends on CPU_SUBTYPE_SHX3 - select NO_IOPORT_MAP if !PCI - select IRQ_DOMAIN - -config SH_MAGIC_PANEL_R2 - bool "Magic Panel R2" - depends on CPU_SUBTYPE_SH7720 - select GPIOLIB - select REGULATOR_FIXED_VOLTAGE if REGULATOR - help - Select Magic Panel R2 if configuring for Magic Panel R2. - -config SH_POLARIS - bool "SMSC Polaris" - select CPU_HAS_IPR_IRQ - select REGULATOR_FIXED_VOLTAGE if REGULATOR - depends on CPU_SUBTYPE_SH7709 - help - Select if configuring for an SMSC Polaris development board - -config SH_SH2007 - bool "SH-2007 board" - select NO_IOPORT_MAP - select REGULATOR_FIXED_VOLTAGE if REGULATOR - depends on CPU_SUBTYPE_SH7780 - help - SH-2007 is a single-board computer based around SH7780 chip - intended for embedded applications. - It has an Ethernet interface (SMC9118), direct connected - Compact Flash socket, two serial ports and PC-104 bus. - More information at . - -config SH_APSH4A3A - bool "AP-SH4A-3A" - select SH_ALPHA_BOARD - select REGULATOR_FIXED_VOLTAGE if REGULATOR - depends on CPU_SUBTYPE_SH7785 - help - Select AP-SH4A-3A if configuring for an ALPHAPROJECT AP-SH4A-3A. - -config SH_APSH4AD0A - bool "AP-SH4AD-0A" - select SH_ALPHA_BOARD - select HAVE_PCI - select REGULATOR_FIXED_VOLTAGE if REGULATOR - depends on CPU_SUBTYPE_SH7786 - help - Select AP-SH4AD-0A if configuring for an ALPHAPROJECT AP-SH4AD-0A. - -source "arch/sh/boards/mach-r2d/Kconfig" -source "arch/sh/boards/mach-highlander/Kconfig" -source "arch/sh/boards/mach-sdk7780/Kconfig" -source "arch/sh/boards/mach-migor/Kconfig" -source "arch/sh/boards/mach-rsk/Kconfig" - -if SH_MAGIC_PANEL_R2 - -menu "Magic Panel R2 options" - -config SH_MAGIC_PANEL_R2_VERSION - int "Magic Panel R2 Version" - default "3" - help - Set the version of the Magic Panel R2 - -endmenu - -endif - -endmenu diff --git a/arch/sh/boards/Makefile b/arch/sh/boards/Makefile deleted file mode 100644 index 4002a22a7c409b..00000000000000 --- a/arch/sh/boards/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -# -# Specific board support, not covered by a mach group. -# -obj-$(CONFIG_SH_MAGIC_PANEL_R2) += board-magicpanelr2.o -obj-$(CONFIG_SH_SECUREEDGE5410) += board-secureedge5410.o -obj-$(CONFIG_SH_SH2007) += board-sh2007.o -obj-$(CONFIG_SH_SH7785LCR) += board-sh7785lcr.o -obj-$(CONFIG_SH_URQUELL) += board-urquell.o -obj-$(CONFIG_SH_SHMIN) += board-shmin.o -obj-$(CONFIG_SH_EDOSK7705) += board-edosk7705.o -obj-$(CONFIG_SH_EDOSK7760) += board-edosk7760.o -obj-$(CONFIG_SH_ESPT) += board-espt.o -obj-$(CONFIG_SH_POLARIS) += board-polaris.o -obj-$(CONFIG_SH_TITAN) += board-titan.o -obj-$(CONFIG_SH_SH7757LCR) += board-sh7757lcr.o -obj-$(CONFIG_SH_APSH4A3A) += board-apsh4a3a.o -obj-$(CONFIG_SH_APSH4AD0A) += board-apsh4ad0a.o - -obj-$(CONFIG_SH_DEVICE_TREE) += of-generic.o diff --git a/arch/sh/boards/board-apsh4a3a.c b/arch/sh/boards/board-apsh4a3a.c deleted file mode 100644 index abf19a947df354..00000000000000 --- a/arch/sh/boards/board-apsh4a3a.c +++ /dev/null @@ -1,182 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * ALPHAPROJECT AP-SH4A-3A Support. - * - * Copyright (C) 2010 ALPHAPROJECT Co.,Ltd. - * Copyright (C) 2008 Yoshihiro Shimoda - * Copyright (C) 2009 Paul Mundt - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -static struct mtd_partition nor_flash_partitions[] = { - { - .name = "loader", - .offset = 0x00000000, - .size = 512 * 1024, - }, - { - .name = "bootenv", - .offset = MTDPART_OFS_APPEND, - .size = 512 * 1024, - }, - { - .name = "kernel", - .offset = MTDPART_OFS_APPEND, - .size = 4 * 1024 * 1024, - }, - { - .name = "data", - .offset = MTDPART_OFS_APPEND, - .size = MTDPART_SIZ_FULL, - }, -}; - -static struct physmap_flash_data nor_flash_data = { - .width = 4, - .parts = nor_flash_partitions, - .nr_parts = ARRAY_SIZE(nor_flash_partitions), -}; - -static struct resource nor_flash_resources[] = { - [0] = { - .start = 0x00000000, - .end = 0x01000000 - 1, - .flags = IORESOURCE_MEM, - } -}; - -static struct platform_device nor_flash_device = { - .name = "physmap-flash", - .dev = { - .platform_data = &nor_flash_data, - }, - .num_resources = ARRAY_SIZE(nor_flash_resources), - .resource = nor_flash_resources, -}; - -/* Dummy supplies, where voltage doesn't matter */ -static struct regulator_consumer_supply dummy_supplies[] = { - REGULATOR_SUPPLY("vddvario", "smsc911x"), - REGULATOR_SUPPLY("vdd33a", "smsc911x"), -}; - -static struct resource smsc911x_resources[] = { - [0] = { - .name = "smsc911x-memory", - .start = 0xA4000000, - .end = 0xA4000000 + SZ_256 - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .name = "smsc911x-irq", - .start = evt2irq(0x200), - .end = evt2irq(0x200), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct smsc911x_platform_config smsc911x_config = { - .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, - .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, - .flags = SMSC911X_USE_16BIT, - .phy_interface = PHY_INTERFACE_MODE_MII, -}; - -static struct platform_device smsc911x_device = { - .name = "smsc911x", - .id = -1, - .num_resources = ARRAY_SIZE(smsc911x_resources), - .resource = smsc911x_resources, - .dev = { - .platform_data = &smsc911x_config, - }, -}; - -static struct platform_device *apsh4a3a_devices[] __initdata = { - &nor_flash_device, - &smsc911x_device, -}; - -static int __init apsh4a3a_devices_setup(void) -{ - regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - - return platform_add_devices(apsh4a3a_devices, - ARRAY_SIZE(apsh4a3a_devices)); -} -device_initcall(apsh4a3a_devices_setup); - -static int apsh4a3a_clk_init(void) -{ - struct clk *clk; - int ret; - - clk = clk_get(NULL, "extal"); - if (IS_ERR(clk)) - return PTR_ERR(clk); - ret = clk_set_rate(clk, 33333000); - clk_put(clk); - - return ret; -} - -/* Initialize the board */ -static void __init apsh4a3a_setup(char **cmdline_p) -{ - printk(KERN_INFO "Alpha Project AP-SH4A-3A support:\n"); -} - -static void __init apsh4a3a_init_irq(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ7654); -} - -/* Return the board specific boot mode pin configuration */ -static int apsh4a3a_mode_pins(void) -{ - int value = 0; - - /* These are the factory default settings of SW1 and SW2. - * If you change these dip switches then you will need to - * adjust the values below as well. - */ - value &= ~MODE_PIN0; /* Clock Mode 16 */ - value &= ~MODE_PIN1; - value &= ~MODE_PIN2; - value &= ~MODE_PIN3; - value |= MODE_PIN4; - value &= ~MODE_PIN5; /* 16-bit Area0 bus width */ - value |= MODE_PIN6; /* Area 0 SRAM interface */ - value |= MODE_PIN7; - value |= MODE_PIN8; /* Little Endian */ - value |= MODE_PIN9; /* Master Mode */ - value |= MODE_PIN10; /* Crystal resonator */ - value |= MODE_PIN11; /* Display Unit */ - value |= MODE_PIN12; - value &= ~MODE_PIN13; /* 29-bit address mode */ - value |= MODE_PIN14; /* No PLL step-up */ - - return value; -} - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_apsh4a3a __initmv = { - .mv_name = "AP-SH4A-3A", - .mv_setup = apsh4a3a_setup, - .mv_clk_init = apsh4a3a_clk_init, - .mv_init_irq = apsh4a3a_init_irq, - .mv_mode_pins = apsh4a3a_mode_pins, -}; diff --git a/arch/sh/boards/board-apsh4ad0a.c b/arch/sh/boards/board-apsh4ad0a.c deleted file mode 100644 index fa031a16c9b5c7..00000000000000 --- a/arch/sh/boards/board-apsh4ad0a.c +++ /dev/null @@ -1,132 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * ALPHAPROJECT AP-SH4AD-0A Support. - * - * Copyright (C) 2010 ALPHAPROJECT Co.,Ltd. - * Copyright (C) 2010 Matt Fleming - * Copyright (C) 2010 Paul Mundt - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* Dummy supplies, where voltage doesn't matter */ -static struct regulator_consumer_supply dummy_supplies[] = { - REGULATOR_SUPPLY("vddvario", "smsc911x"), - REGULATOR_SUPPLY("vdd33a", "smsc911x"), -}; - -static struct resource smsc911x_resources[] = { - [0] = { - .name = "smsc911x-memory", - .start = 0xA4000000, - .end = 0xA4000000 + SZ_256 - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .name = "smsc911x-irq", - .start = evt2irq(0x200), - .end = evt2irq(0x200), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct smsc911x_platform_config smsc911x_config = { - .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, - .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, - .flags = SMSC911X_USE_16BIT, - .phy_interface = PHY_INTERFACE_MODE_MII, -}; - -static struct platform_device smsc911x_device = { - .name = "smsc911x", - .id = -1, - .num_resources = ARRAY_SIZE(smsc911x_resources), - .resource = smsc911x_resources, - .dev = { - .platform_data = &smsc911x_config, - }, -}; - -static struct platform_device *apsh4ad0a_devices[] __initdata = { - &smsc911x_device, -}; - -static int __init apsh4ad0a_devices_setup(void) -{ - regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - - return platform_add_devices(apsh4ad0a_devices, - ARRAY_SIZE(apsh4ad0a_devices)); -} -device_initcall(apsh4ad0a_devices_setup); - -static int apsh4ad0a_mode_pins(void) -{ - int value = 0; - - /* These are the factory default settings of SW1 and SW2. - * If you change these dip switches then you will need to - * adjust the values below as well. - */ - value |= MODE_PIN0; /* Clock Mode 3 */ - value |= MODE_PIN1; - value &= ~MODE_PIN2; - value &= ~MODE_PIN3; - value &= ~MODE_PIN4; /* 16-bit Area0 bus width */ - value |= MODE_PIN5; - value |= MODE_PIN6; - value |= MODE_PIN7; /* Normal mode */ - value |= MODE_PIN8; /* Little Endian */ - value |= MODE_PIN9; /* Crystal resonator */ - value &= ~MODE_PIN10; /* 29-bit address mode */ - value &= ~MODE_PIN11; /* PCI-E Root port */ - value &= ~MODE_PIN12; /* 4 lane + 1 lane */ - value |= MODE_PIN13; /* AUD Enable */ - value &= ~MODE_PIN14; /* Normal Operation */ - - return value; -} - -static int apsh4ad0a_clk_init(void) -{ - struct clk *clk; - int ret; - - clk = clk_get(NULL, "extal"); - if (IS_ERR(clk)) - return PTR_ERR(clk); - ret = clk_set_rate(clk, 33333000); - clk_put(clk); - - return ret; -} - -/* Initialize the board */ -static void __init apsh4ad0a_setup(char **cmdline_p) -{ - pr_info("Alpha Project AP-SH4AD-0A support:\n"); -} - -static void __init apsh4ad0a_init_irq(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ3210); -} - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_apsh4ad0a __initmv = { - .mv_name = "AP-SH4AD-0A", - .mv_setup = apsh4ad0a_setup, - .mv_mode_pins = apsh4ad0a_mode_pins, - .mv_clk_init = apsh4ad0a_clk_init, - .mv_init_irq = apsh4ad0a_init_irq, -}; diff --git a/arch/sh/boards/board-edosk7705.c b/arch/sh/boards/board-edosk7705.c deleted file mode 100644 index 0de7d603da2d8c..00000000000000 --- a/arch/sh/boards/board-edosk7705.c +++ /dev/null @@ -1,79 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * arch/sh/boards/renesas/edosk7705/setup.c - * - * Copyright (C) 2000 Kazumoto Kojima - * - * Hitachi SolutionEngine Support. - * - * Modified for edosk7705 development - * board by S. Dunn, 2003. - */ -#include -#include -#include -#include -#include -#include -#include -#include - -#define SMC_IOBASE 0xA2000000 -#define SMC_IO_OFFSET 0x300 -#define SMC_IOADDR (SMC_IOBASE + SMC_IO_OFFSET) - -#define ETHERNET_IRQ evt2irq(0x320) - -static void __init sh_edosk7705_init_irq(void) -{ - make_imask_irq(ETHERNET_IRQ); -} - -/* eth initialization functions */ -static struct smc91x_platdata smc91x_info = { - .flags = SMC91X_USE_16BIT | SMC91X_IO_SHIFT_1 | IORESOURCE_IRQ_LOWLEVEL, -}; - -static struct resource smc91x_res[] = { - [0] = { - .start = SMC_IOADDR, - .end = SMC_IOADDR + SZ_32 - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = ETHERNET_IRQ, - .end = ETHERNET_IRQ, - .flags = IORESOURCE_IRQ , - } -}; - -static struct platform_device smc91x_dev = { - .name = "smc91x", - .id = -1, - .num_resources = ARRAY_SIZE(smc91x_res), - .resource = smc91x_res, - - .dev = { - .platform_data = &smc91x_info, - }, -}; - -/* platform init code */ -static struct platform_device *edosk7705_devices[] __initdata = { - &smc91x_dev, -}; - -static int __init init_edosk7705_devices(void) -{ - return platform_add_devices(edosk7705_devices, - ARRAY_SIZE(edosk7705_devices)); -} -device_initcall(init_edosk7705_devices); - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_edosk7705 __initmv = { - .mv_name = "EDOSK7705", - .mv_init_irq = sh_edosk7705_init_irq, -}; diff --git a/arch/sh/boards/board-edosk7760.c b/arch/sh/boards/board-edosk7760.c deleted file mode 100644 index 7569d85c5ff5a8..00000000000000 --- a/arch/sh/boards/board-edosk7760.c +++ /dev/null @@ -1,178 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0+ -/* - * Renesas Europe EDOSK7760 Board Support - * - * Copyright (C) 2008 SPES Societa' Progettazione Elettronica e Software Ltd. - * Author: Luca Santini - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* Bus state controller registers for CS4 area */ -#define BSC_CS4BCR 0xA4FD0010 -#define BSC_CS4WCR 0xA4FD0030 - -#define SMC_IOBASE 0xA2000000 -#define SMC_IO_OFFSET 0x300 -#define SMC_IOADDR (SMC_IOBASE + SMC_IO_OFFSET) - -/* NOR flash */ -static struct mtd_partition edosk7760_nor_flash_partitions[] = { - { - .name = "bootloader", - .offset = 0, - .size = SZ_256K, - .mask_flags = MTD_WRITEABLE, /* Read-only */ - }, { - .name = "kernel", - .offset = MTDPART_OFS_APPEND, - .size = SZ_2M, - }, { - .name = "fs", - .offset = MTDPART_OFS_APPEND, - .size = (26 << 20), - }, { - .name = "other", - .offset = MTDPART_OFS_APPEND, - .size = MTDPART_SIZ_FULL, - }, -}; - -static struct physmap_flash_data edosk7760_nor_flash_data = { - .width = 4, - .parts = edosk7760_nor_flash_partitions, - .nr_parts = ARRAY_SIZE(edosk7760_nor_flash_partitions), -}; - -static struct resource edosk7760_nor_flash_resources[] = { - [0] = { - .name = "NOR Flash", - .start = 0x00000000, - .end = 0x00000000 + SZ_32M - 1, - .flags = IORESOURCE_MEM, - } -}; - -static struct platform_device edosk7760_nor_flash_device = { - .name = "physmap-flash", - .resource = edosk7760_nor_flash_resources, - .num_resources = ARRAY_SIZE(edosk7760_nor_flash_resources), - .dev = { - .platform_data = &edosk7760_nor_flash_data, - }, -}; - -/* i2c initialization functions */ -static struct sh7760_i2c_platdata i2c_pd = { - .speed_khz = 400, -}; - -static struct resource sh7760_i2c1_res[] = { - { - .start = SH7760_I2C1_MMIO, - .end = SH7760_I2C1_MMIOEND, - .flags = IORESOURCE_MEM, - },{ - .start = evt2irq(0x9e0), - .end = evt2irq(0x9e0), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device sh7760_i2c1_dev = { - .dev = { - .platform_data = &i2c_pd, - }, - - .name = SH7760_I2C_DEVNAME, - .id = 1, - .resource = sh7760_i2c1_res, - .num_resources = ARRAY_SIZE(sh7760_i2c1_res), -}; - -static struct resource sh7760_i2c0_res[] = { - { - .start = SH7760_I2C0_MMIO, - .end = SH7760_I2C0_MMIOEND, - .flags = IORESOURCE_MEM, - }, { - .start = evt2irq(0x9c0), - .end = evt2irq(0x9c0), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device sh7760_i2c0_dev = { - .dev = { - .platform_data = &i2c_pd, - }, - .name = SH7760_I2C_DEVNAME, - .id = 0, - .resource = sh7760_i2c0_res, - .num_resources = ARRAY_SIZE(sh7760_i2c0_res), -}; - -/* eth initialization functions */ -static struct smc91x_platdata smc91x_info = { - .flags = SMC91X_USE_16BIT | SMC91X_IO_SHIFT_1 | IORESOURCE_IRQ_LOWLEVEL, -}; - -static struct resource smc91x_res[] = { - [0] = { - .start = SMC_IOADDR, - .end = SMC_IOADDR + SZ_32 - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x2a0), - .end = evt2irq(0x2a0), - .flags = IORESOURCE_IRQ , - } -}; - -static struct platform_device smc91x_dev = { - .name = "smc91x", - .id = -1, - .num_resources = ARRAY_SIZE(smc91x_res), - .resource = smc91x_res, - - .dev = { - .platform_data = &smc91x_info, - }, -}; - -/* platform init code */ -static struct platform_device *edosk7760_devices[] __initdata = { - &smc91x_dev, - &edosk7760_nor_flash_device, - &sh7760_i2c0_dev, - &sh7760_i2c1_dev, -}; - -static int __init init_edosk7760_devices(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ); - - return platform_add_devices(edosk7760_devices, - ARRAY_SIZE(edosk7760_devices)); -} -device_initcall(init_edosk7760_devices); - -/* - * The Machine Vector - */ -struct sh_machine_vector mv_edosk7760 __initmv = { - .mv_name = "EDOSK7760", -}; diff --git a/arch/sh/boards/board-espt.c b/arch/sh/boards/board-espt.c deleted file mode 100644 index 6e784b5cf5a0b2..00000000000000 --- a/arch/sh/boards/board-espt.c +++ /dev/null @@ -1,105 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Data Technology Inc. ESPT-GIGA board support - * - * Copyright (C) 2008, 2009 Renesas Solutions Corp. - * Copyright (C) 2008, 2009 Nobuhiro Iwamatsu - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* NOR Flash */ -static struct mtd_partition espt_nor_flash_partitions[] = { - { - .name = "U-Boot", - .offset = 0, - .size = (2 * SZ_128K), - .mask_flags = MTD_WRITEABLE, /* Read-only */ - }, { - .name = "Linux-Kernel", - .offset = MTDPART_OFS_APPEND, - .size = (20 * SZ_128K), - }, { - .name = "Root Filesystem", - .offset = MTDPART_OFS_APPEND, - .size = MTDPART_SIZ_FULL, - }, -}; - -static struct physmap_flash_data espt_nor_flash_data = { - .width = 2, - .parts = espt_nor_flash_partitions, - .nr_parts = ARRAY_SIZE(espt_nor_flash_partitions), -}; - -static struct resource espt_nor_flash_resources[] = { - [0] = { - .name = "NOR Flash", - .start = 0, - .end = SZ_8M - 1, - .flags = IORESOURCE_MEM, - }, -}; - -static struct platform_device espt_nor_flash_device = { - .name = "physmap-flash", - .resource = espt_nor_flash_resources, - .num_resources = ARRAY_SIZE(espt_nor_flash_resources), - .dev = { - .platform_data = &espt_nor_flash_data, - }, -}; - -/* SH-Ether */ -static struct resource sh_eth_resources[] = { - { - .start = 0xFEE00800, /* use eth1 */ - .end = 0xFEE00F7C - 1, - .flags = IORESOURCE_MEM, - }, { - .start = 0xFEE01800, /* TSU */ - .end = 0xFEE01FFF, - .flags = IORESOURCE_MEM, - }, { - - .start = evt2irq(0x920), /* irq number */ - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_eth_plat_data sh7763_eth_pdata = { - .phy = 0, - .phy_interface = PHY_INTERFACE_MODE_MII, -}; - -static struct platform_device espt_eth_device = { - .name = "sh7763-gether", - .resource = sh_eth_resources, - .num_resources = ARRAY_SIZE(sh_eth_resources), - .dev = { - .platform_data = &sh7763_eth_pdata, - }, -}; - -static struct platform_device *espt_devices[] __initdata = { - &espt_nor_flash_device, - &espt_eth_device, -}; - -static int __init espt_devices_setup(void) -{ - return platform_add_devices(espt_devices, - ARRAY_SIZE(espt_devices)); -} -device_initcall(espt_devices_setup); - -static struct sh_machine_vector mv_espt __initmv = { - .mv_name = "ESPT-GIGA", -}; diff --git a/arch/sh/boards/board-magicpanelr2.c b/arch/sh/boards/board-magicpanelr2.c deleted file mode 100644 index 56bd386ff3b043..00000000000000 --- a/arch/sh/boards/board-magicpanelr2.c +++ /dev/null @@ -1,390 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * linux/arch/sh/boards/magicpanel/setup.c - * - * Copyright (C) 2007 Markus Brunner, Mark Jonas - * - * Magic Panel Release 2 board setup - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* Dummy supplies, where voltage doesn't matter */ -static struct regulator_consumer_supply dummy_supplies[] = { - REGULATOR_SUPPLY("vddvario", "smsc911x"), - REGULATOR_SUPPLY("vdd33a", "smsc911x"), -}; - -#define LAN9115_READY (__raw_readl(0xA8000084UL) & 0x00000001UL) - -/* Wait until reset finished. Timeout is 100ms. */ -static int __init ethernet_reset_finished(void) -{ - int i; - - if (LAN9115_READY) - return 1; - - for (i = 0; i < 10; ++i) { - mdelay(10); - if (LAN9115_READY) - return 1; - } - - return 0; -} - -static void __init reset_ethernet(void) -{ - /* PMDR: LAN_RESET=on */ - CLRBITS_OUTB(0x10, PORT_PMDR); - - udelay(200); - - /* PMDR: LAN_RESET=off */ - SETBITS_OUTB(0x10, PORT_PMDR); -} - -static void __init setup_chip_select(void) -{ - /* CS2: LAN (0x08000000 - 0x0bffffff) */ - /* no idle cycles, normal space, 8 bit data bus */ - __raw_writel(0x36db0400, CS2BCR); - /* (SW:1.5 WR:3 HW:1.5), ext. wait */ - __raw_writel(0x000003c0, CS2WCR); - - /* CS4: CAN1 (0xb0000000 - 0xb3ffffff) */ - /* no idle cycles, normal space, 8 bit data bus */ - __raw_writel(0x00000200, CS4BCR); - /* (SW:1.5 WR:3 HW:1.5), ext. wait */ - __raw_writel(0x00100981, CS4WCR); - - /* CS5a: CAN2 (0xb4000000 - 0xb5ffffff) */ - /* no idle cycles, normal space, 8 bit data bus */ - __raw_writel(0x00000200, CS5ABCR); - /* (SW:1.5 WR:3 HW:1.5), ext. wait */ - __raw_writel(0x00100981, CS5AWCR); - - /* CS5b: CAN3 (0xb6000000 - 0xb7ffffff) */ - /* no idle cycles, normal space, 8 bit data bus */ - __raw_writel(0x00000200, CS5BBCR); - /* (SW:1.5 WR:3 HW:1.5), ext. wait */ - __raw_writel(0x00100981, CS5BWCR); - - /* CS6a: Rotary (0xb8000000 - 0xb9ffffff) */ - /* no idle cycles, normal space, 8 bit data bus */ - __raw_writel(0x00000200, CS6ABCR); - /* (SW:1.5 WR:3 HW:1.5), no ext. wait */ - __raw_writel(0x001009C1, CS6AWCR); -} - -static void __init setup_port_multiplexing(void) -{ - /* A7 GPO(LED8); A6 GPO(LED7); A5 GPO(LED6); A4 GPO(LED5); - * A3 GPO(LED4); A2 GPO(LED3); A1 GPO(LED2); A0 GPO(LED1); - */ - __raw_writew(0x5555, PORT_PACR); /* 01 01 01 01 01 01 01 01 */ - - /* B7 GPO(RST4); B6 GPO(RST3); B5 GPO(RST2); B4 GPO(RST1); - * B3 GPO(PB3); B2 GPO(PB2); B1 GPO(PB1); B0 GPO(PB0); - */ - __raw_writew(0x5555, PORT_PBCR); /* 01 01 01 01 01 01 01 01 */ - - /* C7 GPO(PC7); C6 GPO(PC6); C5 GPO(PC5); C4 GPO(PC4); - * C3 LCD_DATA3; C2 LCD_DATA2; C1 LCD_DATA1; C0 LCD_DATA0; - */ - __raw_writew(0x5500, PORT_PCCR); /* 01 01 01 01 00 00 00 00 */ - - /* D7 GPO(PD7); D6 GPO(PD6); D5 GPO(PD5); D4 GPO(PD4); - * D3 GPO(PD3); D2 GPO(PD2); D1 GPO(PD1); D0 GPO(PD0); - */ - __raw_writew(0x5555, PORT_PDCR); /* 01 01 01 01 01 01 01 01 */ - - /* E7 (x); E6 GPI(nu); E5 GPI(nu); E4 LCD_M_DISP; - * E3 LCD_CL1; E2 LCD_CL2; E1 LCD_DON; E0 LCD_FLM; - */ - __raw_writew(0x3C00, PORT_PECR); /* 00 11 11 00 00 00 00 00 */ - - /* F7 (x); F6 DA1(VLCD); F5 DA0(nc); F4 AN3; - * F3 AN2(MID_AD); F2 AN1(EARTH_AD); F1 AN0(TEMP); F0 GPI+(nc); - */ - __raw_writew(0x0002, PORT_PFCR); /* 00 00 00 00 00 00 00 10 */ - - /* G7 (x); G6 IRQ5(TOUCH_BUSY); G5 IRQ4(TOUCH_IRQ); G4 GPI(KEY2); - * G3 GPI(KEY1); G2 GPO(LED11); G1 GPO(LED10); G0 GPO(LED9); - */ - __raw_writew(0x03D5, PORT_PGCR); /* 00 00 00 11 11 01 01 01 */ - - /* H7 (x); H6 /RAS(BRAS); H5 /CAS(BCAS); H4 CKE(BCKE); - * H3 GPO(EARTH_OFF); H2 GPO(EARTH_TEST); H1 USB2_PWR; H0 USB1_PWR; - */ - __raw_writew(0x0050, PORT_PHCR); /* 00 00 00 00 01 01 00 00 */ - - /* J7 (x); J6 AUDCK; J5 ASEBRKAK; J4 AUDATA3; - * J3 AUDATA2; J2 AUDATA1; J1 AUDATA0; J0 AUDSYNC; - */ - __raw_writew(0x0000, PORT_PJCR); /* 00 00 00 00 00 00 00 00 */ - - /* K7 (x); K6 (x); K5 (x); K4 (x); - * K3 PINT7(/PWR2); K2 PINT6(/PWR1); K1 PINT5(nu); K0 PINT4(FLASH_READY) - */ - __raw_writew(0x00FF, PORT_PKCR); /* 00 00 00 00 11 11 11 11 */ - - /* L7 TRST; L6 TMS; L5 TDO; L4 TDI; - * L3 TCK; L2 (x); L1 (x); L0 (x); - */ - __raw_writew(0x0000, PORT_PLCR); /* 00 00 00 00 00 00 00 00 */ - - /* M7 GPO(CURRENT_SINK); M6 GPO(PWR_SWITCH); M5 GPO(LAN_SPEED); - * M4 GPO(LAN_RESET); M3 GPO(BUZZER); M2 GPO(LCD_BL); - * M1 CS5B(CAN3_CS); M0 GPI+(nc); - */ - __raw_writew(0x5552, PORT_PMCR); /* 01 01 01 01 01 01 00 10 */ - - /* CURRENT_SINK=off, PWR_SWITCH=off, LAN_SPEED=100MBit, - * LAN_RESET=off, BUZZER=off, LCD_BL=off - */ -#if CONFIG_SH_MAGIC_PANEL_R2_VERSION == 2 - __raw_writeb(0x30, PORT_PMDR); -#elif CONFIG_SH_MAGIC_PANEL_R2_VERSION == 3 - __raw_writeb(0xF0, PORT_PMDR); -#else -#error Unknown revision of PLATFORM_MP_R2 -#endif - - /* P7 (x); P6 (x); P5 (x); - * P4 GPO(nu); P3 IRQ3(LAN_IRQ); P2 IRQ2(CAN3_IRQ); - * P1 IRQ1(CAN2_IRQ); P0 IRQ0(CAN1_IRQ) - */ - __raw_writew(0x0100, PORT_PPCR); /* 00 00 00 01 00 00 00 00 */ - __raw_writeb(0x10, PORT_PPDR); - - /* R7 A25; R6 A24; R5 A23; R4 A22; - * R3 A21; R2 A20; R1 A19; R0 A0; - */ - gpio_request(GPIO_FN_A25, NULL); - gpio_request(GPIO_FN_A24, NULL); - gpio_request(GPIO_FN_A23, NULL); - gpio_request(GPIO_FN_A22, NULL); - gpio_request(GPIO_FN_A21, NULL); - gpio_request(GPIO_FN_A20, NULL); - gpio_request(GPIO_FN_A19, NULL); - gpio_request(GPIO_FN_A0, NULL); - - /* S7 (x); S6 (x); S5 (x); S4 GPO(EEPROM_CS2); - * S3 GPO(EEPROM_CS1); S2 SIOF0_TXD; S1 SIOF0_RXD; S0 SIOF0_SCK; - */ - __raw_writew(0x0140, PORT_PSCR); /* 00 00 00 01 01 00 00 00 */ - - /* T7 (x); T6 (x); T5 (x); T4 COM1_CTS; - * T3 COM1_RTS; T2 COM1_TXD; T1 COM1_RXD; T0 GPO(WDOG) - */ - __raw_writew(0x0001, PORT_PTCR); /* 00 00 00 00 00 00 00 01 */ - - /* U7 (x); U6 (x); U5 (x); U4 GPI+(/AC_FAULT); - * U3 GPO(TOUCH_CS); U2 TOUCH_TXD; U1 TOUCH_RXD; U0 TOUCH_SCK; - */ - __raw_writew(0x0240, PORT_PUCR); /* 00 00 00 10 01 00 00 00 */ - - /* V7 (x); V6 (x); V5 (x); V4 GPO(MID2); - * V3 GPO(MID1); V2 CARD_TxD; V1 CARD_RxD; V0 GPI+(/BAT_FAULT); - */ - __raw_writew(0x0142, PORT_PVCR); /* 00 00 00 01 01 00 00 10 */ -} - -static void __init mpr2_setup(char **cmdline_p) -{ - /* set Pin Select Register A: - * /PCC_CD1, /PCC_CD2, PCC_BVD1, PCC_BVD2, - * /IOIS16, IRQ4, IRQ5, USB1d_SUSPEND - */ - __raw_writew(0xAABC, PORT_PSELA); - /* set Pin Select Register B: - * /SCIF0_RTS, /SCIF0_CTS, LCD_VCPWC, - * LCD_VEPWC, IIC_SDA, IIC_SCL, Reserved - */ - __raw_writew(0x3C00, PORT_PSELB); - /* set Pin Select Register C: - * SIOF1_SCK, SIOF1_RxD, SCIF1_RxD, SCIF1_TxD, Reserved - */ - __raw_writew(0x0000, PORT_PSELC); - /* set Pin Select Register D: Reserved, SIOF1_TxD, Reserved, SIOF1_MCLK, - * Reserved, SIOF1_SYNC, Reserved, SCIF1_SCK, Reserved - */ - __raw_writew(0x0000, PORT_PSELD); - /* set USB TxRx Control: Reserved, DRV, Reserved, USB_TRANS, USB_SEL */ - __raw_writew(0x0101, PORT_UTRCTL); - /* set USB Clock Control: USSCS, USSTB, Reserved (HighByte always A5) */ - __raw_writew(0xA5C0, PORT_UCLKCR_W); - - setup_chip_select(); - - setup_port_multiplexing(); - - reset_ethernet(); - - printk(KERN_INFO "Magic Panel Release 2 A.%i\n", - CONFIG_SH_MAGIC_PANEL_R2_VERSION); - - if (ethernet_reset_finished() == 0) - printk(KERN_WARNING "Ethernet not ready\n"); -} - -static struct resource smsc911x_resources[] = { - [0] = { - .start = 0xa8000000, - .end = 0xabffffff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x660), - .end = evt2irq(0x660), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct smsc911x_platform_config smsc911x_config = { - .phy_interface = PHY_INTERFACE_MODE_MII, - .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, - .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, - .flags = SMSC911X_USE_32BIT, -}; - -static struct platform_device smsc911x_device = { - .name = "smsc911x", - .id = -1, - .num_resources = ARRAY_SIZE(smsc911x_resources), - .resource = smsc911x_resources, - .dev = { - .platform_data = &smsc911x_config, - }, -}; - -static struct resource heartbeat_resources[] = { - [0] = { - .start = PA_LED, - .end = PA_LED, - .flags = IORESOURCE_MEM, - }, -}; - -static struct heartbeat_data heartbeat_data = { - .flags = HEARTBEAT_INVERTED, -}; - -static struct platform_device heartbeat_device = { - .name = "heartbeat", - .id = -1, - .dev = { - .platform_data = &heartbeat_data, - }, - .num_resources = ARRAY_SIZE(heartbeat_resources), - .resource = heartbeat_resources, -}; - -static struct mtd_partition mpr2_partitions[] = { - /* Reserved for bootloader, read-only */ - { - .name = "Bootloader", - .offset = 0x00000000UL, - .size = MPR2_MTD_BOOTLOADER_SIZE, - .mask_flags = MTD_WRITEABLE, - }, - /* Reserved for kernel image */ - { - .name = "Kernel", - .offset = MTDPART_OFS_NXTBLK, - .size = MPR2_MTD_KERNEL_SIZE, - }, - /* Rest is used for Flash FS */ - { - .name = "Flash_FS", - .offset = MTDPART_OFS_NXTBLK, - .size = MTDPART_SIZ_FULL, - } -}; - -static struct physmap_flash_data flash_data = { - .parts = mpr2_partitions, - .nr_parts = ARRAY_SIZE(mpr2_partitions), - .width = 2, -}; - -static struct resource flash_resource = { - .start = 0x00000000, - .end = 0x2000000UL, - .flags = IORESOURCE_MEM, -}; - -static struct platform_device flash_device = { - .name = "physmap-flash", - .id = -1, - .resource = &flash_resource, - .num_resources = 1, - .dev = { - .platform_data = &flash_data, - }, -}; - -/* - * Add all resources to the platform_device - */ - -static struct platform_device *mpr2_devices[] __initdata = { - &heartbeat_device, - &smsc911x_device, - &flash_device, -}; - - -static int __init mpr2_devices_setup(void) -{ - regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - - return platform_add_devices(mpr2_devices, ARRAY_SIZE(mpr2_devices)); -} -device_initcall(mpr2_devices_setup); - -/* - * Initialize IRQ setting - */ -static void __init init_mpr2_IRQ(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ); /* install handlers for IRQ0-5 */ - - irq_set_irq_type(evt2irq(0x600), IRQ_TYPE_LEVEL_LOW); /* IRQ0 CAN1 */ - irq_set_irq_type(evt2irq(0x620), IRQ_TYPE_LEVEL_LOW); /* IRQ1 CAN2 */ - irq_set_irq_type(evt2irq(0x640), IRQ_TYPE_LEVEL_LOW); /* IRQ2 CAN3 */ - irq_set_irq_type(evt2irq(0x660), IRQ_TYPE_LEVEL_LOW); /* IRQ3 SMSC9115 */ - irq_set_irq_type(evt2irq(0x680), IRQ_TYPE_EDGE_RISING); /* IRQ4 touchscreen */ - irq_set_irq_type(evt2irq(0x6a0), IRQ_TYPE_EDGE_FALLING); /* IRQ5 touchscreen */ - - intc_set_priority(evt2irq(0x600), 13); /* IRQ0 CAN1 */ - intc_set_priority(evt2irq(0x620), 13); /* IRQ0 CAN2 */ - intc_set_priority(evt2irq(0x640), 13); /* IRQ0 CAN3 */ - intc_set_priority(evt2irq(0x660), 6); /* IRQ3 SMSC9115 */ -} - -/* - * The Machine Vector - */ - -static struct sh_machine_vector mv_mpr2 __initmv = { - .mv_name = "mpr2", - .mv_setup = mpr2_setup, - .mv_init_irq = init_mpr2_IRQ, -}; diff --git a/arch/sh/boards/board-polaris.c b/arch/sh/boards/board-polaris.c deleted file mode 100644 index 3de7bac0190392..00000000000000 --- a/arch/sh/boards/board-polaris.c +++ /dev/null @@ -1,156 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * June 2006 Steve Glendinning - * - * Polaris-specific resource declaration - * - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define BCR2 (0xFFFFFF62) -#define WCR2 (0xFFFFFF66) -#define AREA5_WAIT_CTRL (0x1C00) -#define WAIT_STATES_10 (0x7) - -/* Dummy supplies, where voltage doesn't matter */ -static struct regulator_consumer_supply dummy_supplies[] = { - REGULATOR_SUPPLY("vddvario", "smsc911x.0"), - REGULATOR_SUPPLY("vdd33a", "smsc911x.0"), -}; - -static struct resource smsc911x_resources[] = { - [0] = { - .name = "smsc911x-memory", - .start = PA_EXT5, - .end = PA_EXT5 + 0x1fff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .name = "smsc911x-irq", - .start = IRQ0_IRQ, - .end = IRQ0_IRQ, - .flags = IORESOURCE_IRQ, - }, -}; - -static struct smsc911x_platform_config smsc911x_config = { - .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, - .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, - .flags = SMSC911X_USE_32BIT, - .phy_interface = PHY_INTERFACE_MODE_MII, -}; - -static struct platform_device smsc911x_device = { - .name = "smsc911x", - .id = 0, - .num_resources = ARRAY_SIZE(smsc911x_resources), - .resource = smsc911x_resources, - .dev = { - .platform_data = &smsc911x_config, - }, -}; - -static unsigned char heartbeat_bit_pos[] = { 0, 1, 2, 3 }; - -static struct heartbeat_data heartbeat_data = { - .bit_pos = heartbeat_bit_pos, - .nr_bits = ARRAY_SIZE(heartbeat_bit_pos), -}; - -static struct resource heartbeat_resource = { - .start = PORT_PCDR, - .end = PORT_PCDR, - .flags = IORESOURCE_MEM | IORESOURCE_MEM_8BIT, -}; - -static struct platform_device heartbeat_device = { - .name = "heartbeat", - .id = -1, - .dev = { - .platform_data = &heartbeat_data, - }, - .num_resources = 1, - .resource = &heartbeat_resource, -}; - -static struct platform_device *polaris_devices[] __initdata = { - &smsc911x_device, - &heartbeat_device, -}; - -static int __init polaris_initialise(void) -{ - u16 wcr, bcr_mask; - - printk(KERN_INFO "Configuring Polaris external bus\n"); - - regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - - /* Configure area 5 with 2 wait states */ - wcr = __raw_readw(WCR2); - wcr &= (~AREA5_WAIT_CTRL); - wcr |= (WAIT_STATES_10 << 10); - __raw_writew(wcr, WCR2); - - /* Configure area 5 for 32-bit access */ - bcr_mask = __raw_readw(BCR2); - bcr_mask |= 1 << 10; - __raw_writew(bcr_mask, BCR2); - - return platform_add_devices(polaris_devices, - ARRAY_SIZE(polaris_devices)); -} -arch_initcall(polaris_initialise); - -static struct ipr_data ipr_irq_table[] = { - /* External IRQs */ - { IRQ0_IRQ, 0, 0, 1, }, /* IRQ0 */ - { IRQ1_IRQ, 0, 4, 1, }, /* IRQ1 */ -}; - -static unsigned long ipr_offsets[] = { - INTC_IPRC -}; - -static struct ipr_desc ipr_irq_desc = { - .ipr_offsets = ipr_offsets, - .nr_offsets = ARRAY_SIZE(ipr_offsets), - - .ipr_data = ipr_irq_table, - .nr_irqs = ARRAY_SIZE(ipr_irq_table), - .chip = { - .name = "sh7709-ext", - }, -}; - -static void __init init_polaris_irq(void) -{ - /* Disable all interrupts */ - __raw_writew(0, BCR_ILCRA); - __raw_writew(0, BCR_ILCRB); - __raw_writew(0, BCR_ILCRC); - __raw_writew(0, BCR_ILCRD); - __raw_writew(0, BCR_ILCRE); - __raw_writew(0, BCR_ILCRF); - __raw_writew(0, BCR_ILCRG); - - register_ipr_controller(&ipr_irq_desc); -} - -static struct sh_machine_vector mv_polaris __initmv = { - .mv_name = "Polaris", - .mv_init_irq = init_polaris_irq, -}; diff --git a/arch/sh/boards/board-secureedge5410.c b/arch/sh/boards/board-secureedge5410.c deleted file mode 100644 index 603a82325c65f0..00000000000000 --- a/arch/sh/boards/board-secureedge5410.c +++ /dev/null @@ -1,75 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Copyright (C) 2002 David McCullough - * Copyright (C) 2003 Paul Mundt - * - * Based on files with the following comments: - * - * Copyright (C) 2000 Kazumoto Kojima - * - * Modified for 7751 Solution Engine by - * Ian da Silva and Jeremy Siegel, 2001. - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -unsigned short secureedge5410_ioport; - -/* - * EraseConfig handling functions - */ -static irqreturn_t eraseconfig_interrupt(int irq, void *dev_id) -{ - printk("SnapGear: erase switch interrupt!\n"); - - return IRQ_HANDLED; -} - -static int __init eraseconfig_init(void) -{ - unsigned int irq = evt2irq(0x240); - - printk("SnapGear: EraseConfig init\n"); - - /* Setup "EraseConfig" switch on external IRQ 0 */ - if (request_irq(irq, eraseconfig_interrupt, 0, "Erase Config", NULL)) - printk("SnapGear: failed to register IRQ%d for Reset witch\n", - irq); - else - printk("SnapGear: registered EraseConfig switch on IRQ%d\n", - irq); - return 0; -} -device_initcall(eraseconfig_init); - -/* - * Initialize IRQ setting - * - * IRL0 = erase switch - * IRL1 = eth0 - * IRL2 = eth1 - * IRL3 = crypto - */ -static void __init init_snapgear_IRQ(void) -{ - printk("Setup SnapGear IRQ/IPR ...\n"); - /* enable individual interrupt mode for externals */ - plat_irq_setup_pins(IRQ_MODE_IRQ); -} - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_snapgear __initmv = { - .mv_name = "SnapGear SecureEdge5410", - .mv_init_irq = init_snapgear_IRQ, -}; diff --git a/arch/sh/boards/board-sh2007.c b/arch/sh/boards/board-sh2007.c deleted file mode 100644 index 6ea85e4808512f..00000000000000 --- a/arch/sh/boards/board-sh2007.c +++ /dev/null @@ -1,146 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * SH-2007 board support. - * - * Copyright (C) 2003, 2004 SUGIOKA Toshinobu - * Copyright (C) 2010 Hitoshi Mitake - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* Dummy supplies, where voltage doesn't matter */ -static struct regulator_consumer_supply dummy_supplies[] = { - REGULATOR_SUPPLY("vddvario", "smsc911x.0"), - REGULATOR_SUPPLY("vdd33a", "smsc911x.0"), - REGULATOR_SUPPLY("vddvario", "smsc911x.1"), - REGULATOR_SUPPLY("vdd33a", "smsc911x.1"), -}; - -struct smsc911x_platform_config smc911x_info = { - .flags = SMSC911X_USE_32BIT, - .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, - .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL, -}; - -static struct resource smsc9118_0_resources[] = { - [0] = { - .start = SMC0_BASE, - .end = SMC0_BASE + 0xff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x240), - .end = evt2irq(0x240), - .flags = IORESOURCE_IRQ, - } -}; - -static struct resource smsc9118_1_resources[] = { - [0] = { - .start = SMC1_BASE, - .end = SMC1_BASE + 0xff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x280), - .end = evt2irq(0x280), - .flags = IORESOURCE_IRQ, - } -}; - -static struct platform_device smsc9118_0_device = { - .name = "smsc911x", - .id = 0, - .num_resources = ARRAY_SIZE(smsc9118_0_resources), - .resource = smsc9118_0_resources, - .dev = { - .platform_data = &smc911x_info, - }, -}; - -static struct platform_device smsc9118_1_device = { - .name = "smsc911x", - .id = 1, - .num_resources = ARRAY_SIZE(smsc9118_1_resources), - .resource = smsc9118_1_resources, - .dev = { - .platform_data = &smc911x_info, - }, -}; - -static struct resource cf_resources[] = { - [0] = { - .start = CF_BASE + CF_OFFSET, - .end = CF_BASE + CF_OFFSET + 0x0f, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = CF_BASE + CF_OFFSET + 0x206, - .end = CF_BASE + CF_OFFSET + 0x20f, - .flags = IORESOURCE_MEM, - }, - [2] = { - .start = evt2irq(0x2c0), - .end = evt2irq(0x2c0), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device cf_device = { - .name = "pata_platform", - .id = 0, - .num_resources = ARRAY_SIZE(cf_resources), - .resource = cf_resources, -}; - -static struct platform_device *sh2007_devices[] __initdata = { - &smsc9118_0_device, - &smsc9118_1_device, - &cf_device, -}; - -static int __init sh2007_io_init(void) -{ - regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); - - platform_add_devices(sh2007_devices, ARRAY_SIZE(sh2007_devices)); - return 0; -} -subsys_initcall(sh2007_io_init); - -static void __init sh2007_init_irq(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ); -} - -/* - * Initialize the board - */ -static void __init sh2007_setup(char **cmdline_p) -{ - pr_info("SH-2007 Setup..."); - - /* setup wait control registers for area 5 */ - __raw_writel(CS5BCR_D, CS5BCR); - __raw_writel(CS5WCR_D, CS5WCR); - __raw_writel(CS5PCR_D, CS5PCR); - - pr_cont(" done.\n"); -} - -/* - * The Machine Vector - */ -struct sh_machine_vector mv_sh2007 __initmv = { - .mv_setup = sh2007_setup, - .mv_name = "sh2007", - .mv_init_irq = sh2007_init_irq, -}; diff --git a/arch/sh/boards/board-sh7757lcr.c b/arch/sh/boards/board-sh7757lcr.c deleted file mode 100644 index f39c8196efdfd1..00000000000000 --- a/arch/sh/boards/board-sh7757lcr.c +++ /dev/null @@ -1,604 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Renesas R0P7757LC0012RL Support. - * - * Copyright (C) 2009 - 2010 Renesas Solutions Corp. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -static struct resource heartbeat_resource = { - .start = 0xffec005c, /* PUDR */ - .end = 0xffec005c, - .flags = IORESOURCE_MEM | IORESOURCE_MEM_8BIT, -}; - -static unsigned char heartbeat_bit_pos[] = { 0, 1, 2, 3 }; - -static struct heartbeat_data heartbeat_data = { - .bit_pos = heartbeat_bit_pos, - .nr_bits = ARRAY_SIZE(heartbeat_bit_pos), - .flags = HEARTBEAT_INVERTED, -}; - -static struct platform_device heartbeat_device = { - .name = "heartbeat", - .id = -1, - .dev = { - .platform_data = &heartbeat_data, - }, - .num_resources = 1, - .resource = &heartbeat_resource, -}; - -/* Fast Ethernet */ -#define GBECONT 0xffc10100 -#define GBECONT_RMII1 BIT(17) -#define GBECONT_RMII0 BIT(16) -static void sh7757_eth_set_mdio_gate(void *addr) -{ - if (((unsigned long)addr & 0x00000fff) < 0x0800) - writel(readl(GBECONT) | GBECONT_RMII0, GBECONT); - else - writel(readl(GBECONT) | GBECONT_RMII1, GBECONT); -} - -static struct resource sh_eth0_resources[] = { - { - .start = 0xfef00000, - .end = 0xfef001ff, - .flags = IORESOURCE_MEM, - }, { - .start = evt2irq(0xc80), - .end = evt2irq(0xc80), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_eth_plat_data sh7757_eth0_pdata = { - .phy = 1, - .set_mdio_gate = sh7757_eth_set_mdio_gate, -}; - -static struct platform_device sh7757_eth0_device = { - .name = "sh7757-ether", - .resource = sh_eth0_resources, - .id = 0, - .num_resources = ARRAY_SIZE(sh_eth0_resources), - .dev = { - .platform_data = &sh7757_eth0_pdata, - }, -}; - -static struct resource sh_eth1_resources[] = { - { - .start = 0xfef00800, - .end = 0xfef009ff, - .flags = IORESOURCE_MEM, - }, { - .start = evt2irq(0xc80), - .end = evt2irq(0xc80), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_eth_plat_data sh7757_eth1_pdata = { - .phy = 1, - .set_mdio_gate = sh7757_eth_set_mdio_gate, -}; - -static struct platform_device sh7757_eth1_device = { - .name = "sh7757-ether", - .resource = sh_eth1_resources, - .id = 1, - .num_resources = ARRAY_SIZE(sh_eth1_resources), - .dev = { - .platform_data = &sh7757_eth1_pdata, - }, -}; - -static void sh7757_eth_giga_set_mdio_gate(void *addr) -{ - if (((unsigned long)addr & 0x00000fff) < 0x0800) { - gpio_set_value(GPIO_PTT4, 1); - writel(readl(GBECONT) & ~GBECONT_RMII0, GBECONT); - } else { - gpio_set_value(GPIO_PTT4, 0); - writel(readl(GBECONT) & ~GBECONT_RMII1, GBECONT); - } -} - -static struct resource sh_eth_giga0_resources[] = { - { - .start = 0xfee00000, - .end = 0xfee007ff, - .flags = IORESOURCE_MEM, - }, { - /* TSU */ - .start = 0xfee01800, - .end = 0xfee01fff, - .flags = IORESOURCE_MEM, - }, { - .start = evt2irq(0x2960), - .end = evt2irq(0x2960), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_eth_plat_data sh7757_eth_giga0_pdata = { - .phy = 18, - .set_mdio_gate = sh7757_eth_giga_set_mdio_gate, - .phy_interface = PHY_INTERFACE_MODE_RGMII_ID, -}; - -static struct platform_device sh7757_eth_giga0_device = { - .name = "sh7757-gether", - .resource = sh_eth_giga0_resources, - .id = 2, - .num_resources = ARRAY_SIZE(sh_eth_giga0_resources), - .dev = { - .platform_data = &sh7757_eth_giga0_pdata, - }, -}; - -static struct resource sh_eth_giga1_resources[] = { - { - .start = 0xfee00800, - .end = 0xfee00fff, - .flags = IORESOURCE_MEM, - }, { - /* TSU */ - .start = 0xfee01800, - .end = 0xfee01fff, - .flags = IORESOURCE_MEM, - }, { - .start = evt2irq(0x2980), - .end = evt2irq(0x2980), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_eth_plat_data sh7757_eth_giga1_pdata = { - .phy = 19, - .set_mdio_gate = sh7757_eth_giga_set_mdio_gate, - .phy_interface = PHY_INTERFACE_MODE_RGMII_ID, -}; - -static struct platform_device sh7757_eth_giga1_device = { - .name = "sh7757-gether", - .resource = sh_eth_giga1_resources, - .id = 3, - .num_resources = ARRAY_SIZE(sh_eth_giga1_resources), - .dev = { - .platform_data = &sh7757_eth_giga1_pdata, - }, -}; - -/* Fixed 3.3V regulator to be used by SDHI0, MMCIF */ -static struct regulator_consumer_supply fixed3v3_power_consumers[] = -{ - REGULATOR_SUPPLY("vmmc", "sh_mobile_sdhi.0"), - REGULATOR_SUPPLY("vqmmc", "sh_mobile_sdhi.0"), - REGULATOR_SUPPLY("vmmc", "sh_mmcif.0"), - REGULATOR_SUPPLY("vqmmc", "sh_mmcif.0"), -}; - -/* SH_MMCIF */ -static struct resource sh_mmcif_resources[] = { - [0] = { - .start = 0xffcb0000, - .end = 0xffcb00ff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x1c60), - .flags = IORESOURCE_IRQ, - }, - [2] = { - .start = evt2irq(0x1c80), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct sh_mmcif_plat_data sh_mmcif_plat = { - .sup_pclk = 0x0f, - .caps = MMC_CAP_4_BIT_DATA | MMC_CAP_8_BIT_DATA | - MMC_CAP_NONREMOVABLE, - .ocr = MMC_VDD_32_33 | MMC_VDD_33_34, - .slave_id_tx = SHDMA_SLAVE_MMCIF_TX, - .slave_id_rx = SHDMA_SLAVE_MMCIF_RX, -}; - -static struct platform_device sh_mmcif_device = { - .name = "sh_mmcif", - .id = 0, - .dev = { - .platform_data = &sh_mmcif_plat, - }, - .num_resources = ARRAY_SIZE(sh_mmcif_resources), - .resource = sh_mmcif_resources, -}; - -/* SDHI0 */ -static struct tmio_mmc_data sdhi_info = { - .chan_priv_tx = (void *)SHDMA_SLAVE_SDHI_TX, - .chan_priv_rx = (void *)SHDMA_SLAVE_SDHI_RX, - .capabilities = MMC_CAP_SD_HIGHSPEED, -}; - -static struct resource sdhi_resources[] = { - [0] = { - .start = 0xffe50000, - .end = 0xffe500ff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x480), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device sdhi_device = { - .name = "sh_mobile_sdhi", - .num_resources = ARRAY_SIZE(sdhi_resources), - .resource = sdhi_resources, - .id = 0, - .dev = { - .platform_data = &sdhi_info, - }, -}; - -static int usbhs0_get_id(struct platform_device *pdev) -{ - return USBHS_GADGET; -} - -static struct renesas_usbhs_platform_info usb0_data = { - .platform_callback = { - .get_id = usbhs0_get_id, - }, - .driver_param = { - .buswait_bwait = 5, - } -}; - -static struct resource usb0_resources[] = { - [0] = { - .start = 0xfe450000, - .end = 0xfe4501ff, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x840), - .end = evt2irq(0x840), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device usb0_device = { - .name = "renesas_usbhs", - .id = 0, - .dev = { - .platform_data = &usb0_data, - }, - .num_resources = ARRAY_SIZE(usb0_resources), - .resource = usb0_resources, -}; - -static struct platform_device *sh7757lcr_devices[] __initdata = { - &heartbeat_device, - &sh7757_eth0_device, - &sh7757_eth1_device, - &sh7757_eth_giga0_device, - &sh7757_eth_giga1_device, - &sh_mmcif_device, - &sdhi_device, - &usb0_device, -}; - -static struct flash_platform_data spi_flash_data = { - .name = "m25p80", - .type = "m25px64", -}; - -static struct spi_board_info spi_board_info[] = { - { - .modalias = "m25p80", - .max_speed_hz = 25000000, - .bus_num = 0, - .chip_select = 1, - .platform_data = &spi_flash_data, - }, -}; - -static int __init sh7757lcr_devices_setup(void) -{ - regulator_register_always_on(0, "fixed-3.3V", fixed3v3_power_consumers, - ARRAY_SIZE(fixed3v3_power_consumers), 3300000); - - /* RGMII (PTA) */ - gpio_request(GPIO_FN_ET0_MDC, NULL); - gpio_request(GPIO_FN_ET0_MDIO, NULL); - gpio_request(GPIO_FN_ET1_MDC, NULL); - gpio_request(GPIO_FN_ET1_MDIO, NULL); - - /* ONFI (PTB, PTZ) */ - gpio_request(GPIO_FN_ON_NRE, NULL); - gpio_request(GPIO_FN_ON_NWE, NULL); - gpio_request(GPIO_FN_ON_NWP, NULL); - gpio_request(GPIO_FN_ON_NCE0, NULL); - gpio_request(GPIO_FN_ON_R_B0, NULL); - gpio_request(GPIO_FN_ON_ALE, NULL); - gpio_request(GPIO_FN_ON_CLE, NULL); - - gpio_request(GPIO_FN_ON_DQ7, NULL); - gpio_request(GPIO_FN_ON_DQ6, NULL); - gpio_request(GPIO_FN_ON_DQ5, NULL); - gpio_request(GPIO_FN_ON_DQ4, NULL); - gpio_request(GPIO_FN_ON_DQ3, NULL); - gpio_request(GPIO_FN_ON_DQ2, NULL); - gpio_request(GPIO_FN_ON_DQ1, NULL); - gpio_request(GPIO_FN_ON_DQ0, NULL); - - /* IRQ8 to 0 (PTB, PTC) */ - gpio_request(GPIO_FN_IRQ8, NULL); - gpio_request(GPIO_FN_IRQ7, NULL); - gpio_request(GPIO_FN_IRQ6, NULL); - gpio_request(GPIO_FN_IRQ5, NULL); - gpio_request(GPIO_FN_IRQ4, NULL); - gpio_request(GPIO_FN_IRQ3, NULL); - gpio_request(GPIO_FN_IRQ2, NULL); - gpio_request(GPIO_FN_IRQ1, NULL); - gpio_request(GPIO_FN_IRQ0, NULL); - - /* SPI0 (PTD) */ - gpio_request(GPIO_FN_SP0_MOSI, NULL); - gpio_request(GPIO_FN_SP0_MISO, NULL); - gpio_request(GPIO_FN_SP0_SCK, NULL); - gpio_request(GPIO_FN_SP0_SCK_FB, NULL); - gpio_request(GPIO_FN_SP0_SS0, NULL); - gpio_request(GPIO_FN_SP0_SS1, NULL); - gpio_request(GPIO_FN_SP0_SS2, NULL); - gpio_request(GPIO_FN_SP0_SS3, NULL); - - /* RMII 0/1 (PTE, PTF) */ - gpio_request(GPIO_FN_RMII0_CRS_DV, NULL); - gpio_request(GPIO_FN_RMII0_TXD1, NULL); - gpio_request(GPIO_FN_RMII0_TXD0, NULL); - gpio_request(GPIO_FN_RMII0_TXEN, NULL); - gpio_request(GPIO_FN_RMII0_REFCLK, NULL); - gpio_request(GPIO_FN_RMII0_RXD1, NULL); - gpio_request(GPIO_FN_RMII0_RXD0, NULL); - gpio_request(GPIO_FN_RMII0_RX_ER, NULL); - gpio_request(GPIO_FN_RMII1_CRS_DV, NULL); - gpio_request(GPIO_FN_RMII1_TXD1, NULL); - gpio_request(GPIO_FN_RMII1_TXD0, NULL); - gpio_request(GPIO_FN_RMII1_TXEN, NULL); - gpio_request(GPIO_FN_RMII1_REFCLK, NULL); - gpio_request(GPIO_FN_RMII1_RXD1, NULL); - gpio_request(GPIO_FN_RMII1_RXD0, NULL); - gpio_request(GPIO_FN_RMII1_RX_ER, NULL); - - /* eMMC (PTG) */ - gpio_request(GPIO_FN_MMCCLK, NULL); - gpio_request(GPIO_FN_MMCCMD, NULL); - gpio_request(GPIO_FN_MMCDAT7, NULL); - gpio_request(GPIO_FN_MMCDAT6, NULL); - gpio_request(GPIO_FN_MMCDAT5, NULL); - gpio_request(GPIO_FN_MMCDAT4, NULL); - gpio_request(GPIO_FN_MMCDAT3, NULL); - gpio_request(GPIO_FN_MMCDAT2, NULL); - gpio_request(GPIO_FN_MMCDAT1, NULL); - gpio_request(GPIO_FN_MMCDAT0, NULL); - - /* LPC (PTG, PTH, PTQ, PTU) */ - gpio_request(GPIO_FN_SERIRQ, NULL); - gpio_request(GPIO_FN_LPCPD, NULL); - gpio_request(GPIO_FN_LDRQ, NULL); - gpio_request(GPIO_FN_WP, NULL); - gpio_request(GPIO_FN_FMS0, NULL); - gpio_request(GPIO_FN_LAD3, NULL); - gpio_request(GPIO_FN_LAD2, NULL); - gpio_request(GPIO_FN_LAD1, NULL); - gpio_request(GPIO_FN_LAD0, NULL); - gpio_request(GPIO_FN_LFRAME, NULL); - gpio_request(GPIO_FN_LRESET, NULL); - gpio_request(GPIO_FN_LCLK, NULL); - gpio_request(GPIO_FN_LGPIO7, NULL); - gpio_request(GPIO_FN_LGPIO6, NULL); - gpio_request(GPIO_FN_LGPIO5, NULL); - gpio_request(GPIO_FN_LGPIO4, NULL); - - /* SPI1 (PTH) */ - gpio_request(GPIO_FN_SP1_MOSI, NULL); - gpio_request(GPIO_FN_SP1_MISO, NULL); - gpio_request(GPIO_FN_SP1_SCK, NULL); - gpio_request(GPIO_FN_SP1_SCK_FB, NULL); - gpio_request(GPIO_FN_SP1_SS0, NULL); - gpio_request(GPIO_FN_SP1_SS1, NULL); - - /* SDHI (PTI) */ - gpio_request(GPIO_FN_SD_WP, NULL); - gpio_request(GPIO_FN_SD_CD, NULL); - gpio_request(GPIO_FN_SD_CLK, NULL); - gpio_request(GPIO_FN_SD_CMD, NULL); - gpio_request(GPIO_FN_SD_D3, NULL); - gpio_request(GPIO_FN_SD_D2, NULL); - gpio_request(GPIO_FN_SD_D1, NULL); - gpio_request(GPIO_FN_SD_D0, NULL); - - /* SCIF3/4 (PTJ, PTW) */ - gpio_request(GPIO_FN_RTS3, NULL); - gpio_request(GPIO_FN_CTS3, NULL); - gpio_request(GPIO_FN_TXD3, NULL); - gpio_request(GPIO_FN_RXD3, NULL); - gpio_request(GPIO_FN_RTS4, NULL); - gpio_request(GPIO_FN_RXD4, NULL); - gpio_request(GPIO_FN_TXD4, NULL); - gpio_request(GPIO_FN_CTS4, NULL); - - /* SERMUX (PTK, PTL, PTO, PTV) */ - gpio_request(GPIO_FN_COM2_TXD, NULL); - gpio_request(GPIO_FN_COM2_RXD, NULL); - gpio_request(GPIO_FN_COM2_RTS, NULL); - gpio_request(GPIO_FN_COM2_CTS, NULL); - gpio_request(GPIO_FN_COM2_DTR, NULL); - gpio_request(GPIO_FN_COM2_DSR, NULL); - gpio_request(GPIO_FN_COM2_DCD, NULL); - gpio_request(GPIO_FN_COM2_RI, NULL); - gpio_request(GPIO_FN_RAC_RXD, NULL); - gpio_request(GPIO_FN_RAC_RTS, NULL); - gpio_request(GPIO_FN_RAC_CTS, NULL); - gpio_request(GPIO_FN_RAC_DTR, NULL); - gpio_request(GPIO_FN_RAC_DSR, NULL); - gpio_request(GPIO_FN_RAC_DCD, NULL); - gpio_request(GPIO_FN_RAC_TXD, NULL); - gpio_request(GPIO_FN_COM1_TXD, NULL); - gpio_request(GPIO_FN_COM1_RXD, NULL); - gpio_request(GPIO_FN_COM1_RTS, NULL); - gpio_request(GPIO_FN_COM1_CTS, NULL); - - writeb(0x10, 0xfe470000); /* SMR0: SerMux mode 0 */ - - /* IIC (PTM, PTR, PTS) */ - gpio_request(GPIO_FN_SDA7, NULL); - gpio_request(GPIO_FN_SCL7, NULL); - gpio_request(GPIO_FN_SDA6, NULL); - gpio_request(GPIO_FN_SCL6, NULL); - gpio_request(GPIO_FN_SDA5, NULL); - gpio_request(GPIO_FN_SCL5, NULL); - gpio_request(GPIO_FN_SDA4, NULL); - gpio_request(GPIO_FN_SCL4, NULL); - gpio_request(GPIO_FN_SDA3, NULL); - gpio_request(GPIO_FN_SCL3, NULL); - gpio_request(GPIO_FN_SDA2, NULL); - gpio_request(GPIO_FN_SCL2, NULL); - gpio_request(GPIO_FN_SDA1, NULL); - gpio_request(GPIO_FN_SCL1, NULL); - gpio_request(GPIO_FN_SDA0, NULL); - gpio_request(GPIO_FN_SCL0, NULL); - - /* USB (PTN) */ - gpio_request(GPIO_FN_VBUS_EN, NULL); - gpio_request(GPIO_FN_VBUS_OC, NULL); - - /* SGPIO1/0 (PTN, PTO) */ - gpio_request(GPIO_FN_SGPIO1_CLK, NULL); - gpio_request(GPIO_FN_SGPIO1_LOAD, NULL); - gpio_request(GPIO_FN_SGPIO1_DI, NULL); - gpio_request(GPIO_FN_SGPIO1_DO, NULL); - gpio_request(GPIO_FN_SGPIO0_CLK, NULL); - gpio_request(GPIO_FN_SGPIO0_LOAD, NULL); - gpio_request(GPIO_FN_SGPIO0_DI, NULL); - gpio_request(GPIO_FN_SGPIO0_DO, NULL); - - /* WDT (PTN) */ - gpio_request(GPIO_FN_SUB_CLKIN, NULL); - - /* System (PTT) */ - gpio_request(GPIO_FN_STATUS1, NULL); - gpio_request(GPIO_FN_STATUS0, NULL); - - /* PWMX (PTT) */ - gpio_request(GPIO_FN_PWMX1, NULL); - gpio_request(GPIO_FN_PWMX0, NULL); - - /* R-SPI (PTV) */ - gpio_request(GPIO_FN_R_SPI_MOSI, NULL); - gpio_request(GPIO_FN_R_SPI_MISO, NULL); - gpio_request(GPIO_FN_R_SPI_RSPCK, NULL); - gpio_request(GPIO_FN_R_SPI_SSL0, NULL); - gpio_request(GPIO_FN_R_SPI_SSL1, NULL); - - /* EVC (PTV, PTW) */ - gpio_request(GPIO_FN_EVENT7, NULL); - gpio_request(GPIO_FN_EVENT6, NULL); - gpio_request(GPIO_FN_EVENT5, NULL); - gpio_request(GPIO_FN_EVENT4, NULL); - gpio_request(GPIO_FN_EVENT3, NULL); - gpio_request(GPIO_FN_EVENT2, NULL); - gpio_request(GPIO_FN_EVENT1, NULL); - gpio_request(GPIO_FN_EVENT0, NULL); - - /* LED for heartbeat */ - gpio_request(GPIO_PTU3, NULL); - gpio_direction_output(GPIO_PTU3, 1); - gpio_request(GPIO_PTU2, NULL); - gpio_direction_output(GPIO_PTU2, 1); - gpio_request(GPIO_PTU1, NULL); - gpio_direction_output(GPIO_PTU1, 1); - gpio_request(GPIO_PTU0, NULL); - gpio_direction_output(GPIO_PTU0, 1); - - /* control for MDIO of Gigabit Ethernet */ - gpio_request(GPIO_PTT4, NULL); - gpio_direction_output(GPIO_PTT4, 1); - - /* control for eMMC */ - gpio_request(GPIO_PTT7, NULL); /* eMMC_RST# */ - gpio_direction_output(GPIO_PTT7, 0); - gpio_request(GPIO_PTT6, NULL); /* eMMC_INDEX# */ - gpio_direction_output(GPIO_PTT6, 0); - gpio_request(GPIO_PTT5, NULL); /* eMMC_PRST# */ - gpio_direction_output(GPIO_PTT5, 1); - - /* register SPI device information */ - spi_register_board_info(spi_board_info, - ARRAY_SIZE(spi_board_info)); - - /* General platform */ - return platform_add_devices(sh7757lcr_devices, - ARRAY_SIZE(sh7757lcr_devices)); -} -arch_initcall(sh7757lcr_devices_setup); - -/* Initialize IRQ setting */ -void __init init_sh7757lcr_IRQ(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ7654); - plat_irq_setup_pins(IRQ_MODE_IRQ3210); -} - -/* Initialize the board */ -static void __init sh7757lcr_setup(char **cmdline_p) -{ - printk(KERN_INFO "Renesas R0P7757LC0012RL support.\n"); -} - -static int sh7757lcr_mode_pins(void) -{ - int value = 0; - - /* These are the factory default settings of S3 (Low active). - * If you change these dip switches then you will need to - * adjust the values below as well. - */ - value |= MODE_PIN0; /* Clock Mode: 1 */ - - return value; -} - -/* The Machine Vector */ -static struct sh_machine_vector mv_sh7757lcr __initmv = { - .mv_name = "SH7757LCR", - .mv_setup = sh7757lcr_setup, - .mv_init_irq = init_sh7757lcr_IRQ, - .mv_mode_pins = sh7757lcr_mode_pins, -}; - diff --git a/arch/sh/boards/board-sh7785lcr.c b/arch/sh/boards/board-sh7785lcr.c deleted file mode 100644 index 77dad1e511b465..00000000000000 --- a/arch/sh/boards/board-sh7785lcr.c +++ /dev/null @@ -1,384 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Renesas Technology Corp. R0P7785LC0011RL Support. - * - * Copyright (C) 2008 Yoshihiro Shimoda - * Copyright (C) 2009 Paul Mundt - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* - * NOTE: This board has 2 physical memory maps. - * Please look at include/asm-sh/sh7785lcr.h or hardware manual. - */ -static struct resource heartbeat_resource = { - .start = PLD_LEDCR, - .end = PLD_LEDCR, - .flags = IORESOURCE_MEM | IORESOURCE_MEM_8BIT, -}; - -static struct platform_device heartbeat_device = { - .name = "heartbeat", - .id = -1, - .num_resources = 1, - .resource = &heartbeat_resource, -}; - -static struct mtd_partition nor_flash_partitions[] = { - { - .name = "loader", - .offset = 0x00000000, - .size = 512 * 1024, - }, - { - .name = "bootenv", - .offset = MTDPART_OFS_APPEND, - .size = 512 * 1024, - }, - { - .name = "kernel", - .offset = MTDPART_OFS_APPEND, - .size = 4 * 1024 * 1024, - }, - { - .name = "data", - .offset = MTDPART_OFS_APPEND, - .size = MTDPART_SIZ_FULL, - }, -}; - -static struct physmap_flash_data nor_flash_data = { - .width = 4, - .parts = nor_flash_partitions, - .nr_parts = ARRAY_SIZE(nor_flash_partitions), -}; - -static struct resource nor_flash_resources[] = { - [0] = { - .start = NOR_FLASH_ADDR, - .end = NOR_FLASH_ADDR + NOR_FLASH_SIZE - 1, - .flags = IORESOURCE_MEM, - } -}; - -static struct platform_device nor_flash_device = { - .name = "physmap-flash", - .dev = { - .platform_data = &nor_flash_data, - }, - .num_resources = ARRAY_SIZE(nor_flash_resources), - .resource = nor_flash_resources, -}; - -static struct r8a66597_platdata r8a66597_data = { - .xtal = R8A66597_PLATDATA_XTAL_12MHZ, - .vif = 1, -}; - -static struct resource r8a66597_usb_host_resources[] = { - [0] = { - .start = R8A66597_ADDR, - .end = R8A66597_ADDR + R8A66597_SIZE - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x240), - .end = evt2irq(0x240), - .flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW, - }, -}; - -static struct platform_device r8a66597_usb_host_device = { - .name = "r8a66597_hcd", - .id = -1, - .dev = { - .dma_mask = NULL, - .coherent_dma_mask = 0xffffffff, - .platform_data = &r8a66597_data, - }, - .num_resources = ARRAY_SIZE(r8a66597_usb_host_resources), - .resource = r8a66597_usb_host_resources, -}; - -static struct resource sm501_resources[] = { - [0] = { - .start = SM107_MEM_ADDR, - .end = SM107_MEM_ADDR + SM107_MEM_SIZE - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = SM107_REG_ADDR, - .end = SM107_REG_ADDR + SM107_REG_SIZE - 1, - .flags = IORESOURCE_MEM, - }, - [2] = { - .start = evt2irq(0x340), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct fb_videomode sm501_default_mode_crt = { - .pixclock = 35714, /* 28MHz */ - .xres = 640, - .yres = 480, - .left_margin = 105, - .right_margin = 16, - .upper_margin = 33, - .lower_margin = 10, - .hsync_len = 39, - .vsync_len = 2, - .sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT, -}; - -static struct fb_videomode sm501_default_mode_pnl = { - .pixclock = 40000, /* 25MHz */ - .xres = 640, - .yres = 480, - .left_margin = 2, - .right_margin = 16, - .upper_margin = 33, - .lower_margin = 10, - .hsync_len = 39, - .vsync_len = 2, - .sync = 0, -}; - -static struct sm501_platdata_fbsub sm501_pdata_fbsub_pnl = { - .def_bpp = 16, - .def_mode = &sm501_default_mode_pnl, - .flags = SM501FB_FLAG_USE_INIT_MODE | - SM501FB_FLAG_USE_HWCURSOR | - SM501FB_FLAG_USE_HWACCEL | - SM501FB_FLAG_DISABLE_AT_EXIT | - SM501FB_FLAG_PANEL_NO_VBIASEN, -}; - -static struct sm501_platdata_fbsub sm501_pdata_fbsub_crt = { - .def_bpp = 16, - .def_mode = &sm501_default_mode_crt, - .flags = SM501FB_FLAG_USE_INIT_MODE | - SM501FB_FLAG_USE_HWCURSOR | - SM501FB_FLAG_USE_HWACCEL | - SM501FB_FLAG_DISABLE_AT_EXIT, -}; - -static struct sm501_platdata_fb sm501_fb_pdata = { - .fb_route = SM501_FB_OWN, - .fb_crt = &sm501_pdata_fbsub_crt, - .fb_pnl = &sm501_pdata_fbsub_pnl, -}; - -static struct sm501_initdata sm501_initdata = { - .gpio_high = { - .set = 0x00001fe0, - .mask = 0x0, - }, - .devices = 0, - .mclk = 84 * 1000000, - .m1xclk = 112 * 1000000, -}; - -static struct sm501_platdata sm501_platform_data = { - .init = &sm501_initdata, - .fb = &sm501_fb_pdata, -}; - -static struct platform_device sm501_device = { - .name = "sm501", - .id = -1, - .dev = { - .platform_data = &sm501_platform_data, - }, - .num_resources = ARRAY_SIZE(sm501_resources), - .resource = sm501_resources, -}; - -static struct resource i2c_proto_resources[] = { - [0] = { - .start = PCA9564_PROTO_32BIT_ADDR, - .end = PCA9564_PROTO_32BIT_ADDR + PCA9564_SIZE - 1, - .flags = IORESOURCE_MEM | IORESOURCE_MEM_8BIT, - }, - [1] = { - .start = evt2irq(0x380), - .end = evt2irq(0x380), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct resource i2c_resources[] = { - [0] = { - .start = PCA9564_ADDR, - .end = PCA9564_ADDR + PCA9564_SIZE - 1, - .flags = IORESOURCE_MEM | IORESOURCE_MEM_8BIT, - }, - [1] = { - .start = evt2irq(0x380), - .end = evt2irq(0x380), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct gpiod_lookup_table i2c_gpio_table = { - .dev_id = "i2c.0", - .table = { - GPIO_LOOKUP("pfc-sh7757", 0, "reset-gpios", GPIO_ACTIVE_LOW), - { }, - }, -}; - -static struct i2c_pca9564_pf_platform_data i2c_platform_data = { - .i2c_clock_speed = I2C_PCA_CON_330kHz, - .timeout = HZ, -}; - -static struct platform_device i2c_device = { - .name = "i2c-pca-platform", - .id = -1, - .dev = { - .platform_data = &i2c_platform_data, - }, - .num_resources = ARRAY_SIZE(i2c_resources), - .resource = i2c_resources, -}; - -static struct platform_device *sh7785lcr_devices[] __initdata = { - &heartbeat_device, - &nor_flash_device, - &r8a66597_usb_host_device, - &sm501_device, - &i2c_device, -}; - -static struct i2c_board_info __initdata sh7785lcr_i2c_devices[] = { - { - I2C_BOARD_INFO("r2025sd", 0x32), - }, -}; - -static int __init sh7785lcr_devices_setup(void) -{ - i2c_register_board_info(0, sh7785lcr_i2c_devices, - ARRAY_SIZE(sh7785lcr_i2c_devices)); - - if (mach_is_sh7785lcr_pt()) { - i2c_device.resource = i2c_proto_resources; - i2c_device.num_resources = ARRAY_SIZE(i2c_proto_resources); - } - - gpiod_add_lookup_table(&i2c_gpio_table); - return platform_add_devices(sh7785lcr_devices, - ARRAY_SIZE(sh7785lcr_devices)); -} -device_initcall(sh7785lcr_devices_setup); - -/* Initialize IRQ setting */ -void __init init_sh7785lcr_IRQ(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRQ7654); - plat_irq_setup_pins(IRQ_MODE_IRQ3210); -} - -static int sh7785lcr_clk_init(void) -{ - struct clk *clk; - int ret; - - clk = clk_get(NULL, "extal"); - if (IS_ERR(clk)) - return PTR_ERR(clk); - ret = clk_set_rate(clk, 33333333); - clk_put(clk); - - return ret; -} - -static void sh7785lcr_power_off(void) -{ - unsigned char *p; - - p = ioremap(PLD_POFCR, PLD_POFCR + 1); - if (!p) { - printk(KERN_ERR "%s: ioremap error.\n", __func__); - return; - } - *p = 0x01; - iounmap(p); - set_bl_bit(); - while (1) - cpu_relax(); -} - -/* Initialize the board */ -static void __init sh7785lcr_setup(char **cmdline_p) -{ - void __iomem *sm501_reg; - - printk(KERN_INFO "Renesas Technology Corp. R0P7785LC0011RL support.\n"); - - pm_power_off = sh7785lcr_power_off; - - /* sm501 DRAM configuration */ - sm501_reg = ioremap(SM107_REG_ADDR, SM501_DRAM_CONTROL); - if (!sm501_reg) { - printk(KERN_ERR "%s: ioremap error.\n", __func__); - return; - } - - writel(0x000307c2, sm501_reg + SM501_DRAM_CONTROL); - iounmap(sm501_reg); -} - -/* Return the board specific boot mode pin configuration */ -static int sh7785lcr_mode_pins(void) -{ - int value = 0; - - /* These are the factory default settings of S1 and S2. - * If you change these dip switches then you will need to - * adjust the values below as well. - */ - value |= MODE_PIN4; /* Clock Mode 16 */ - value |= MODE_PIN5; /* 32-bit Area0 bus width */ - value |= MODE_PIN6; /* 32-bit Area0 bus width */ - value |= MODE_PIN7; /* Area 0 SRAM interface [fixed] */ - value |= MODE_PIN8; /* Little Endian */ - value |= MODE_PIN9; /* Master Mode */ - value |= MODE_PIN14; /* No PLL step-up */ - - return value; -} - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_sh7785lcr __initmv = { - .mv_name = "SH7785LCR", - .mv_setup = sh7785lcr_setup, - .mv_clk_init = sh7785lcr_clk_init, - .mv_init_irq = init_sh7785lcr_IRQ, - .mv_mode_pins = sh7785lcr_mode_pins, -}; - diff --git a/arch/sh/boards/board-shmin.c b/arch/sh/boards/board-shmin.c deleted file mode 100644 index 83296c0b75c45d..00000000000000 --- a/arch/sh/boards/board-shmin.c +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * arch/sh/boards/shmin/setup.c - * - * Copyright (C) 2006 Takashi YOSHII - * - * SHMIN Support. - */ -#include -#include -#include -#include -#include -#include - -#define PFC_PHCR 0xa400010eUL -#define INTC_ICR1 0xa4000010UL - -static void __init init_shmin_irq(void) -{ - __raw_writew(0x2a00, PFC_PHCR); // IRQ0-3=IRQ - __raw_writew(0x0aaa, INTC_ICR1); // IRQ0-3=IRQ-mode,Low-active. - plat_irq_setup_pins(IRQ_MODE_IRQ); -} - -static void __init shmin_setup(char **cmdline_p) -{ - __set_io_port_base(SHMIN_IO_BASE); -} - -static struct sh_machine_vector mv_shmin __initmv = { - .mv_name = "SHMIN", - .mv_setup = shmin_setup, - .mv_init_irq = init_shmin_irq, -}; diff --git a/arch/sh/boards/board-titan.c b/arch/sh/boards/board-titan.c deleted file mode 100644 index 074a848d8b564d..00000000000000 --- a/arch/sh/boards/board-titan.c +++ /dev/null @@ -1,21 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * arch/sh/boards/titan/setup.c - Setup for Titan - * - * Copyright (C) 2006 Jamie Lenehan - */ -#include -#include -#include -#include - -static void __init init_titan_irq(void) -{ - /* enable individual interrupt mode for externals */ - plat_irq_setup_pins(IRQ_MODE_IRQ); -} - -static struct sh_machine_vector mv_titan __initmv = { - .mv_name = "Titan", - .mv_init_irq = init_titan_irq, -}; diff --git a/arch/sh/boards/board-urquell.c b/arch/sh/boards/board-urquell.c deleted file mode 100644 index dad2b3b40735cb..00000000000000 --- a/arch/sh/boards/board-urquell.c +++ /dev/null @@ -1,218 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Renesas Technology Corp. SH7786 Urquell Support. - * - * Copyright (C) 2008 Kuninori Morimoto - * Copyright (C) 2009, 2010 Paul Mundt - * - * Based on board-sh7785lcr.c - * Copyright (C) 2008 Yoshihiro Shimoda - */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* - * bit 1234 5678 - *---------------------------- - * SW1 0101 0010 -> Pck 33MHz version - * (1101 0010) Pck 66MHz version - * SW2 0x1x xxxx -> little endian - * 29bit mode - * SW47 0001 1000 -> CS0 : on-board flash - * CS1 : SRAM, registers, LAN, PCMCIA - * 38400 bps for SCIF1 - * - * Address - * 0x00000000 - 0x04000000 (CS0) Nor Flash - * 0x04000000 - 0x04200000 (CS1) SRAM - * 0x05000000 - 0x05800000 (CS1) on board register - * 0x05800000 - 0x06000000 (CS1) LAN91C111 - * 0x06000000 - 0x06400000 (CS1) PCMCIA - * 0x08000000 - 0x10000000 (CS2-CS3) DDR3 - * 0x10000000 - 0x14000000 (CS4) PCIe - * 0x14000000 - 0x14800000 (CS5) Core0 LRAM/URAM - * 0x14800000 - 0x15000000 (CS5) Core1 LRAM/URAM - * 0x18000000 - 0x1C000000 (CS6) ATA/NAND-Flash - * 0x1C000000 - (CS7) SH7786 Control register - */ - -/* HeartBeat */ -static struct resource heartbeat_resource = { - .start = BOARDREG(SLEDR), - .end = BOARDREG(SLEDR), - .flags = IORESOURCE_MEM | IORESOURCE_MEM_16BIT, -}; - -static struct platform_device heartbeat_device = { - .name = "heartbeat", - .id = -1, - .num_resources = 1, - .resource = &heartbeat_resource, -}; - -/* LAN91C111 */ -static struct smc91x_platdata smc91x_info = { - .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, -}; - -static struct resource smc91x_eth_resources[] = { - [0] = { - .name = "SMC91C111" , - .start = 0x05800300, - .end = 0x0580030f, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = evt2irq(0x360), - .flags = IORESOURCE_IRQ, - }, -}; - -static struct platform_device smc91x_eth_device = { - .name = "smc91x", - .num_resources = ARRAY_SIZE(smc91x_eth_resources), - .resource = smc91x_eth_resources, - .dev = { - .platform_data = &smc91x_info, - }, -}; - -/* Nor Flash */ -static struct mtd_partition nor_flash_partitions[] = { - { - .name = "loader", - .offset = 0x00000000, - .size = SZ_512K, - .mask_flags = MTD_WRITEABLE, /* Read-only */ - }, - { - .name = "bootenv", - .offset = MTDPART_OFS_APPEND, - .size = SZ_512K, - .mask_flags = MTD_WRITEABLE, /* Read-only */ - }, - { - .name = "kernel", - .offset = MTDPART_OFS_APPEND, - .size = SZ_4M, - }, - { - .name = "data", - .offset = MTDPART_OFS_APPEND, - .size = MTDPART_SIZ_FULL, - }, -}; - -static struct physmap_flash_data nor_flash_data = { - .width = 2, - .parts = nor_flash_partitions, - .nr_parts = ARRAY_SIZE(nor_flash_partitions), -}; - -static struct resource nor_flash_resources[] = { - [0] = { - .start = NOR_FLASH_ADDR, - .end = NOR_FLASH_ADDR + NOR_FLASH_SIZE - 1, - .flags = IORESOURCE_MEM, - } -}; - -static struct platform_device nor_flash_device = { - .name = "physmap-flash", - .dev = { - .platform_data = &nor_flash_data, - }, - .num_resources = ARRAY_SIZE(nor_flash_resources), - .resource = nor_flash_resources, -}; - -static struct platform_device *urquell_devices[] __initdata = { - &heartbeat_device, - &smc91x_eth_device, - &nor_flash_device, -}; - -static int __init urquell_devices_setup(void) -{ - /* USB */ - gpio_request(GPIO_FN_USB_OVC0, NULL); - gpio_request(GPIO_FN_USB_PENC0, NULL); - - /* enable LAN */ - __raw_writew(__raw_readw(UBOARDREG(IRL2MSKR)) & ~0x00000001, - UBOARDREG(IRL2MSKR)); - - return platform_add_devices(urquell_devices, - ARRAY_SIZE(urquell_devices)); -} -device_initcall(urquell_devices_setup); - -static void urquell_power_off(void) -{ - __raw_writew(0xa5a5, UBOARDREG(SRSTR)); -} - -static void __init urquell_init_irq(void) -{ - plat_irq_setup_pins(IRQ_MODE_IRL3210_MASK); -} - -static int urquell_mode_pins(void) -{ - return __raw_readw(UBOARDREG(MDSWMR)); -} - -static int urquell_clk_init(void) -{ - struct clk *clk; - int ret; - - /* - * Only handle the EXTAL case, anyone interfacing a crystal - * resonator will need to provide their own input clock. - */ - if (test_mode_pin(MODE_PIN9)) - return -EINVAL; - - clk = clk_get(NULL, "extal"); - if (IS_ERR(clk)) - return PTR_ERR(clk); - ret = clk_set_rate(clk, 33333333); - clk_put(clk); - - return ret; -} - -/* Initialize the board */ -static void __init urquell_setup(char **cmdline_p) -{ - printk(KERN_INFO "Renesas Technology Corp. Urquell support.\n"); - - pm_power_off = urquell_power_off; - - register_smp_ops(&shx3_smp_ops); -} - -/* - * The Machine Vector - */ -static struct sh_machine_vector mv_urquell __initmv = { - .mv_name = "Urquell", - .mv_setup = urquell_setup, - .mv_init_irq = urquell_init_irq, - .mv_mode_pins = urquell_mode_pins, - .mv_clk_init = urquell_clk_init, -}; diff --git a/arch/sh/boards/mach-ap325rxa/Makefile b/arch/sh/boards/mach-ap325rxa/Makefile deleted file mode 100644 index dba5d0c202615a..00000000000000 --- a/arch/sh/boards/mach-ap325rxa/Makefile +++ /dev/null @@ -1,3 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -obj-y := setup.o sdram.o - diff --git a/arch/sh/boards/mach-ap325rxa/sdram.S b/arch/sh/boards/mach-ap325rxa/sdram.S deleted file mode 100644 index 541c82cc30b112..00000000000000 --- a/arch/sh/boards/mach-ap325rxa/sdram.S +++ /dev/null @@ -1,66 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 - * - * AP325RXA sdram self/auto-refresh setup code - * - * Copyright (C) 2009 Magnus Damm - */ - -#include -#include -#include -#include -#include -#include - -/* code to enter and leave self-refresh. must be self-contained. - * this code will be copied to on-chip memory and executed from there. - */ - .balign 4 -ENTRY(ap325rxa_sdram_enter_start) - - /* SBSC: disable power down and put in self-refresh mode */ - mov.l 1f, r4 - mov.l 2f, r1 - mov.l @r4, r2 - or r1, r2 - mov.l 3f, r3 - and r3, r2 - mov.l r2, @r4 - - rts - nop - - .balign 4 -1: .long 0xfe400008 /* SDCR0 */ -2: .long 0x00000400 -3: .long 0xffff7fff -ENTRY(ap325rxa_sdram_enter_end) - - .balign 4 -ENTRY(ap325rxa_sdram_leave_start) - - /* SBSC: set auto-refresh mode */ - mov.l 1f, r4 - mov.l @r4, r0 - mov.l 4f, r1 - and r1, r0 - mov.l r0, @r4 - mov.l 6f, r4 - mov.l 8f, r0 - mov.l @r4, r1 - mov #-1, r4 - add r4, r1 - or r1, r0 - mov.l 7f, r1 - mov.l r0, @r1 - - rts - nop - - .balign 4 -1: .long 0xfe400008 /* SDCR0 */ -4: .long 0xfffffbff -6: .long 0xfe40001c /* RTCOR */ -7: .long 0xfe400018 /* RTCNT */ -8: .long 0xa55a0000 -ENTRY(ap325rxa_sdram_leave_end) diff --git a/arch/sh/boards/mach-ap325rxa/setup.c b/arch/sh/boards/mach-ap325rxa/setup.c deleted file mode 100644 index c77b5f00a66a3d..00000000000000 --- a/arch/sh/boards/mach-ap325rxa/setup.c +++ /dev/null @@ -1,573 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Renesas - AP-325RXA - * (Compatible with Algo System ., LTD. - AP-320A) - * - * Copyright (C) 2008 Renesas Solutions Corp. - * Author : Yusuke Goda - */ - -#include -#include -#include - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -#include