sh: hp6xx mach-type cleanups.
Some minor cleanups for the updated consolidated hp6xx mach-type. Signed-off-by: Andriy Skulysh <askulysh@gmail.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
parent
e4c2cfee5d
commit
4bcac20a7a
@ -113,7 +113,7 @@ incdir-$(CONFIG_SH_SOLUTION_ENGINE) := se
|
|||||||
incdir-$(CONFIG_SH_7751_SOLUTION_ENGINE) := se7751
|
incdir-$(CONFIG_SH_7751_SOLUTION_ENGINE) := se7751
|
||||||
incdir-$(CONFIG_SH_7300_SOLUTION_ENGINE) := se7300
|
incdir-$(CONFIG_SH_7300_SOLUTION_ENGINE) := se7300
|
||||||
incdir-$(CONFIG_SH_73180_SOLUTION_ENGINE) := se73180
|
incdir-$(CONFIG_SH_73180_SOLUTION_ENGINE) := se73180
|
||||||
incdir-$(CONFIG_SH_HP600) := hp6xx
|
incdir-$(CONFIG_SH_HP6XX) := hp6xx
|
||||||
|
|
||||||
ifneq ($(machdir-y),)
|
ifneq ($(machdir-y),)
|
||||||
core-y += arch/sh/boards/$(machdir-y)/
|
core-y += arch/sh/boards/$(machdir-y)/
|
||||||
|
@ -28,10 +28,8 @@
|
|||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/hd64461/hd64461.h>
|
#include <asm/hd64461/hd64461.h>
|
||||||
|
|
||||||
#ifdef MACH_HP600
|
|
||||||
#include <asm/cpu/dac.h>
|
#include <asm/cpu/dac.h>
|
||||||
#include <asm/hp6xx/hp6xx.h>
|
#include <asm/hp6xx/hp6xx.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#define WIDTH 640
|
#define WIDTH 640
|
||||||
|
|
||||||
@ -192,12 +190,6 @@ int hitfb_blank(int blank_mode, struct fb_info *info)
|
|||||||
unsigned short v;
|
unsigned short v;
|
||||||
|
|
||||||
if (blank_mode) {
|
if (blank_mode) {
|
||||||
#ifdef MACH_HP600
|
|
||||||
sh_dac_disable(DAC_LCD_BRIGHTNESS);
|
|
||||||
v = fb_readw(HD64461_GPBDR);
|
|
||||||
v |= HD64461_GPBDR_LCDOFF;
|
|
||||||
fb_writew(v, HD64461_GPBDR);
|
|
||||||
#endif
|
|
||||||
v = fb_readw(HD64461_LDR1);
|
v = fb_readw(HD64461_LDR1);
|
||||||
v &= ~HD64461_LDR1_DON;
|
v &= ~HD64461_LDR1_DON;
|
||||||
fb_writew(v, HD64461_LDR1);
|
fb_writew(v, HD64461_LDR1);
|
||||||
@ -213,12 +205,7 @@ int hitfb_blank(int blank_mode, struct fb_info *info)
|
|||||||
v = fb_readw(HD64461_STBCR);
|
v = fb_readw(HD64461_STBCR);
|
||||||
v &= ~HD64461_STBCR_SLCDST;
|
v &= ~HD64461_STBCR_SLCDST;
|
||||||
fb_writew(v, HD64461_STBCR);
|
fb_writew(v, HD64461_STBCR);
|
||||||
#ifdef MACH_HP600
|
|
||||||
sh_dac_enable(DAC_LCD_BRIGHTNESS);
|
|
||||||
v = fb_readw(HD64461_GPBDR);
|
|
||||||
v &= ~HD64461_GPBDR_LCDOFF;
|
|
||||||
fb_writew(v, HD64461_GPBDR);
|
|
||||||
#endif
|
|
||||||
v = fb_readw(HD64461_LDR1);
|
v = fb_readw(HD64461_LDR1);
|
||||||
v |= HD64461_LDR1_DON;
|
v |= HD64461_LDR1_DON;
|
||||||
fb_writew(v, HD64461_LDR1);
|
fb_writew(v, HD64461_LDR1);
|
||||||
|
@ -6,18 +6,15 @@
|
|||||||
#include <linux/fs.h>
|
#include <linux/fs.h>
|
||||||
#include <linux/sound.h>
|
#include <linux/sound.h>
|
||||||
#include <linux/soundcard.h>
|
#include <linux/soundcard.h>
|
||||||
|
#include <linux/interrupt.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/uaccess.h>
|
#include <asm/uaccess.h>
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
#include <asm/delay.h>
|
#include <asm/delay.h>
|
||||||
#include <linux/interrupt.h>
|
|
||||||
|
|
||||||
#include <asm/cpu/dac.h>
|
#include <asm/cpu/dac.h>
|
||||||
|
#include <asm/machvec.h>
|
||||||
#ifdef MACH_HP600
|
|
||||||
#include <asm/hp6xx/hp6xx.h>
|
#include <asm/hp6xx/hp6xx.h>
|
||||||
#include <asm/hd64461/hd64461.h>
|
#include <asm/hd64461/hd64461.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#define MODNAME "sh_dac_audio"
|
#define MODNAME "sh_dac_audio"
|
||||||
|
|
||||||
@ -71,26 +68,25 @@ static void dac_audio_sync(void)
|
|||||||
|
|
||||||
static void dac_audio_start(void)
|
static void dac_audio_start(void)
|
||||||
{
|
{
|
||||||
#ifdef MACH_HP600
|
if (mach_is_hp6xx()) {
|
||||||
u16 v;
|
u16 v = inw(HD64461_GPADR);
|
||||||
v = inw(HD64461_GPADR);
|
v &= ~HD64461_GPADR_SPEAKER;
|
||||||
v &= ~HD64461_GPADR_SPEAKER;
|
outw(v, HD64461_GPADR);
|
||||||
outw(v, HD64461_GPADR);
|
}
|
||||||
#endif
|
|
||||||
sh_dac_enable(CONFIG_SOUND_SH_DAC_AUDIO_CHANNEL);
|
sh_dac_enable(CONFIG_SOUND_SH_DAC_AUDIO_CHANNEL);
|
||||||
ctrl_outw(TMU1_TCR_INIT, TMU1_TCR);
|
ctrl_outw(TMU1_TCR_INIT, TMU1_TCR);
|
||||||
}
|
}
|
||||||
static void dac_audio_stop(void)
|
static void dac_audio_stop(void)
|
||||||
{
|
{
|
||||||
#ifdef MACH_HP600
|
|
||||||
u16 v;
|
|
||||||
#endif
|
|
||||||
dac_audio_stop_timer();
|
dac_audio_stop_timer();
|
||||||
#ifdef MACH_HP600
|
|
||||||
v = inw(HD64461_GPADR);
|
if (mach_is_hp6xx()) {
|
||||||
v |= HD64461_GPADR_SPEAKER;
|
u16 v = inw(HD64461_GPADR);
|
||||||
outw(v, HD64461_GPADR);
|
v |= HD64461_GPADR_SPEAKER;
|
||||||
#endif
|
outw(v, HD64461_GPADR);
|
||||||
|
}
|
||||||
|
|
||||||
sh_dac_disable(CONFIG_SOUND_SH_DAC_AUDIO_CHANNEL);
|
sh_dac_disable(CONFIG_SOUND_SH_DAC_AUDIO_CHANNEL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user