mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-21 21:53:28 +07: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>
75 lines
2.5 KiB
C
75 lines
2.5 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_OFFSETS_H
|
|
#define __SOLO6X10_OFFSETS_H
|
|
|
|
#define SOLO_DISP_EXT_ADDR 0x00000000
|
|
#define SOLO_DISP_EXT_SIZE 0x00480000
|
|
|
|
#define SOLO_EOSD_EXT_ADDR \
|
|
(SOLO_DISP_EXT_ADDR + SOLO_DISP_EXT_SIZE)
|
|
#define SOLO_EOSD_EXT_SIZE(__solo) \
|
|
(__solo->type == SOLO_DEV_6010 ? 0x10000 : 0x20000)
|
|
#define SOLO_EOSD_EXT_SIZE_MAX 0x20000
|
|
#define SOLO_EOSD_EXT_AREA(__solo) \
|
|
(SOLO_EOSD_EXT_SIZE(__solo) * 32)
|
|
#define SOLO_EOSD_EXT_ADDR_CHAN(__solo, ch) \
|
|
(SOLO_EOSD_EXT_ADDR + SOLO_EOSD_EXT_SIZE(__solo) * (ch))
|
|
|
|
#define SOLO_MOTION_EXT_ADDR(__solo) \
|
|
(SOLO_EOSD_EXT_ADDR + SOLO_EOSD_EXT_AREA(__solo))
|
|
#define SOLO_MOTION_EXT_SIZE 0x00080000
|
|
|
|
#define SOLO_G723_EXT_ADDR(__solo) \
|
|
(SOLO_MOTION_EXT_ADDR(__solo) + SOLO_MOTION_EXT_SIZE)
|
|
#define SOLO_G723_EXT_SIZE 0x00010000
|
|
|
|
#define SOLO_CAP_EXT_ADDR(__solo) \
|
|
(SOLO_G723_EXT_ADDR(__solo) + SOLO_G723_EXT_SIZE)
|
|
|
|
/* 18 is the maximum number of pages required for PAL@D1, the largest frame
|
|
* possible */
|
|
#define SOLO_CAP_PAGE_SIZE (18 << 16)
|
|
|
|
/* Always allow the encoder enough for 16 channels, even if we have less. The
|
|
* exception is if we have card with only 32Megs of memory. */
|
|
#define SOLO_CAP_EXT_SIZE(__solo) \
|
|
((((__solo->sdram_size <= (32 << 20)) ? 4 : 16) + 1) \
|
|
* SOLO_CAP_PAGE_SIZE)
|
|
|
|
#define SOLO_EREF_EXT_ADDR(__solo) \
|
|
(SOLO_CAP_EXT_ADDR(__solo) + SOLO_CAP_EXT_SIZE(__solo))
|
|
#define SOLO_EREF_EXT_SIZE 0x00140000
|
|
#define SOLO_EREF_EXT_AREA(__solo) \
|
|
(SOLO_EREF_EXT_SIZE * __solo->nr_chans * 2)
|
|
|
|
#define __SOLO_JPEG_MIN_SIZE(__solo) (__solo->nr_chans * 0x00080000)
|
|
|
|
#define SOLO_MP4E_EXT_ADDR(__solo) \
|
|
(SOLO_EREF_EXT_ADDR(__solo) + SOLO_EREF_EXT_AREA(__solo))
|
|
#define SOLO_MP4E_EXT_SIZE(__solo) \
|
|
max((__solo->nr_chans * 0x00080000), \
|
|
min(((__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo)) - \
|
|
__SOLO_JPEG_MIN_SIZE(__solo)), 0x00ff0000))
|
|
|
|
#define __SOLO_JPEG_MIN_SIZE(__solo) (__solo->nr_chans * 0x00080000)
|
|
#define SOLO_JPEG_EXT_ADDR(__solo) \
|
|
(SOLO_MP4E_EXT_ADDR(__solo) + SOLO_MP4E_EXT_SIZE(__solo))
|
|
#define SOLO_JPEG_EXT_SIZE(__solo) \
|
|
max(__SOLO_JPEG_MIN_SIZE(__solo), \
|
|
min((__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo)), 0x00ff0000))
|
|
|
|
#define SOLO_SDRAM_END(__solo) \
|
|
(SOLO_JPEG_EXT_ADDR(__solo) + SOLO_JPEG_EXT_SIZE(__solo))
|
|
|
|
#endif /* __SOLO6X10_OFFSETS_H */
|