cregit-Linux how code gets into the kernel

Release 4.18 drivers/staging/sm750fb/ddk750_chip.h

/* SPDX-License-Identifier: GPL-2.0 */
#ifndef DDK750_CHIP_H__

#define DDK750_CHIP_H__

#define DEFAULT_INPUT_CLOCK 14318181 
/* Default reference clock */
#ifndef SM750LE_REVISION_ID

#define SM750LE_REVISION_ID ((unsigned char)0xfe)
#endif

#include <linux/io.h>
#include <linux/ioport.h>
#include <linux/uaccess.h>

extern void __iomem *mmio750;

/* software control endianness */

static inline u32 peek32(u32 addr) { return readl(addr + mmio750); }

Contributors

PersonTokensPropCommitsCommitProp
Matthieu Simon1477.78%150.00%
Elise Lennion422.22%150.00%
Total18100.00%2100.00%


static inline void poke32(u32 addr, u32 data) { writel(data, addr + mmio750); }

Contributors

PersonTokensPropCommitsCommitProp
Matthieu Simon1881.82%133.33%
Elise Lennion29.09%133.33%
Huacai Chen29.09%133.33%
Total22100.00%3100.00%

/* This is all the chips recognized by this library */ enum logical_chip_type { SM_UNKNOWN, SM718, SM750, SM750LE, }; enum clock_type { MXCLK_PLL, PRIMARY_PLL, SECONDARY_PLL, VGA0_PLL, VGA1_PLL, }; struct pll_value { enum clock_type clockType; unsigned long inputFreq; /* Input clock frequency to the PLL */ /* Use this when clockType = PANEL_PLL */ unsigned long M; unsigned long N; unsigned long OD; unsigned long POD; }; /* input struct to initChipParam() function */ struct initchip_param { /* Use power mode 0 or 1 */ unsigned short powerMode; /* * Speed of main chip clock in MHz unit * 0 = keep the current clock setting * Others = the new main chip clock */ unsigned short chipClock; /* * Speed of memory clock in MHz unit * 0 = keep the current clock setting * Others = the new memory clock */ unsigned short memClock; /* * Speed of master clock in MHz unit * 0 = keep the current clock setting * Others = the new master clock */ unsigned short masterClock; /* * 0 = leave all engine state untouched. * 1 = make sure they are off: 2D, Overlay, * video alpha, alpha, hardware cursors */ unsigned short setAllEngOff; /* * 0 = Do not reset the memory controller * 1 = Reset the memory controller */ unsigned char resetMemory; /* More initialization parameter can be added if needed */ }; enum logical_chip_type sm750_get_chip_type(void); void sm750_set_chip_type(unsigned short devId, u8 revId); unsigned int sm750_calc_pll_value(unsigned int request, struct pll_value *pll); unsigned int sm750_format_pll_reg(struct pll_value *pPLL); unsigned int ddk750_get_vm_size(void); int ddk750_init_hw(struct initchip_param *pinit_param); #endif

Overall Contributors

PersonTokensPropCommitsCommitProp
Sudip Mukherjee13457.76%213.33%
Matthieu Simon3816.38%16.67%
Elise Lennion2510.78%213.33%
Mihaela Muraru104.31%16.67%
Christian Lütke-Stetzkamp83.45%16.67%
Eric S. Stone62.59%16.67%
Lorenzo Stoakes31.29%16.67%
Huacai Chen20.86%16.67%
Arnd Bergmann20.86%16.67%
Varsha Rao10.43%16.67%
Greg Kroah-Hartman10.43%16.67%
Dan Carpenter10.43%16.67%
Moshe Green10.43%16.67%
Total232100.00%15100.00%
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.