<commit_before>/*
 * XG20, XG21, XG40, XG42 frame buffer device
 * for Linux kernels  2.5.x, 2.6.x
 * Base on TW's sis fbdev code.
 */

#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt

#include <linux/module.h>

#ifdef CONFIG_MTRR
#include <asm/mtrr.h>
#endif

#include "XGI_main.h"
#include "vb_init.h"
#include "vb_util.h"
#include "vb_setmode.h"

#define Index_CR_GPIO_Reg1 0x48
#define Index_CR_GPIO_Reg3 0x4a

#define GPIOG_EN    (1<<6)
#define GPIOG_READ  (1<<1)

static char *forcecrt2type;
static char *mode;
static int vesa = -1;
static unsigned int refresh_rate;

/* -------------------- Macro definitions ---------------------------- */

#undef XGIFBDEBUG

#ifdef XGIFBDEBUG
static void dumpVGAReg(void)
{
	u8 i, reg;

	xgifb_reg_set(XGISR, 0x05, 0x86);
	/*
	xgifb_reg_set(XGISR, 0x08, 0x4f);
	xgifb_reg_set(XGISR, 0x0f, 0x20);
	xgifb_reg_set(XGISR, 0x11, 0x4f);
	xgifb_reg_set(XGISR, 0x13, 0x45);
	xgifb_reg_set(XGISR, 0x14, 0x51);
	xgifb_reg_set(XGISR, 0x1e, 0x41);
	xgifb_reg_set(XGISR, 0x1f, 0x0);
	xgifb_reg_set(XGISR, 0x20, 0xa1);
	xgifb_reg_set(XGISR, 0x22, 0xfb);
	xgifb_reg_set(XGISR, 0x26, 0x22);
	xgifb_reg_set(XGISR, 0x3e, 0x07);
	*/

	/* xgifb_reg_set(XGICR, 0x19, 0x00); */
	/* xgifb_reg_set(XGICR, 0x1a, 0x3C); */
	/* xgifb_reg_set(XGICR, 0x22, 0xff); */
	/* xgifb_reg_set(XGICR, 0x3D, 0x10); */

	/* xgifb_reg_set(XGICR, 0x4a, 0xf3); */

	/* xgifb_reg_set(XGICR, 0x57, 0x0); */
	/* xgifb_reg_set(XGICR, 0x7a, 0x2c); */

	/* xgifb_reg_set(XGICR, 0x82, 0xcc); */<commit_msg>Staging: xgifb: define real dumpVGAReg() content only in DEBUG mode.<commit_after>/*
 * XG20, XG21, XG40, XG42 frame buffer device
 * for Linux kernels  2.5.x, 2.6.x
 * Base on TW's sis fbdev code.
 */

#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt

#include <linux/module.h>

#ifdef CONFIG_MTRR
#include <asm/mtrr.h>
#endif

#include "XGI_main.h"
#include "vb_init.h"
#include "vb_util.h"
#include "vb_setmode.h"

#define Index_CR_GPIO_Reg1 0x48
#define Index_CR_GPIO_Reg3 0x4a

#define GPIOG_EN    (1<<6)
#define GPIOG_READ  (1<<1)

static char *forcecrt2type;
static char *mode;
static int vesa = -1;
static unsigned int refresh_rate;

/* -------------------- Macro definitions ---------------------------- */

#ifdef DEBUG
static void dumpVGAReg(void)
{
	u8 i, reg;

	xgifb_reg_set(XGISR, 0x05, 0x86);
	/*
	xgifb_reg_set(XGISR, 0x08, 0x4f);
	xgifb_reg_set(XGISR, 0x0f, 0x20);
	xgifb_reg_set(XGISR, 0x11, 0x4f);
	xgifb_reg_set(XGISR, 0x13, 0x45);
	xgifb_reg_set(XGISR, 0x14, 0x51);
	xgifb_reg_set(XGISR, 0x1e, 0x41);
	xgifb_reg_set(XGISR, 0x1f, 0x0);
	xgifb_reg_set(XGISR, 0x20, 0xa1);
	xgifb_reg_set(XGISR, 0x22, 0xfb);
	xgifb_reg_set(XGISR, 0x26, 0x22);
	xgifb_reg_set(XGISR, 0x3e, 0x07);
	*/

	/* xgifb_reg_set(XGICR, 0x19, 0x00); */
	/* xgifb_reg_set(XGICR, 0x1a, 0x3C); */
	/* xgifb_reg_set(XGICR, 0x22, 0xff); */
	/* xgifb_reg_set(XGICR, 0x3D, 0x10); */

	/* xgifb_reg_set(XGICR, 0x4a, 0xf3); */

	/* xgifb_reg_set(XGICR, 0x57, 0x0); */
	/* xgifb_reg_set(XGICR, 0x7a, 0x2c); */

	/* xgifb_reg_set(XGICR, 0x82, 0xcc); */
{'fraction_non_alphanumeric': 0.17941079112876532, 'fraction_numerical': 0.08209202250910294, 'mean_word_length': 4.036666666666667, 'pattern_counts': {'":': 2, '<': 15, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2958671', 'n_tokens_mistral': 1741, 'n_tokens_neox': 1540, 'n_words': 279}