A company’s board of directors is supposed to act in the best interests of shareholders, but that doesn’t always seem to be the case in Silicon Valley, where some chief executives are capable of driving boards to act in their own interests.

The latest example of worrisome corporate governance in the tech mecca comes from Facebook Inc. FB, -2.24% , where new information shows that the relationship between one board member and Chief Executive Mark Zuckerberg has gotten far too cozy. Bloomberg News reported revelations Thursday on recently unsealed documents in a shareholder lawsuit that contends Facebook’s recent stock split with a new class of nonvoting stock are tantamount to “granting Zuckerberg billions of dollars in equity, for which he will not pay anything.”

The plan, announced in April along with Facebook’s barn-burning first-quarter earnings, was a move by Zuckerberg to retain his control of the company despite plans to deposit almost all his Facebook stock in a philanthropic LLC, the Chan Zuckerberg Initiative. It is a fraught decision for a board to approve a new class of stock that will not have voting privileges and ensure Zuckerberg retains control no matter what he may do in the future.

Facebook Eyes Artificial Intelligence for Spotting Fake News

Zuckerberg seems to have had an ace in the hole, though: board member and venture capitalist Marc Andreessen. Documents in the lawsuit showed texts in which Andreessen was advising Zuckerberg and helping him prepare for questions from a Facebook special committee of the board that reviewed the three-way stock split. Andreessen, one of the three members of that committee, even coached Zuckerberg via text message during one board call.

Facebook’s three-way stock split was not well-received by corporate governance experts and some investors, but it was approved by Facebook shareholders after the board’s seal of approval.

“Facebook is confident that the special committee engaged in a thorough and fair process to negotiate a proposal in the best interests of Facebook and its shareholders,” Facebook said in an emailed statement.

Zuckerberg is also chairman of the board, which counts Chief Operating Officer Sheryl Sandberg and Jan Koum — co-founder and CEO of WhatsApp, an app that Zuckerberg acquired for $16 billion plus incentives — among its members in addition to Andreessen. Together, that group makes up exactly half of the eight-member board, a voting bloc that could ensure Zuckerberg gets his way.

This is certainly an issue beyond Facebook, which was really just stealing from Google’s playbook. Now called Alphabet Inc. GOOGL, -3.45% GOOG, -3.42% , Google split its stock in 2012 to ensure continued dominant control by co-founders Larry Page and Sergey Brin, and ended up paying out investors when a similar shareholder lawsuit was successful.

Beyond favorable stock splits, powerful chief executives with stacked boards can cause issues. Look no farther than a few miles from Facebook’s Menlo Park campus to Palo Alto’s Tesla Motors Inc. TSLA, -10.34% , where Elon Musk recently completed his $2.6 billion deal to buy SolarCity Corp. MX:SCTY

Musk had a number of conflicts of interest in the deal for SolarCity, a solar installer for which he was the principal investor, chairman and cousin of the two founders who act as its top executives. A strong, independent board would have had some serious questions about the deal and how it could be in Musk’s favor while possibly not in Tesla’s, and Musk rightly recused himself from board discussions.

Musk — also chairman at Tesla — had no need to worry that the board would decide in his favor, though, considering how many had a vested interest in seeing SolarCity propped up by a larger entity. Tesla board members included Antonio Gracias, who was also a SolarCity board member; Brad Buss, the former chief financial officer for SolarCity; and Steve Jurvetson, whose venture-capital firm invested in SolarCity. Another Tesla board member is Elon Musk’s brother, Kimbal Musk.

The Tesla-SolarCity deal divided Wall Street and even the two largest independent shareholder-advisory services, Institutional Shareholder Services Inc. and Glass Lewis & Co. While ISS described the deal as “reasonable” and a “necessary step,” Glass Lewis called it a “thinly veiled bailout” for SolarCity.

In its recommendation against voting for the deal, Glass Lewis cited the board’s review, saying it was “hastily managed by a board room rife with conflicts and seemingly limited interest in moderating the apparently ardent strategic and financial preferences” of Elon Musk.

Still, Tesla shareholders approved the deal. Now, Tesla will deal with its own consolidated shareholder lawsuit, which could make a compelling case.

As in Facebook’s case, Musk and Tesla are not alone in this kind of maneuver. At the same time Tesla was fighting to ensure the SolarCity merger, Oracle Corp. ORCL, -2.73% pushed through a much more expensive acquisition of NetSuite Inc. that would enrich Oracle’s founder and chairman, Larry Ellison, an early investor in NetSuite. Despite objections from one of NetSuite’s largest institutional shareholders, Oracle’s $9.3 billion deal for the cloud software developer would also eventually go through.

Forward-thinking executives like Zuckerberg and Musk draw investors to Silicon Valley companies, but building a new “old-boy network” through their boards could also drive them away. Instead of doing what they want and paying off those who dissent through shareholder lawsuits, tech companies’ founders and top executives should start actually constructing boards to do what they are supposed to do.