Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 91824
b: refs/heads/master
c: af15a29
h: refs/heads/master
v: v3
  • Loading branch information
Marcin Slusarz authored and Jan Kara committed Apr 17, 2008
1 parent 0e1ace2 commit ac5bc4a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 40 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 56774805d5eeecd3f1fb700603e593a35dc523c8
refs/heads/master: af15a298a49c9b5844cdaf70e10eb808e54ead2c
13 changes: 0 additions & 13 deletions trunk/fs/udf/ecma_167.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,6 @@ typedef struct {
uint8_t microseconds;
} __attribute__ ((packed)) timestamp;

typedef struct {
uint16_t typeAndTimezone;
int16_t year;
uint8_t month;
uint8_t day;
uint8_t hour;
uint8_t minute;
uint8_t second;
uint8_t centiseconds;
uint8_t hundredsOfMicroseconds;
uint8_t microseconds;
} __attribute__ ((packed)) kernel_timestamp;

/* Type and Time Zone (ECMA 167r3 1/7.3.1) */
#define TIMESTAMP_TYPE_MASK 0xF000
#define TIMESTAMP_TYPE_CUT 0x0000
Expand Down
9 changes: 5 additions & 4 deletions trunk/fs/udf/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -945,12 +945,13 @@ static void udf_load_pvoldesc(struct super_block *sb, struct buffer_head *bh)

if (udf_disk_stamp_to_time(&UDF_SB(sb)->s_record_time,
pvoldesc->recordingDateAndTime)) {
kernel_timestamp ts;
ts = lets_to_cpu(pvoldesc->recordingDateAndTime);
#ifdef UDFFS_DEBUG
timestamp *ts = &pvoldesc->recordingDateAndTime;
udf_debug("recording time %04u/%02u/%02u"
" %02u:%02u (%x)\n",
ts.year, ts.month, ts.day, ts.hour,
ts.minute, ts.typeAndTimezone);
le16_to_cpu(ts->year), ts->month, ts->day, ts->hour,
ts->minute, le16_to_cpu(ts->typeAndTimezone));
#endif
}

if (!udf_build_ustr(&instr, pvoldesc->volIdent, 32))
Expand Down
22 changes: 0 additions & 22 deletions trunk/fs/udf/udfend.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,6 @@ static inline lb_addr cpu_to_lelb(kernel_lb_addr in)
return out;
}

static inline kernel_timestamp lets_to_cpu(timestamp in)
{
kernel_timestamp out;

memcpy(&out, &in, sizeof(timestamp));
out.typeAndTimezone = le16_to_cpu(in.typeAndTimezone);
out.year = le16_to_cpu(in.year);

return out;
}

static inline short_ad lesa_to_cpu(short_ad in)
{
short_ad out;
Expand Down Expand Up @@ -85,15 +74,4 @@ static inline kernel_extent_ad leea_to_cpu(extent_ad in)
return out;
}

static inline timestamp cpu_to_lets(kernel_timestamp in)
{
timestamp out;

memcpy(&out, &in, sizeof(timestamp));
out.typeAndTimezone = cpu_to_le16(in.typeAndTimezone);
out.year = cpu_to_le16(in.year);

return out;
}

#endif /* __UDF_ENDIAN_H */

0 comments on commit ac5bc4a

Please sign in to comment.