+ drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch added to -mm tree
Subject: + drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch added to -mm tree
To: [email protected],[email protected],[email protected]
From: [email protected]
Date: Fri, 15 Nov 2013 14:29:46 -0800
The patch titled
Subject: drivers/rtc/rtc-s5m.c: fix info->rtc assignment
has been added to the -mm tree. Its filename is
drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch
This patch should soon appear at
http://ozlabs.org/~akpm/mmots/broken-out/drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch
and later at
http://ozlabs.org/~akpm/mmotm/broken-out/drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/SubmitChecklist when testing your code ***
The -mm tree is included into linux-next and is updated there every 3-4 working days
------------------------------------------------------
From: Geert Uytterhoeven <[email protected]>
Subject: drivers/rtc/rtc-s5m.c: fix info->rtc assignment
drivers/rtc/rtc-s5m.c: In function `s5m_rtc_probe':drivers/rtc/rtc-s5m.c:545: warning: assignment from incompatible pointer type
struct s5m_rtc_info.rtc has type "struct regmap *", while struct sec_pmic_dev.rtc has type "struct i2c_client *".
Probably the author wanted to assign "struct sec_pmic_dev.regmap", which has the correct type.
Also, as "rtc" doesn't make much sense as a name for a regmap, rename it to "regmap".
---
drivers/rtc/rtc-s5m.c | 54 ++++++++++++++++++++-------------------- 1 file changed, 27 insertions(+), 27 deletions(-)
drivers/rtc/rtc-s5m.c renamed from drivers/rtc/rtc-s5m.c~drivers-rtc-rtc-s5mc-fix-info-rtc-assignment +27 -27
@@ -31,7 +31,7 @@struct s5m_rtc_info {struct device *dev;struct sec_pmic_dev *s5m87xx; -struct regmap *rtc; +struct regmap *regmap;struct rtc_device *rtc_dev;int irq;int device_type;
@@ -89,7 +89,7 @@ static inline int s5m8767_rtc_set_time_rint ret;unsigned int data; - ret =regmap_read (info->rtc,SEC_RTC_UDR_CON , &data); + ret =regmap_read (info->regmap,SEC_RTC_UDR_CON , &data);if (ret <0 ) {dev_err (info->dev,"failed to read update reg(%d)\n" , ret);return ret;
@@ -98,14 +98,14 @@ static inline int s5m8767_rtc_set_time_r data |=RTC_TIME_EN_MASK ; data |=RTC_UDR_MASK ; - ret =regmap_write (info->rtc,SEC_RTC_UDR_CON , data); + ret =regmap_write (info->regmap,SEC_RTC_UDR_CON , data);if (ret <0 ) {dev_err (info->dev,"failed to write update reg(%d)\n" , ret);return ret; }do { - ret =regmap_read (info->rtc,SEC_RTC_UDR_CON , &data); + ret =regmap_read (info->regmap,SEC_RTC_UDR_CON , &data); }while ((data &RTC_UDR_MASK ) && !ret);return ret;
@@ -116,7 +116,7 @@ static inline int s5m8767_rtc_set_alarm_int ret;unsigned int data; - ret =regmap_read (info->rtc,SEC_RTC_UDR_CON , &data); + ret =regmap_read (info->regmap,SEC_RTC_UDR_CON , &data);if (ret <0 ) {dev_err (info->dev,"%s: fail to read update reg(%d)\n" , __func__, ret);
@@ -126,7 +126,7 @@ static inline int s5m8767_rtc_set_alarm_ data &= ~RTC_TIME_EN_MASK ; data |=RTC_UDR_MASK ; - ret =regmap_write (info->rtc,SEC_RTC_UDR_CON , data); + ret =regmap_write (info->regmap,SEC_RTC_UDR_CON , data);if (ret <0 ) {dev_err (info->dev,"%s: fail to write update reg(%d)\n" , __func__, ret);
@@ -134,7 +134,7 @@ static inline int s5m8767_rtc_set_alarm_ }do { - ret =regmap_read (info->rtc,SEC_RTC_UDR_CON , &data); + ret =regmap_read (info->regmap,SEC_RTC_UDR_CON , &data); }while ((data &RTC_UDR_MASK ) && !ret);return ret;
@@ -178,7 +178,7 @@ static int s5m_rtc_read_time(struct deviu8 data[8 ];int ret; - ret =regmap_bulk_read (info->rtc,SEC_RTC_SEC , data,8 ); + ret =regmap_bulk_read (info->regmap,SEC_RTC_SEC , data,8 );if (ret <0 )return ret;
@@ -226,7 +226,7 @@ static int s5m_rtc_set_time(struct devic1900 + tm->tm_year,1 + tm->tm_mon, tm->tm_mday, tm->tm_hour, tm->tm_min, tm->tm_sec, tm->tm_wday); - ret =regmap_raw_write (info->rtc,SEC_RTC_SEC , data,8 ); + ret =regmap_raw_write (info->regmap,SEC_RTC_SEC , data,8 );if (ret <0 )return ret;
@@ -242,20 +242,20 @@ static int s5m_rtc_read_alarm(struct devunsigned int val;int ret, i; - ret =regmap_bulk_read (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_bulk_read (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret;switch (info->device_type) {case S5M8763X :s5m8763_data_to_tm (data, &alrm->time); - ret =regmap_read (info->rtc,SEC_ALARM0_CONF , &val); + ret =regmap_read (info->regmap,SEC_ALARM0_CONF , &val);if (ret <0 )return ret; alrm->enabled = !!val; - ret =regmap_read (info->rtc,SEC_RTC_STATUS , &val); + ret =regmap_read (info->regmap,SEC_RTC_STATUS , &val);if (ret <0 )return ret;
@@ -278,7 +278,7 @@ static int s5m_rtc_read_alarm(struct dev } alrm->pending =0 ; - ret =regmap_read (info->rtc,SEC_RTC_STATUS , &val); + ret =regmap_read (info->regmap,SEC_RTC_STATUS , &val);if (ret <0 )return ret;break ;
@@ -301,7 +301,7 @@ static int s5m_rtc_stop_alarm(struct s5mint ret, i;struct rtc_time tm; - ret =regmap_bulk_read (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_bulk_read (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret;
@@ -312,14 +312,14 @@ static int s5m_rtc_stop_alarm(struct s5mswitch (info->device_type) {case S5M8763X : - ret =regmap_write (info->rtc,SEC_ALARM0_CONF ,0 ); + ret =regmap_write (info->regmap,SEC_ALARM0_CONF ,0 );break ;case S5M8767X :for (i =0 ; i <7 ; i++) data[i] &= ~ALARM_ENABLE_MASK ; - ret =regmap_raw_write (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_raw_write (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret;
@@ -341,7 +341,7 @@ static int s5m_rtc_start_alarm(struct s5u8 alarm0_conf;struct rtc_time tm; - ret =regmap_bulk_read (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_bulk_read (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret;
@@ -353,7 +353,7 @@ static int s5m_rtc_start_alarm(struct s5switch (info->device_type) {case S5M8763X : alarm0_conf =0x77 ; - ret =regmap_write (info->rtc,SEC_ALARM0_CONF , alarm0_conf); + ret =regmap_write (info->regmap,SEC_ALARM0_CONF , alarm0_conf);break ;case S5M8767X :
@@ -368,7 +368,7 @@ static int s5m_rtc_start_alarm(struct s5if (data[RTC_YEAR1 ] &0x7f ) data[RTC_YEAR1 ] |=ALARM_ENABLE_MASK ; - ret =regmap_raw_write (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_raw_write (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret; ret =s5m8767_rtc_set_alarm_reg (info);
@@ -410,7 +410,7 @@ static int s5m_rtc_set_alarm(struct deviif (ret <0 )return ret; - ret =regmap_raw_write (info->rtc,SEC_ALARM0_SEC , data,8 ); + ret =regmap_raw_write (info->regmap,SEC_ALARM0_SEC , data,8 );if (ret <0 )return ret;
@@ -455,7 +455,7 @@ static const struct rtc_class_ops s5m_rtstatic void s5m_rtc_enable_wtsr (struct s5m_rtc_info *info,bool enable) {int ret; - ret =regmap_update_bits (info->rtc,SEC_WTSR_SMPL_CNTL , + ret =regmap_update_bits (info->regmap,SEC_WTSR_SMPL_CNTL ,WTSR_ENABLE_MASK , enable ?WTSR_ENABLE_MASK :0 );if (ret <0 )
@@ -466,7 +466,7 @@ static void s5m_rtc_enable_wtsr(struct sstatic void s5m_rtc_enable_smpl (struct s5m_rtc_info *info,bool enable) {int ret; - ret =regmap_update_bits (info->rtc,SEC_WTSR_SMPL_CNTL , + ret =regmap_update_bits (info->regmap,SEC_WTSR_SMPL_CNTL ,SMPL_ENABLE_MASK , enable ?SMPL_ENABLE_MASK :0 );if (ret <0 )
@@ -481,7 +481,7 @@ static int s5m8767_rtc_init_reg(struct sint ret;struct rtc_time tm; - ret =regmap_read (info->rtc,SEC_RTC_UDR_CON , &tp_read); + ret =regmap_read (info->regmap,SEC_RTC_UDR_CON , &tp_read);if (ret <0 ) {dev_err (info->dev,"%s: fail to read control reg(%d)\n" , __func__, ret);
@@ -493,7 +493,7 @@ static int s5m8767_rtc_init_reg(struct s data[1 ] = (0 <<BCD_EN_SHIFT ) | (1 <<MODEL24_SHIFT ); info->rtc_24hr_mode =1 ; - ret =regmap_raw_write (info->rtc,SEC_ALARM0_CONF , data,2 ); + ret =regmap_raw_write (info->regmap,SEC_ALARM0_CONF , data,2 );if (ret <0 ) {dev_err (info->dev,"%s: fail to write controlm reg(%d)\n" , __func__, ret);
@@ -515,7 +515,7 @@ static int s5m8767_rtc_init_reg(struct s ret =s5m_rtc_set_time (info->dev, &tm); } - ret =regmap_update_bits (info->rtc,SEC_RTC_UDR_CON , + ret =regmap_update_bits (info->regmap,SEC_RTC_UDR_CON ,RTC_TCON_MASK , tp_read |RTC_TCON_MASK );if (ret <0 ) dev_err(info->dev, "%s: fail to update TCON reg(%d)\n",
@@ -542,7 +542,7 @@ static int s5m_rtc_probe(struct platform info->dev = &pdev->dev; info->s5m87xx = s5m87xx; - info->rtc = s5m87xx->rtc; + info->regmap = s5m87xx->regmap; info->device_type = s5m87xx->device_type; info->wtsr_smpl = s5m87xx->wtsr_smpl;
@@ -596,7 +596,7 @@ static void s5m_rtc_shutdown(struct platif (info->wtsr_smpl) {for (i =0 ; i <3 ; i++) {s5m_rtc_enable_wtsr (info, false); -regmap_read (info->rtc,SEC_WTSR_SMPL_CNTL , &val); +regmap_read (info->regmap,SEC_WTSR_SMPL_CNTL , &val);pr_debug ("%s: WTSR_SMPL reg(0x%02x)\n" , __func__, val);if (val &WTSR_ENABLE_MASK ) pr_emerg("%s: fail to disable WTSR\n",
_
Patches currently in -mm which might be from [email protected] are
origin.patch drivers-rtc-rtc-s5mc-fix-info-rtc-assignment.patch genirq-correct-fuzzy-and-fragile-irq_retval-definition.patch scsi-do-not-call-do_div-with-a-64-bit-divisor.patch linux-next.patch