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

Commit b30b159f authored by Elliott Hughes's avatar Elliott Hughes Committed by Android Git Automerger
Browse files

am 61e92a02: am 68835ee8: Merge "system/core LP64 cleanup."

* commit '61e92a02':
  system/core LP64 cleanup.
parents c7cb88f1 61e92a02
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -57,13 +57,13 @@ static void test_call1()

static void *noisy(void *x)
{
    char c = (unsigned) x;
    char c = (uintptr_t) x;
    for(;;) {
        usleep(250*1000);
        write(2, &c, 1);
        if(c == 'C') *((unsigned*) 0) = 42;
    }
    return 0;
    return NULL;
}

static int ctest()
@@ -81,7 +81,7 @@ static int ctest()

static void* thread_callback(void* raw_arg)
{
    return (void*) do_action((const char*) raw_arg);
    return (void*) (uintptr_t) do_action((const char*) raw_arg);
}

static int do_action_on_thread(const char* arg)
@@ -90,7 +90,7 @@ static int do_action_on_thread(const char* arg)
    pthread_create(&t, NULL, thread_callback, (void*) arg);
    void* result = NULL;
    pthread_join(t, &result);
    return (int) result;
    return (int) (uintptr_t) result;
}

__attribute__((noinline)) static int crash3(int a) {
+3 −3
Original line number Diff line number Diff line
@@ -124,9 +124,9 @@ static void cmd_boot(struct protocol_handle *phandle, const char *arg)
        goto error;
    }

    kernel_ptr = (void *)((unsigned) ptr + hdr->page_size);
    ramdisk_ptr = (void *)((unsigned) kernel_ptr + kernel_actual);
    second_ptr = (void *)((unsigned) ramdisk_ptr + ramdisk_actual);
    kernel_ptr = (void *)((uintptr_t) ptr + hdr->page_size);
    ramdisk_ptr = (void *)((uintptr_t) kernel_ptr + kernel_actual);
    second_ptr = (void *)((uintptr_t) ramdisk_ptr + ramdisk_actual);

    D(INFO, "preparing to boot");
    // Prepares boot physical address. Addresses from header are ignored
+4 −4
Original line number Diff line number Diff line
@@ -89,10 +89,10 @@ long kexec_load(unsigned int entry, unsigned long nr_segments,
 * Kernel address is not set into kernel_phys
 * Ramdisk is set to position relative to kernel
 */
int prepare_boot_linux(unsigned kernel_phys, void *kernel_addr, int kernel_size,
                       unsigned ramdisk_phys, void *ramdisk_addr, int ramdisk_size,
                       unsigned second_phys, void *second_addr, int second_size,
                       unsigned atags_phys, void *atags_addr, int atags_size) {
int prepare_boot_linux(uintptr_t kernel_phys, void *kernel_addr, int kernel_size,
                       uintptr_t ramdisk_phys, void *ramdisk_addr, int ramdisk_size,
                       uintptr_t second_phys, void *second_addr, int second_size,
                       uintptr_t atags_phys, void *atags_addr, int atags_size) {
    struct kexec_segment segment[4];
    int segment_count = 2;
    unsigned entry = START_ADDRESS + KEXEC_ARM_ZIMAGE_OFFSET;
+2 −2
Original line number Diff line number Diff line
@@ -40,8 +40,8 @@
#define KEXEC_TYPE_DEFAULT 0
#define KEXEC_TYPE_CRASH   1

int prepare_boot_linux(unsigned, void *, int, unsigned, void *, int,
                       unsigned, void *, int, unsigned, void *, int);
int prepare_boot_linux(uintptr_t, void *, int, uintptr_t, void *, int,
                       uintptr_t, void *, int, uintptr_t, void *, int);
unsigned *create_atags(unsigned *, int, const struct boot_img_hdr *, int *);
long kexec_load(unsigned int, unsigned long, struct kexec_segment *, unsigned long);
char *read_atags(const char *, int *);
+1 −1
Original line number Diff line number Diff line
@@ -142,7 +142,7 @@ void fastboot_data(struct protocol_handle *phandle, size_t len)
    char response[64];
    ssize_t ret;

    snprintf(response, 64, "DATA%08x", len);
    snprintf(response, 64, "DATA%08zx", len);
    ret = protocol_handle_write(phandle, response, strlen(response));
    if (ret < 0)
        return;
Loading