mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	rtc: cpcap: set range
The CPCAP rtc is a 14bit day counter plus a 17bit seconds counter. Note that this failed on Nov 10 2014 so it is very likely this driver as never been used since. Link: https://lore.kernel.org/r/20200306015703.42101-2-alexandre.belloni@bootlin.com Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
This commit is contained in:
		
							parent
							
								
									05b38d182c
								
							
						
					
					
						commit
						d2377f8cc5
					
				
					 1 changed files with 1 additions and 0 deletions
				
			
		| 
						 | 
					@ -261,6 +261,7 @@ static int cpcap_rtc_probe(struct platform_device *pdev)
 | 
				
			||||||
		return PTR_ERR(rtc->rtc_dev);
 | 
							return PTR_ERR(rtc->rtc_dev);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	rtc->rtc_dev->ops = &cpcap_rtc_ops;
 | 
						rtc->rtc_dev->ops = &cpcap_rtc_ops;
 | 
				
			||||||
 | 
						rtc->rtc_dev->range_max = (1 << 14) * SECS_PER_DAY - 1;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	err = cpcap_get_vendor(dev, rtc->regmap, &rtc->vendor);
 | 
						err = cpcap_get_vendor(dev, rtc->regmap, &rtc->vendor);
 | 
				
			||||||
	if (err)
 | 
						if (err)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue