Hurricos / realtek-poe

5 stars 10 forks source link

realtek-poe: Do not disable PoE on all ports during setup #14

Closed Hurricos closed 2 years ago

Hurricos commented 2 years ago

realtek-poe: Do not disable PoE on all ports during setup

When /etc/init.d/poe restart is invoked, the startup process calls poe_cmd_global_port_enable(0), which causes all PoE sinks connected to the powering device will temporarily lose power and reboot.

Fix this by removing that poe_cmd_global_port_enable(0) from poe_initial_setup.

Also, since this is the only use of poe_cmd_global_port_enable, remove it entirely.

Signed-off-by: Martin Kennedy hurricos@gmail.com

mrnuke commented 2 years ago

Are you sure we want to add poweron and poweroff at this point?

Picturing this in a luci intreface, such as "Network->Switch", Do we want a big button "Turn off all ports"? Though I see the usefulness of having a way to cut off power, that's also easy to type.

I propose one of the following two things:

  1. Remove poe_cmd_global_port_enable() for now. It's trivial to add later.
  2. squash the two commits into one, and feel free to take credit. You have a point between the first and second that the code won't compile. I'd rather avoid that.
Hurricos commented 2 years ago

2. You have a point between the first and second that the code won't compile. I'd rather avoid that.

You might be mistaking the order. 5822e926d16d33449eb1a66148484cbf15b50b6d is the parent of d3ab2e9eaae70e7f04d8bd471ce3120b64d4351c. I did this intentionally to avoid a non-compiling commit.

RE: 1):

... but:

Hurricos commented 2 years ago

Force-pushed everything back, dropping 5822e926d16d33449eb1a66148484cbf15b50b6d from the patchset.

mrnuke commented 2 years ago

My previous argument was not about the theological principle of appeasing the compiler gods. It has more to do with the practical aspects of maintaining causality for git bisect operations.

If you're willing to drop the URLs and parenthetical references (with one or more parentheses) from the commit message, that would be awesome. Otherwise :+1:

Hurricos commented 2 years ago

If you're willing to drop the URLs and parenthetical references (with one or more parentheses) from the commit message, that would be awesome. Otherwise +1

Advice taken.