X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=drivers%2Frtc%2Fimxdi.c;h=17519ce2c057d7ee66077ba637124ff8c228d460;hb=5d0449d4c74ad310373bb90691b9258e8ff12c2c;hp=985ce93acf71ed803844c43c86c14baee201fc44;hpb=5fb29f3c48d26981b117b08286bc16ec99d4ca0b;p=oweals%2Fu-boot.git diff --git a/drivers/rtc/imxdi.c b/drivers/rtc/imxdi.c index 985ce93acf..17519ce2c0 100644 --- a/drivers/rtc/imxdi.c +++ b/drivers/rtc/imxdi.c @@ -6,23 +6,7 @@ * Copyright 2008-2009 Freescale Semiconductor, Inc. All Rights Reserved. * Copyright 2010 Orex Computed Radiography * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0+ */ /* @@ -208,7 +192,7 @@ int rtc_get(struct rtc_time *tmp) } now = __raw_readl(&data.regs->dtcmr); - to_tm(now, tmp); + rtc_to_tm(now, tmp); err: return rc; @@ -225,8 +209,7 @@ int rtc_set(struct rtc_time *tmp) goto err; } - now = mktime(tmp->tm_year, tmp->tm_mon, tmp->tm_mday, - tmp->tm_hour, tmp->tm_min, tmp->tm_sec); + now = rtc_mktime(tmp); /* zero the fractional part first */ rc = DI_WRITE_WAIT(0, dtclr); if (rc == 0)