Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for timestamp seconds count on 4.20 kernel. #139

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

terraluna977
Copy link

Signed-off-by: Woody Suwalski [email protected]

@tommyjcarpenter
Copy link

tommyjcarpenter commented Dec 31, 2018

I tried building your local branch @terraluna977 on arch 4.20 and it still fails to compile with many errors like the below

    /home/tommy/exfat-nofuse/exfat_super.c: In function ‘exfat_read_root’:
/home/tommy/exfat-nofuse/exfat_super.c:2425:18: error: wrong type argument to increment
  inode->i_version++;

@@ -128,16 +128,16 @@ static time_t accum_days_in_year[] = {

TIMESTAMP_T *tm_current(TIMESTAMP_T *tp)
{
struct timespec ts;
time_t second, day, leap_day, month, year;

#if LINUX_VERSION_CODE < KERNEL_VERSION(4,8,0)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ktime_get_real_seconds() available on Linux kernels lower than 4.8.0 (looks like it was introduced in 3.19.0), is this #if really required at all?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as an FYI I have a working (built and tested this morning_ PR here: barrybingo#1

@jamesan
Copy link

jamesan commented Jan 7, 2019

Duplicate of #137.

Also, this doesn't address the root issue, which is updating to current time interfaces. The relevant deprecated time interfaces were finally removed from the Linux kernel on Aug 14, 2018 to address the Year 2038 problem by moving from 32- to 64-bit data types.

The official direct replacements for the timespec type and the ktime_get_real_ts() function are, respectively, timespec64 and ktime_get_real_ts64(), as found in Documentation/core-api/timekeeping.rst.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants