OSDN Git Service

goldfish: pipe: ANDROID: fix logging format strings
authorRoman Kiryanov <rkir@google.com>
Tue, 20 Mar 2018 20:40:04 +0000 (13:40 -0700)
committerRoman Kiryanov <rkir@google.com>
Tue, 1 May 2018 18:47:38 +0000 (11:47 -0700)
* remove '%p' to avoid exposing kernel addresses;
* add missing '\n'.

Bug: 72717639
Bug: 66884503
Change-Id: I81357841dc334df595a3244f232c2e6bb72e64a1
Signed-off-by: Roman Kiryanov <rkir@google.com>
drivers/platform/goldfish/goldfish_pipe_v2.c

index 3119b33..aa794a6 100644 (file)
@@ -721,12 +721,11 @@ static int goldfish_pipe_open(struct inode *inode, struct file *file)
        status = goldfish_cmd_locked(pipe, PIPE_CMD_OPEN);
        spin_unlock_irqrestore(&dev->lock, flags);
        if (status < 0) {
-               pr_err("Could not tell host of new pipe! status=%d", status);
+               pr_err("Could not tell host of new pipe! status=%d\n", status);
                goto err_cmd;
        }
        /* All is done, save the pipe into the file's private data field */
        file->private_data = pipe;
-       pr_debug("%s on 0x%p\n", __func__, pipe);
        return 0;
 
 err_cmd:
@@ -746,8 +745,6 @@ static int goldfish_pipe_release(struct inode *inode, struct file *filp)
        struct goldfish_pipe *pipe = filp->private_data;
        struct goldfish_pipe_dev *dev = pipe->dev;
 
-       pr_debug("%s on 0x%p\n", __func__, pipe);
-
        /* The guest is closing the channel, so tell the emulator right now */
        (void)goldfish_cmd(pipe, PIPE_CMD_CLOSE);