Lines Matching +full:clk +full:- +full:csr

1 // SPDX-License-Identifier: GPL-2.0-or-later
3 Copyright (C) 2004 - 2009 Ivo van Doorn <IvDoorn@gmail.com>
4 Copyright (C) 2004 - 2009 Felix Fietkau <nbd@openwrt.org>
25 kfree(rt2x00dev->rf); in rt2x00soc_free_reg()
26 rt2x00dev->rf = NULL; in rt2x00soc_free_reg()
28 kfree(rt2x00dev->eeprom); in rt2x00soc_free_reg()
29 rt2x00dev->eeprom = NULL; in rt2x00soc_free_reg()
31 iounmap(rt2x00dev->csr.base); in rt2x00soc_free_reg()
36 struct platform_device *pdev = to_platform_device(rt2x00dev->dev); in rt2x00soc_alloc_reg()
41 return -ENODEV; in rt2x00soc_alloc_reg()
43 rt2x00dev->csr.base = ioremap(res->start, resource_size(res)); in rt2x00soc_alloc_reg()
44 if (!rt2x00dev->csr.base) in rt2x00soc_alloc_reg()
45 return -ENOMEM; in rt2x00soc_alloc_reg()
47 rt2x00dev->eeprom = kzalloc(rt2x00dev->ops->eeprom_size, GFP_KERNEL); in rt2x00soc_alloc_reg()
48 if (!rt2x00dev->eeprom) in rt2x00soc_alloc_reg()
51 rt2x00dev->rf = kzalloc(rt2x00dev->ops->rf_size, GFP_KERNEL); in rt2x00soc_alloc_reg()
52 if (!rt2x00dev->rf) in rt2x00soc_alloc_reg()
61 return -ENOMEM; in rt2x00soc_alloc_reg()
70 hw = ieee80211_alloc_hw(sizeof(struct rt2x00_dev), ops->hw); in rt2x00soc_probe()
73 return -ENOMEM; in rt2x00soc_probe()
78 rt2x00dev = hw->priv; in rt2x00soc_probe()
79 rt2x00dev->dev = &pdev->dev; in rt2x00soc_probe()
80 rt2x00dev->ops = ops; in rt2x00soc_probe()
81 rt2x00dev->hw = hw; in rt2x00soc_probe()
82 rt2x00dev->irq = platform_get_irq(pdev, 0); in rt2x00soc_probe()
83 rt2x00dev->name = pdev->dev.driver->name; in rt2x00soc_probe()
85 rt2x00dev->clk = clk_get(&pdev->dev, NULL); in rt2x00soc_probe()
86 if (IS_ERR(rt2x00dev->clk)) in rt2x00soc_probe()
87 rt2x00dev->clk = NULL; in rt2x00soc_probe()
114 struct rt2x00_dev *rt2x00dev = hw->priv; in rt2x00soc_remove()
131 struct rt2x00_dev *rt2x00dev = hw->priv; in rt2x00soc_suspend()
140 struct rt2x00_dev *rt2x00dev = hw->priv; in rt2x00soc_resume()