//WAIT_ME();
while(!(pDDR_Reg->CTRL_REG_03 & 0x100));
pDDR_Reg->CTRL_REG_10 &= ~(0x1);
- if(memType == DDRII)
- {
- if(333000 < KHz)
- {
- pDDR_Reg->CTRL_REG_82 = 0x00885555;
- }
- else
- {
- pDDR_Reg->CTRL_REG_82 = 0x00685555;
- }
- }
- else
- {
- if(133000 < KHz)
- {
- pDDR_Reg->CTRL_REG_82 = 0x00840000;
- }
- else
- {
- pDDR_Reg->CTRL_REG_82 = 0x00640000;
- }
- }
if(110000 > KHz)
{
DLLBypass(KHz);
telement = 0;
if(memType == DDRII)
{
- pDDR_Reg->CTRL_REG_82 = 0x00685555;
- //tXSR = tXSRD = 200 tCK
+ //tXSR = tXSRD = 200 tCK
pDDR_Reg->CTRL_REG_67 = TXSR(200);
}
else
{
pDDR_Reg->CTRL_REG_11 = 0x101;
- pDDR_Reg->CTRL_REG_82 = 0x00640000;
}
/* 20100609,HSL@RK,disable ddr interrupt .*/
pDDR_Reg->CTRL_REG_45 = 0x07ff03ff;
spi_gpio_set_pindirection(SPI_GPIO_P2_10, SPI_GPIO_IN); //X-XL input\r
spi_gpio_set_pindirection(SPI_GPIO_P2_11, SPI_GPIO_IN); //X+XR input\r
\r
- spi_gpio_set_pinlevel(SPI_GPIO_P2_12, SPI_GPIO_LOW); //LCD_RESET output//\r
+ spi_gpio_set_pinlevel(SPI_GPIO_P2_12, SPI_GPIO_HIGH); //LCD_RESET output//\r
spi_gpio_set_pindirection(SPI_GPIO_P2_12, SPI_GPIO_OUT);\r
- spi_gpio_set_pinlevel(SPI_GPIO_P2_12, SPI_GPIO_HIGH);\r
+ //spi_gpio_set_pinlevel(SPI_GPIO_P2_12, SPI_GPIO_HIGH);\r
spi_gpio_set_pinlevel(SPI_GPIO_P2_13, SPI_GPIO_HIGH); //USB_PWR_EN output\r
spi_gpio_set_pindirection(SPI_GPIO_P2_13, SPI_GPIO_OUT);\r
spi_gpio_set_pinlevel(SPI_GPIO_P2_14, SPI_GPIO_LOW); //WL_HOST_WAKE_B output\r
axis.y = -mma7660_convert_to_int(buffer[MMA7660_REG_Y_OUT]);
axis.z = -mma7660_convert_to_int(buffer[MMA7660_REG_Z_OUT]);
- rk28printk( "%s: -------------------------------------------mma7660_GetData axis = %d %d %d-----------------------------------------------\n",
- __func__, axis.x, axis.y, axis.z);
+ //rk28printk( "%s: ------------------mma7660_GetData axis = %d %d %d--------------\n",
+ // __func__, axis.x, axis.y, axis.z);
memcpy(sense_data, &axis, sizeof(axis));
mma7660_report_value(sense_data);
if (mma7660_get_data() < 0)
rk28printk(KERN_ERR "MMA7660 mma_work_func: Get data failed\n");
enable_irq(this_client->irq);
- rk28printk("---------------------------------------mma7660_delaywork_func------------------------------\n");
+ //rk28printk("---------------------------------------mma7660_delaywork_func------------------------------\n");
}
struct mma7660_data *data = dev_id;
disable_irq_nosync(this_client->irq);
schedule_delayed_work(&data->delaywork,msecs_to_jiffies(30));
- rk28printk("--------------------------------------mma7660_interrupt---------------------------------------\n");
+ //rk28printk("--------------------------------------mma7660_interrupt---------------------------------------\n");
return IRQ_HANDLED;
}
static struct miscdevice mma7660_device = {
.minor = MISC_DYNAMIC_MINOR,
- .name = "mma7660_daemon",
+ .name = "gsensor",//"mma7660_daemon",
.fops = &mma7660_fops,
};
#endif
rk28printk(KERN_INFO "mma7660 probe ok\n");
mma->status = -1;
- mma7660_start(MMA7660_RATE_32);
+ //mma7660_start(MMA7660_RATE_32);
return 0;
exit_gsensor_sysfs_init_failed: