From 80c37bca675f02fb2bfe71f6ae5ba0232c65bd40 Mon Sep 17 00:00:00 2001 From: lonkaars Date: Tue, 14 May 2024 13:42:06 +0200 Subject: week 2 done: fix driver (reboot'd) --- driver/main.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'driver/main.c') diff --git a/driver/main.c b/driver/main.c index d8ea7fc..e7d7d96 100644 --- a/driver/main.c +++ b/driver/main.c @@ -62,9 +62,6 @@ static int mod_init(void) { goto free_device; } - printk("%s() -> 0 (%d:%d)\n", __PRETTY_FUNCTION__, MAJOR(node), MINOR(node)); - printk("one = %d, two = %d\n", one, not_named_two); - // configure gpio mux uint32_t* conf_gpmc_a3 = ioremap(TI_AM335X_CM_GPMC_A3_ADDR, sizeof(ti_am335x_word_t)); if (conf_gpmc_a3 == NULL) @@ -84,6 +81,9 @@ static int mod_init(void) { iowrite32(oe_reg, gpio1 + GPIO_OE); wmb(); iounmap(gpio1); + // printk("%s() -> 0 (%d:%d)\n", __PRETTY_FUNCTION__, MAJOR(node), MINOR(node)); + // printk("one = %d, two = %d\n", one, not_named_two); + return 0; free_device: @@ -93,7 +93,7 @@ free_cdev: free_class: class_destroy(class); return_err: - printk("%s() -> %d\n", __PRETTY_FUNCTION__, err); + // printk("%s() -> %d\n", __PRETTY_FUNCTION__, err); return err; } @@ -101,7 +101,7 @@ static void mod_exit(void) { device_destroy(class, node); cdev_del(cdev); class_destroy(class); - printk("%s()\n", __PRETTY_FUNCTION__); + // printk("%s()\n", __PRETTY_FUNCTION__); } module_init(mod_init); -- cgit v1.2.3