diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2009-03-11 11:36:26 -0400 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2009-03-11 11:36:26 -0400 |
commit | bb899d49a5d04ae53c787c15c5fb82754d6a0da4 (patch) | |
tree | 28550d13fecf0079eab13a009679a193b7598376 /arch/powerpc/platforms/52xx | |
parent | 1df879e4bbf870d769a9330cb917ed517a1d980c (diff) |
powerpc/5200: remove sysfs debug file from GPT driver
Remove poorly designed debug sysfs attribute entry from the GPT driver.
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
Diffstat (limited to 'arch/powerpc/platforms/52xx')
-rw-r--r-- | arch/powerpc/platforms/52xx/mpc52xx_gpt.c | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/arch/powerpc/platforms/52xx/mpc52xx_gpt.c b/arch/powerpc/platforms/52xx/mpc52xx_gpt.c index cb038dc67a85..bfbcd418e690 100644 --- a/arch/powerpc/platforms/52xx/mpc52xx_gpt.c +++ b/arch/powerpc/platforms/52xx/mpc52xx_gpt.c | |||
@@ -335,44 +335,6 @@ static void | |||
335 | mpc52xx_gpt_gpio_setup(struct mpc52xx_gpt_priv *p, struct device_node *np) { } | 335 | mpc52xx_gpt_gpio_setup(struct mpc52xx_gpt_priv *p, struct device_node *np) { } |
336 | #endif /* defined(CONFIG_GPIOLIB) */ | 336 | #endif /* defined(CONFIG_GPIOLIB) */ |
337 | 337 | ||
338 | /*********************************************************************** | ||
339 | * SYSFS attributes | ||
340 | */ | ||
341 | #if defined(CONFIG_SYSFS) | ||
342 | static ssize_t mpc52xx_gpt_show_regs(struct device *dev, | ||
343 | struct device_attribute *attr, char *buf) | ||
344 | { | ||
345 | struct mpc52xx_gpt_priv *gpt = dev_get_drvdata(dev); | ||
346 | int i, len = 0; | ||
347 | u32 __iomem *regs = (void __iomem *) gpt->regs; | ||
348 | |||
349 | for (i = 0; i < 4; i++) | ||
350 | len += sprintf(buf + len, "%.8x ", in_be32(regs + i)); | ||
351 | len += sprintf(buf + len, "\n"); | ||
352 | |||
353 | return len; | ||
354 | } | ||
355 | |||
356 | static struct device_attribute mpc52xx_gpt_attrib[] = { | ||
357 | __ATTR(regs, S_IRUGO | S_IWUSR, mpc52xx_gpt_show_regs, NULL), | ||
358 | }; | ||
359 | |||
360 | static void mpc52xx_gpt_create_attribs(struct mpc52xx_gpt_priv *gpt) | ||
361 | { | ||
362 | int i, err = 0; | ||
363 | |||
364 | for (i = 0; i < ARRAY_SIZE(mpc52xx_gpt_attrib); i++) { | ||
365 | err = device_create_file(gpt->dev, &mpc52xx_gpt_attrib[i]); | ||
366 | if (err) | ||
367 | dev_err(gpt->dev, "error creating attribute %i\n", i); | ||
368 | } | ||
369 | |||
370 | } | ||
371 | |||
372 | #else /* defined(CONFIG_SYSFS) */ | ||
373 | static void mpc52xx_gpt_create_attribs(struct mpc52xx_gpt_priv *) { return 0; } | ||
374 | #endif /* defined(CONFIG_SYSFS) */ | ||
375 | |||
376 | /* --------------------------------------------------------------------- | 338 | /* --------------------------------------------------------------------- |
377 | * of_platform bus binding code | 339 | * of_platform bus binding code |
378 | */ | 340 | */ |
@@ -395,7 +357,6 @@ static int __devinit mpc52xx_gpt_probe(struct of_device *ofdev, | |||
395 | 357 | ||
396 | dev_set_drvdata(&ofdev->dev, gpt); | 358 | dev_set_drvdata(&ofdev->dev, gpt); |
397 | 359 | ||
398 | mpc52xx_gpt_create_attribs(gpt); | ||
399 | mpc52xx_gpt_gpio_setup(gpt, ofdev->node); | 360 | mpc52xx_gpt_gpio_setup(gpt, ofdev->node); |
400 | mpc52xx_gpt_irq_setup(gpt, ofdev->node); | 361 | mpc52xx_gpt_irq_setup(gpt, ofdev->node); |
401 | 362 | ||