File tree Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -182,7 +182,6 @@ static int bbc_beep_probe(struct platform_device *op)
182
182
{
183
183
struct sparcspkr_state * state ;
184
184
struct bbc_beep_info * info ;
185
- struct device_node * dp ;
186
185
int err ;
187
186
188
187
state = devm_kzalloc (& op -> dev , sizeof (* state ), GFP_KERNEL );
@@ -193,13 +192,12 @@ static int bbc_beep_probe(struct platform_device *op)
193
192
state -> event = bbc_spkr_event ;
194
193
spin_lock_init (& state -> lock );
195
194
196
- dp = of_find_node_by_path ("/" );
195
+ struct device_node * dp __free ( device_node ) = of_find_node_by_path ("/" );
197
196
if (!dp )
198
197
return - ENODEV ;
199
198
200
199
info = & state -> u .bbc ;
201
200
info -> clock_freq = of_getintprop_default (dp , "clock-frequency" , 0 );
202
- of_node_put (dp );
203
201
if (!info -> clock_freq )
204
202
return - ENODEV ;
205
203
You can’t perform that action at this time.
0 commit comments