mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-29 23:24:11 +08:00
c942fddf87
Based on 3 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation either version 2 of the license or at your option any later version this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation either version 2 of the license or at your option any later version [author] [kishon] [vijay] [abraham] [i] [kishon]@[ti] [com] this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation either version 2 of the license or at your option any later version [author] [graeme] [gregory] [gg]@[slimlogic] [co] [uk] [author] [kishon] [vijay] [abraham] [i] [kishon]@[ti] [com] [based] [on] [twl6030]_[usb] [c] [author] [hema] [hk] [hemahk]@[ti] [com] this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details extracted by the scancode license scanner the SPDX license identifier GPL-2.0-or-later has been chosen to replace the boilerplate/reference in 1105 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Richard Fontana <rfontana@redhat.com> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190527070033.202006027@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
57 lines
1.8 KiB
C
57 lines
1.8 KiB
C
/* SPDX-License-Identifier: GPL-2.0-or-later */
|
|
/*
|
|
* Copyright (C) 2010-2013 Bluecherry, LLC <http://www.bluecherrydvr.com>
|
|
*
|
|
* Original author:
|
|
* Ben Collins <bcollins@ubuntu.com>
|
|
*
|
|
* Additional work by:
|
|
* John Brooks <john.brooks@bluecherry.net>
|
|
*/
|
|
|
|
#ifndef __SOLO6X10_TW28_H
|
|
#define __SOLO6X10_TW28_H
|
|
|
|
#include "solo6x10.h"
|
|
|
|
#define TW_NUM_CHIP 4
|
|
#define TW_BASE_ADDR 0x28
|
|
#define TW_CHIP_OFFSET_ADDR(n) (TW_BASE_ADDR + (n))
|
|
|
|
/* tw2815 */
|
|
#define TW_AV_STAT_ADDR 0x5a
|
|
#define TW_HUE_ADDR(n) (0x07 | ((n) << 4))
|
|
#define TW_SATURATION_ADDR(n) (0x08 | ((n) << 4))
|
|
#define TW_CONTRAST_ADDR(n) (0x09 | ((n) << 4))
|
|
#define TW_BRIGHTNESS_ADDR(n) (0x0a | ((n) << 4))
|
|
#define TW_AUDIO_OUTPUT_VOL_ADDR 0x70
|
|
#define TW_AUDIO_INPUT_GAIN_ADDR(n) (0x60 + ((n > 1) ? 1 : 0))
|
|
|
|
/* tw286x */
|
|
#define TW286x_AV_STAT_ADDR 0xfd
|
|
#define TW286x_HUE_ADDR(n) (0x06 | ((n) << 4))
|
|
#define TW286x_SATURATIONU_ADDR(n) (0x04 | ((n) << 4))
|
|
#define TW286x_SATURATIONV_ADDR(n) (0x05 | ((n) << 4))
|
|
#define TW286x_CONTRAST_ADDR(n) (0x02 | ((n) << 4))
|
|
#define TW286x_BRIGHTNESS_ADDR(n) (0x01 | ((n) << 4))
|
|
#define TW286x_SHARPNESS(n) (0x03 | ((n) << 4))
|
|
#define TW286x_AUDIO_OUTPUT_VOL_ADDR 0xdf
|
|
#define TW286x_AUDIO_INPUT_GAIN_ADDR(n) (0xD0 + ((n > 1) ? 1 : 0))
|
|
|
|
int solo_tw28_init(struct solo_dev *solo_dev);
|
|
|
|
int tw28_set_ctrl_val(struct solo_dev *solo_dev, u32 ctrl, u8 ch, s32 val);
|
|
int tw28_get_ctrl_val(struct solo_dev *solo_dev, u32 ctrl, u8 ch, s32 *val);
|
|
bool tw28_has_sharpness(struct solo_dev *solo_dev, u8 ch);
|
|
|
|
u8 tw28_get_audio_gain(struct solo_dev *solo_dev, u8 ch);
|
|
void tw28_set_audio_gain(struct solo_dev *solo_dev, u8 ch, u8 val);
|
|
int tw28_get_video_status(struct solo_dev *solo_dev, u8 ch);
|
|
|
|
#if 0
|
|
unsigned int tw2815_get_audio_status(struct SOLO *solo);
|
|
void tw2815_Set_AudioOutVol(struct SOLO *solo, unsigned int u_val);
|
|
#endif
|
|
|
|
#endif /* __SOLO6X10_TW28_H */
|