Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 615736
Collapse All | Expand All

(-)a/kexec/arch/arm/kexec-arm.c (-1 / +1 lines)
Lines 47-53 int get_memory_ranges(struct memory_range **range, int *ranges, Link Here
47
		int count;
47
		int count;
48
		if (memory_ranges >= MAX_MEMORY_RANGES)
48
		if (memory_ranges >= MAX_MEMORY_RANGES)
49
			break;
49
			break;
50
		count = sscanf(line, "%Lx-%Lx : %n",
50
		count = sscanf(line, "%llx-%llx : %n",
51
			&start, &end, &consumed);
51
			&start, &end, &consumed);
52
		if (count != 2)
52
		if (count != 2)
53
			continue;
53
			continue;
(-)a/kexec/arch/i386/crashdump-x86.c (-4 / +4 lines)
Lines 119-125 static unsigned long long get_kernel_sym(const char *symbol) Link Here
119
	}
119
	}
120
120
121
	while(fgets(line, sizeof(line), fp) != NULL) {
121
	while(fgets(line, sizeof(line), fp) != NULL) {
122
		if (sscanf(line, "%Lx %c %s", &vaddr, &type, sym) != 3)
122
		if (sscanf(line, "%llx %c %s", &vaddr, &type, sym) != 3)
123
			continue;
123
			continue;
124
		if (strcmp(sym, symbol) == 0) {
124
		if (strcmp(sym, symbol) == 0) {
125
			dbgprintf("kernel symbol %s vaddr = %16llx\n", symbol, vaddr);
125
			dbgprintf("kernel symbol %s vaddr = %16llx\n", symbol, vaddr);
Lines 296-307 static int get_crash_memory_ranges(struct memory_range **range, int *ranges, Link Here
296
296
297
		if (memory_ranges >= CRASH_MAX_MEMORY_RANGES)
297
		if (memory_ranges >= CRASH_MAX_MEMORY_RANGES)
298
			break;
298
			break;
299
		count = sscanf(line, "%Lx-%Lx : %n",
299
		count = sscanf(line, "%llx-%llx : %n",
300
			&start, &end, &consumed);
300
			&start, &end, &consumed);
301
		if (count != 2)
301
		if (count != 2)
302
			continue;
302
			continue;
303
		str = line + consumed;
303
		str = line + consumed;
304
		dbgprintf("%016Lx-%016Lx : %s",
304
		dbgprintf("%016llx-%016llx : %s",
305
			start, end, str);
305
			start, end, str);
306
		/* Only Dumping memory of type System RAM. */
306
		/* Only Dumping memory of type System RAM. */
307
		if (memcmp(str, "System RAM\n", 11) == 0) {
307
		if (memcmp(str, "System RAM\n", 11) == 0) {
Lines 778-784 static int get_crash_notes(int cpu, uint64_t *addr, uint64_t *len) Link Here
778
		*addr = x86__pa(vaddr + (cpu * MAX_NOTE_BYTES));
778
		*addr = x86__pa(vaddr + (cpu * MAX_NOTE_BYTES));
779
		*len = MAX_NOTE_BYTES;
779
		*len = MAX_NOTE_BYTES;
780
780
781
		dbgprintf("crash_notes addr = %Lx\n",
781
		dbgprintf("crash_notes addr = %llx\n",
782
			  (unsigned long long)*addr);
782
			  (unsigned long long)*addr);
783
783
784
		fclose(fp);
784
		fclose(fp);
(-)a/kexec/arch/i386/kexec-x86-common.c (-1 / +1 lines)
Lines 81-87 static int get_memory_ranges_proc_iomem(struct memory_range **range, int *ranges Link Here
81
		int count;
81
		int count;
82
		if (memory_ranges >= MAX_MEMORY_RANGES)
82
		if (memory_ranges >= MAX_MEMORY_RANGES)
83
			break;
83
			break;
84
		count = sscanf(line, "%Lx-%Lx : %n",
84
		count = sscanf(line, "%llx-%llx : %n",
85
			&start, &end, &consumed);
85
			&start, &end, &consumed);
86
		if (count != 2)
86
		if (count != 2)
87
			continue;
87
			continue;
(-)a/kexec/arch/ia64/kexec-elf-rel-ia64.c (-1 / +1 lines)
Lines 155-160 void machine_apply_elf_rel(struct mem_ehdr *ehdr, Link Here
155
	}
155
	}
156
	return;
156
	return;
157
overflow:
157
overflow:
158
	die("overflow in relocation type %lu val %Lx\n", 
158
	die("overflow in relocation type %lu val %llx\n",
159
			r_type, value);
159
			r_type, value);
160
}
160
}
(-)a/kexec/arch/mips/crashdump-mips.c (-1 / +1 lines)
Lines 173-179 static int get_crash_memory_ranges(struct memory_range **range, int *ranges) Link Here
173
		int type, consumed, count;
173
		int type, consumed, count;
174
		if (memory_ranges >= CRASH_MAX_MEMORY_RANGES)
174
		if (memory_ranges >= CRASH_MAX_MEMORY_RANGES)
175
			break;
175
			break;
176
		count = sscanf(line, "%Lx-%Lx : %n",
176
		count = sscanf(line, "%llx-%llx : %n",
177
			&start, &end, &consumed);
177
			&start, &end, &consumed);
178
		if (count != 2)
178
		if (count != 2)
179
			continue;
179
			continue;
(-)a/kexec/arch/mips/kexec-mips.c (-1 / +1 lines)
Lines 48-54 int get_memory_ranges(struct memory_range **range, int *ranges, Link Here
48
	while (fgets(line, sizeof(line), fp) != 0) {
48
	while (fgets(line, sizeof(line), fp) != 0) {
49
		if (memory_ranges >= MAX_MEMORY_RANGES)
49
		if (memory_ranges >= MAX_MEMORY_RANGES)
50
			break;
50
			break;
51
		count = sscanf(line, "%Lx-%Lx : %n", &start, &end, &consumed);
51
		count = sscanf(line, "%llx-%llx : %n", &start, &end, &consumed);
52
		if (count != 2)
52
		if (count != 2)
53
			continue;
53
			continue;
54
		str = line + consumed;
54
		str = line + consumed;
(-)a/kexec/arch/s390/kexec-s390.c (-1 / +1 lines)
Lines 170-176 int get_memory_ranges_s390(struct memory_range memory_range[], int *ranges, Link Here
170
		if (current_range == MAX_MEMORY_RANGES)
170
		if (current_range == MAX_MEMORY_RANGES)
171
			break;
171
			break;
172
172
173
		sscanf(line,"%Lx-%Lx : %n", &start, &end, &cons);
173
		sscanf(line,"%llx-%llx : %n", &start, &end, &cons);
174
		str = line+cons;
174
		str = line+cons;
175
		if ((memcmp(str, sys_ram, strlen(sys_ram)) == 0) ||
175
		if ((memcmp(str, sys_ram, strlen(sys_ram)) == 0) ||
176
		    ((memcmp(str, crash_kernel, strlen(crash_kernel)) == 0) &&
176
		    ((memcmp(str, crash_kernel, strlen(crash_kernel)) == 0) &&
(-)a/kexec/crashdump.c (-4 / +4 lines)
Lines 98-104 int get_crash_notes_per_cpu(int cpu, uint64_t *addr, uint64_t *len) Link Here
98
	}
98
	}
99
	if (!fgets(line, sizeof(line), fp))
99
	if (!fgets(line, sizeof(line), fp))
100
		die("Cannot parse %s: %s\n", crash_notes, strerror(errno));
100
		die("Cannot parse %s: %s\n", crash_notes, strerror(errno));
101
	count = sscanf(line, "%Lx", &temp);
101
	count = sscanf(line, "%llx", &temp);
102
	if (count != 1)
102
	if (count != 1)
103
		die("Cannot parse %s: %s\n", crash_notes, strerror(errno));
103
		die("Cannot parse %s: %s\n", crash_notes, strerror(errno));
104
	*addr = (uint64_t) temp;
104
	*addr = (uint64_t) temp;
Lines 112-118 int get_crash_notes_per_cpu(int cpu, uint64_t *addr, uint64_t *len) Link Here
112
		if (!fgets(line, sizeof(line), fp))
112
		if (!fgets(line, sizeof(line), fp))
113
			die("Cannot parse %s: %s\n",
113
			die("Cannot parse %s: %s\n",
114
			    crash_notes_size, strerror(errno));
114
			    crash_notes_size, strerror(errno));
115
		count = sscanf(line, "%Lu", &temp);
115
		count = sscanf(line, "%llu", &temp);
116
		if (count != 1)
116
		if (count != 1)
117
			die("Cannot parse %s: %s\n",
117
			die("Cannot parse %s: %s\n",
118
			    crash_notes_size, strerror(errno));
118
			    crash_notes_size, strerror(errno));
Lines 120-126 int get_crash_notes_per_cpu(int cpu, uint64_t *addr, uint64_t *len) Link Here
120
		fclose(fp);
120
		fclose(fp);
121
	}
121
	}
122
122
123
	dbgprintf("%s: crash_notes addr = %Lx, size = %Lu\n", __FUNCTION__,
123
	dbgprintf("%s: crash_notes addr = %llx, size = %llu\n", __FUNCTION__,
124
		  (unsigned long long)*addr, (unsigned long long)*len);
124
		  (unsigned long long)*addr, (unsigned long long)*len);
125
125
126
	return 0;
126
	return 0;
Lines 141-147 static int get_vmcoreinfo(const char *kdump_info, uint64_t *addr, uint64_t *len) Link Here
141
141
142
	if (!fgets(line, sizeof(line), fp))
142
	if (!fgets(line, sizeof(line), fp))
143
		die("Cannot parse %s: %s\n", kdump_info, strerror(errno));
143
		die("Cannot parse %s: %s\n", kdump_info, strerror(errno));
144
	count = sscanf(line, "%Lx %Lx", &temp, &temp2);
144
	count = sscanf(line, "%llx %llx", &temp, &temp2);
145
	if (count != 2)
145
	if (count != 2)
146
		die("Cannot parse %s: %s\n", kdump_info, strerror(errno));
146
		die("Cannot parse %s: %s\n", kdump_info, strerror(errno));
147
147
(-)a/kexec/kexec-iomem.c (-1 / +1 lines)
Lines 44-50 int kexec_iomem_for_each_line(char *match, Link Here
44
		die("Cannot open %s\n", iomem);
44
		die("Cannot open %s\n", iomem);
45
45
46
	while(fgets(line, sizeof(line), fp) != 0) {
46
	while(fgets(line, sizeof(line), fp) != 0) {
47
		count = sscanf(line, "%Lx-%Lx : %n", &start, &end, &consumed);
47
		count = sscanf(line, "%llx-%llx : %n", &start, &end, &consumed);
48
		if (count != 2)
48
		if (count != 2)
49
			continue;
49
			continue;
50
		str = line + consumed;
50
		str = line + consumed;

Return to bug 615736