Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 31003e3a authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull UML update from Richard Weinberger:
 "Besides of fixes this contains also support for CONFIG_STACKTRACE by
  Daniel Walter"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml:
  um: net: Eliminate NULL test after alloc_bootmem
  um: Add support for CONFIG_STACKTRACE
  um: ubd: Fix for processes stuck in D state forever
  um: delete unnecessary bootmem struct page array
  um: remove csum_partial_copy_generic_i386 to clean up exception table
parents 1ee07ef6 5f786595
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -39,7 +39,8 @@ config LOCKDEP_SUPPORT

config STACKTRACE_SUPPORT
	bool
	default n
	default y
	select STACKTRACE

config GENERIC_CALIBRATE_DELAY
	bool
+0 −4
Original line number Diff line number Diff line
@@ -659,10 +659,6 @@ static int __init eth_setup(char *str)
	}

	new = alloc_bootmem(sizeof(*new));
	if (new == NULL) {
		printk(KERN_ERR "eth_init : alloc_bootmem failed\n");
		return 1;
	}

	INIT_LIST_HEAD(&new->list);
	new->index = n;
+3 −2
Original line number Diff line number Diff line
@@ -1277,7 +1277,7 @@ static void do_ubd_request(struct request_queue *q)

	while(1){
		struct ubd *dev = q->queuedata;
		if(dev->end_sg == 0){
		if(dev->request == NULL){
			struct request *req = blk_fetch_request(q);
			if(req == NULL)
				return;
@@ -1299,7 +1299,8 @@ static void do_ubd_request(struct request_queue *q)
				return;
			}
			prepare_flush_request(req, io_req);
			submit_request(io_req, dev);
			if (submit_request(io_req, dev) == false)
				return;
		}

		while(dev->start_sg < dev->end_sg){
+42 −0
Original line number Diff line number Diff line
#ifndef _ASM_UML_STACKTRACE_H
#define _ASM_UML_STACKTRACE_H

#include <linux/uaccess.h>
#include <linux/ptrace.h>

struct stack_frame {
	struct stack_frame *next_frame;
	unsigned long return_address;
};

struct stacktrace_ops {
	void (*address)(void *data, unsigned long address, int reliable);
};

#ifdef CONFIG_FRAME_POINTER
static inline unsigned long
get_frame_pointer(struct task_struct *task, struct pt_regs *segv_regs)
{
	if (!task || task == current)
		return segv_regs ? PT_REGS_BP(segv_regs) : current_bp();
	return KSTK_EBP(task);
}
#else
static inline unsigned long
get_frame_pointer(struct task_struct *task, struct pt_regs *segv_regs)
{
	return 0;
}
#endif

static inline unsigned long
*get_stack_pointer(struct task_struct *task, struct pt_regs *segv_regs)
{
	if (!task || task == current)
		return segv_regs ? (unsigned long *)PT_REGS_SP(segv_regs) : current_sp();
	return (unsigned long *)KSTK_ESP(task);
}

void dump_trace(struct task_struct *tsk, const struct stacktrace_ops *ops, void *data);

#endif /* _ASM_UML_STACKTRACE_H */
+1 −1
Original line number Diff line number Diff line
@@ -49,7 +49,7 @@ extern int iomem_size;
extern int init_mem_user(void);
extern void setup_memory(void *entry);
extern unsigned long find_iomem(char *driver, unsigned long *len_out);
extern int init_maps(unsigned long physmem, unsigned long iomem,
extern void mem_total_pages(unsigned long physmem, unsigned long iomem,
		     unsigned long highmem);
extern unsigned long get_vm(unsigned long len);
extern void setup_physmem(unsigned long start, unsigned long usable,
Loading